Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Small stylistic tweaks for `Delegator#try` patch | Godfrey Chan | 2015-05-19 | 1 | -5/+5 |
| | | | | | | * Rename `ActiveSupport::Try` => `ActiveSupport::Tryable` * Include the modules inline * `private` indentation | ||||
* | Patch `Delegator` to work with `#try` | Nate Smith | 2015-05-19 | 1 | -17/+57 |
| | | | | | | | | | | | | `Delegator` inherits from `BasicObject`, which means that it will not have `Object#try` defined. It will then delegate the call to the underlying object, which will not (necessarily) respond to the method defined in the enclosing `Delegator`. This patches `Delegator` with the `#try` method to work around the surprising behaviour. Fixes #5790 | ||||
* | Only define #positive? and #negative? on Ruby 2.2 | Rafael Mendonça França | 2015-05-19 | 1 | -0/+7 |
| | | | | | | | The feature was accepted and added to Ruby 2.3+ so we don't need to define it again. See https://bugs.ruby-lang.org/issues/11151 | ||||
* | Move Integer#positive? and Integer#negative? query methods to Numeric class | Mehmet Emin İNAÇ | 2015-05-13 | 3 | -2/+2 |
| | | | | By this way Integer, Rational, Float, Fixnum, Bignum classes have the same behaviour | ||||
* | Minor comment fix. [ci skip] | Zoltan Kiss | 2015-05-13 | 1 | -4/+4 |
| | |||||
* | Add Integer#positive? and Integer#negative? query methods in the vein of ↵ | David Heinemeier Hansson | 2015-05-13 | 2 | -0/+20 |
| | | | | Fixnum#zero? | ||||
* | Merge pull request #20049 from iamvery/patch-1 | Yves Senn | 2015-05-07 | 1 | -1/+13 |
|\ | | | | | | | Amend `next_week` documentation [ci skip] | ||||
| * | Add examples of Date and Time `next_week` usage | Jay Hayes | 2015-05-07 | 1 | -0/+7 |
|/ | | | | [skip ci] | ||||
* | deep_dup method, remove old key from duplicated hash to avoid unnecessary pairs | Mehmet Emin İNAÇ | 2015-05-04 | 1 | -0/+1 |
| | |||||
* | Clearify that alias_method_chain is deprecated | Prem Sichanugrist | 2015-04-22 | 1 | -0/+3 |
| | | | | | This was not clear on the API documentation that the method was deprecated in a982a42d766169c2170d7f100c2a5ceb5430efb1. | ||||
* | Merge pull request #19814 from y-yagi/array_inquiry | Rafael Mendonça França | 2015-04-19 | 1 | -0/+2 |
|\ | | | | | add missing require for ArrayInquirer | ||||
| * | add missing require for ArrayInquirer | yuuji.yaginuma | 2015-04-19 | 1 | -0/+2 |
| | | |||||
* | | Merge pull request #19799 from yui-knk/fix/wrap_doc2 | Arthur Nogueira Neves | 2015-04-19 | 1 | -3/+4 |
|\ \ | |/ |/| | [ci skip] Fix docs and guide about 'Array.wrap' | ||||
| * | [ci skip] Fix docs and guide about 'Array.wrap' | yui-knk | 2015-04-19 | 1 | -3/+4 |
| | | |||||
* | | [ci skip] Replace `list` with `array` | yui-knk | 2015-04-18 | 1 | -1/+1 |
|/ | |||||
* | Fix typos and improve the documentation | Jon Atack | 2015-04-15 | 1 | -3/+3 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a squash of the following commits, from first to last: - Fix minor, random things I’ve come across lately that individually did not seem worth making a PR for, so I saved them for one commit. One common error is using “it’s” (which is an abbreviation of “it is”) when the possessive “its” should be used for indicating possession. - Changes include the name of a test, so remove the `[skip ci]` (thanks @senny). - Line wrap the changes at 80 chars and add one more doc fix. - Add a missing line wrap in the Contributing to Ruby on Rails Guide. - Line wrap the `TIP` section in the Contributing to Ruby on Rails Guide as well. Rendering the guide locally with `bundle exec rake guides:generate` did not show any change in on-screen formatting after adding the line wrap. The HTML generated is (extra line added to illustrate where the line wrap takes place): <div class="info"><p>Please squash your commits into a single commit when appropriate. This simplifies future cherry picks and also keeps the git log clean.</p></div> - Squash commits. | ||||
* | Use #prepend rather than using 2 aliases | Yuki Nishijima | 2015-04-14 | 2 | -42/+36 |
| | |||||
* | Merge branch 'master' of github.com:rails/docrails | Vijay Dev | 2015-04-14 | 1 | -1/+1 |
|\ | |||||
| * | [ci skip] Remove unnecessary `>` | yui-knk | 2015-03-31 | 1 | -1/+1 |
| | | |||||
* | | Speedup String#squish | ojab | 2015-04-12 | 1 | -2/+1 |
| | | |||||
* | | Only coerce time when comparing if necessary | Aaron Jensen | 2015-03-31 | 1 | -2/+4 |
| | | | | | | | | | | | | In dev, ActiveSupport::FileUpdateChecker#max_mtime triggers many time comparisons. Time#to_time is quite a bit slower than not doing it, so we should avoid it if possible. | ||||
* | | [ci skip] Replace `query methods` with `a predicate` | yui-knk | 2015-03-31 | 1 | -1/+1 |
| | | |||||
* | | Revert "Remove Array#inquiry" | Rafael Mendonça França | 2015-03-30 | 2 | -0/+16 |
| | | | | | | | | | | | | This reverts commit 9420de59f5b7f5ceac77e28e6c326ec145f71f80. Reason: Turns out we want to keep this method. | ||||
* | | Remove circular require | Rafael Mendonça França | 2015-03-27 | 2 | -4/+0 |
| | | |||||
* | | Remove Array#inquiry | Rafael Mendonça França | 2015-03-27 | 2 | -16/+0 |
| | | | | | | | | | | We are promoting too much a feature that will not be widler used. So for now lets keep just the ArrayInquirer constructor. | ||||
* | | Merge pull request #18939 from georgeclaghorn/variant-inquiry | Rafael Mendonça França | 2015-03-27 | 2 | -0/+16 |
|\ \ | | | | | | | | | | Provide friendlier access to request variants | ||||
| * | | Add ActiveSupport::ArrayInquirer and Array#inquiry | George Claghorn | 2015-03-24 | 2 | -0/+16 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Wrapping an array in an `ArrayInquirer` gives a friendlier way to check its string-like contents. For example, `request.variant` returns an `ArrayInquirer` object. To check a request's variants, you can call: request.variant.phone? request.variant.any?(:phone, :tablet) ...instead of: request.variant.include?(:phone) request.variant.any? { |v| v.in?([:phone, :tablet]) } `Array#inquiry` is a shortcut for wrapping the receiving array in an `ArrayInquirer`: pets = [:cat, :dog] pets.cat? # => true pets.ferret? # => false pets.any?(:cat, :ferret} # => true | ||||
* | | | Missing require 'active_support/deprecation' | Akira Matsuda | 2015-03-27 | 2 | -0/+4 |
| |/ |/| | |||||
* | | Merge branch 'master' of github.com:rails/docrails | Vijay Dev | 2015-03-26 | 1 | -1/+1 |
|\ \ | |/ |/| | | | | | Conflicts: guides/source/4_0_release_notes.md | ||||
| * | [ci skip] Add space after erb block. | yui-knk | 2015-03-12 | 1 | -1/+1 |
| | | |||||
* | | Make sure Array#to_sentence always returns a String | David Cornu | 2015-03-23 | 1 | -1/+1 |
| | | |||||
* | | Remove reference to Numeric#from_now, as it is no longer supported | nerdinand | 2015-03-23 | 2 | -30/+0 |
| | | |||||
* | | Deprecate alias_method_chain in favour of Module#prepend | Kir Shatrov | 2015-03-22 | 3 | -8/+14 |
| | | | | | | …as discussed #19413 | ||||
* | | Mark some constants as nodoc and remove unneeded namespace | Rafael Mendonça França | 2015-03-20 | 2 | -12/+10 |
| | | |||||
* | | Use Module#prepend instead of alias_method_chain | Kir Shatrov | 2015-03-20 | 2 | -20/+22 |
| | | | | | | | | | | | | | | Thanks @fbernier for suggestion! <3 At this moment we can use Module#prepend in all all cases except of Range because of the bug [1] in MRI 2.2 [1] https://bugs.ruby-lang.org/issues/10847 | ||||
* | | Doc fixes [ci skip] | Islam Wazery | 2015-03-07 | 4 | -4/+4 |
| | | |||||
* | | Doc fix [ci skip] | Islam Wazery | 2015-03-07 | 1 | -7/+7 |
| | | |||||
* | | [ci skip] Update documentation for Time#seconds_since_midnight | Anton Davydov | 2015-03-06 | 1 | -1/+5 |
| | | |||||
* | | Some documentation edits [ci skip] | Robin Dupret | 2015-03-05 | 1 | -3/+3 |
| | | | | | | | | | | | | * Fix a few typos * Wrap some lines around 80 chars * Rephrase some statements | ||||
* | | Move Array#without from Grouping to Access concern and add dedicated test ↵ | David Heinemeier Hansson | 2015-03-02 | 2 | -12/+12 |
| | | | | | | | | (relates to #19157) | ||||
* | | Use include? instead of in? for Enumerable#without. | Juanito Fatas | 2015-03-02 | 1 | -1/+1 |
| | | | | | | | | [egilburg] | ||||
* | | Add Enumerable#without | Todd Bealmear | 2015-03-01 | 2 | -0/+23 |
|/ | |||||
* | Merge pull request #19131 from ↵ | Yves Senn | 2015-02-28 | 1 | -1/+1 |
|\ | | | | | | | | | tgxworld/reduce_allocated_memory_in_module_delegate Reduce allocated memory for Module#delegate. | ||||
| * | Reduce allocated memory for Module#delegate. | Guo Xiang Tan | 2015-03-01 | 1 | -1/+1 |
| | | |||||
* | | [ci skip] Add code examples for Module#anonymous? documentation | Anton Davydov | 2015-02-28 | 1 | -0/+7 |
| | | |||||
* | | [ci skip] Update documentation for Range#to_formatted_s | Anton Davydov | 2015-02-28 | 1 | -2/+17 |
|/ | |||||
* | [skip ci] Add documentation for String#is_utf8? method | Anton Davydov | 2015-02-28 | 1 | -0/+7 |
| | |||||
* | Merge pull request #19121 from davydovanton/update-doc-for-remove | Yves Senn | 2015-02-28 | 1 | -2/+3 |
|\ | | | | | | | Update documentation examples for String#remove [skip ci] | ||||
| * | Update documentation examples for String#remove [skip ci] | Anton Davydov | 2015-02-28 | 1 | -6/+7 |
|/ | |||||
* | Fix a backtracking problem in String#truncate_words | Henrik Nygren | 2015-02-25 | 1 | -1/+1 |
| | | | | Fixes #19070. |