aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib/active_support/core_ext/module
Commit message (Collapse)AuthorAgeFilesLines
* Fix some typosVipul A M2013-06-071-1/+1
|
* Use new hash syntax in module delegation docs [ci skip]Carlos Antonio da Silva2013-04-281-1/+1
|
* Module#delegate checks nilness rather that falsehood if :allow_nil is true, ↵Xavier Noria2013-04-261-30/+42
| | | | | | | | | | | | | | and avoids multiple evaluation of the target method Notes: 1) I hope nilness is a word. 2) See rationale for avoiding multiple evaluation in a comment in the patch, credit goes to @jeremy for pointing out this gotcha in the existing implementation. 3) Embeds a little joke dedicated to @pixeltrix (it could be worse! :D). References #10347.
* Delegation method bugLi Ellis Gallardo2013-04-251-0/+14
| | | | | | Add documentation and test to delegation method that make sure we're aware that when a delegated object is not nil or false and doesn't respond to the method it will still raise a NoMethodError exception.
* The third argument of deprecation_warning is always optionalRafael Mendonça França2013-04-161-1/+1
| | | [ci skip]
* Fix documentation to the custom DeprecatorRafael Mendonça França2013-04-161-1/+1
| | | [ci skip]
* Make caller attribute in deprecation methods optionalAlexey Gaziev2012-10-301-1/+1
|
* Hash Syntax changes to 1.9 formatAvnerCohen2012-10-201-4/+4
|
* Merge branch 'master' of github.com:lifo/docrailsVijay Dev2012-09-213-4/+0
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: actionmailer/lib/action_mailer/base.rb activesupport/lib/active_support/configurable.rb activesupport/lib/active_support/core_ext/module/deprecation.rb guides/source/action_controller_overview.md guides/source/active_support_core_extensions.md guides/source/ajax_on_rails.textile guides/source/association_basics.textile guides/source/upgrading_ruby_on_rails.md While resolving conflicts, I have chosen to ignore changes done in docrails at some places - these will be most likely 1.9 hash syntax changes.
| * update AS/core_ext docs [ci skip]Francesco Rodriguez2012-09-122-3/+0
| |
| * update some AS code examples to 1.9 hash syntax [ci skip]Francesco Rodriguez2012-09-122-12/+11
| |
* | Update delegate docs with new hash syntax [ci skip]Carlos Antonio da Silva2012-09-201-10/+10
| |
* | Add changelog entry and docs about class delegation using the symbol :classCarlos Antonio da Silva2012-09-201-0/+12
| | | | | | | | See #7613. [ci skip]
* | Merge pull request #7613 from marcandre/delegate_to_classJeremy Kemper2012-09-201-0/+3
|\ \ | | | | | | Nice and easy delegation to the class
| * | Nice and easy delegation to the classMarc-Andre Lafortune2012-09-111-0/+3
| |/
* | Copy-edit deprecation relared documentation [ci skip]Rafael Mendonça França2012-09-131-28/+10
| |
* | Change ActiveSupport::Deprecation to class.Piotr Niełacny2012-09-131-1/+33
|/ | | | | | | | | | | | | | | | | | | | | | | | ActiveSupport::Deprecation is now a class rather than a module. You can get instance of ActiveSupport::Deprecation calling #instance method. ActiveSupport::Deprecation.instance But when you need to get new object od ActiveSupport::Deprecation you need to just call #new. @instance = ActiveSupport::Deprecation.new Since you can create a new object, you can change the version and the name of the library where the deprecator concerned. ActiveSupport::Deprecation.new('2.0', 'MyGem') If you need use another deprecator instance you can select it in the options of deprecate method. deprecate :method, :deprecator => deprecator_instance Documentation has been updated.
* no need to to_s here. Both String and Symbol can be interpolated into StringAkira Matsuda2012-06-061-3/+0
|
* fix example format and add markup in Module#mattr_accessor documentation [ci ↵Francesco Rodriguez2012-05-291-10/+10
| | | | skip]
* update Module#mattr_accessor documentation [ci skip]Francesco Rodriguez2012-05-261-6/+6
|
* removing unnecessary 'examples' noise from activesupportFrancesco Rodriguez2012-05-131-2/+0
|
* String quotes and trailing spacesAlexey Gaziev2012-04-293-11/+11
|
* AS core_ext refactoring pt.2Alexey Gaziev2012-04-295-13/+14
|
* Remove Module#delegate!Daniel Schierbeck2012-04-121-52/+0
|
* Add back the old `deprecate` method as `deprecate!`Daniel Schierbeck2012-04-121-0/+52
|
* Change API docs regarding delegation to non-public methodsDaniel Schierbeck2012-04-121-1/+1
|
* Optimize the performance of #delegateDaniel Schierbeck2012-04-121-9/+13
| | | | | | Remove the use of #__send__ in order to boost performance. This also means that you can no longer delegate to private methods on the target object.
* revises requires of some AS deprecation filesXavier Noria2012-04-051-1/+1
|
* Merge pull request #3084 from esad/masterXavier Noria2012-04-051-0/+2
|\ | | | | Dependency fix for activesupport
| * Add a missing require for 'active_support/deprecation' in Module#deprecateEsad Hajdarevic2011-09-201-0/+2
| |
* | use undef_method to avoid NameError exceptions all the timeAaron Patterson2012-03-311-5/+1
| |
* | validate attribute names in class and module attribute accessorsDmitry Plashchynski2012-03-301-0/+2
| |
* | Remove deprecation from AS::Deprecation behavior, some minor cleanupsCarlos Antonio da Silva2012-03-161-7/+9
| | | | | | | | | | | | | | | | | | * Refactor log subscriber, use select! to avoid a new object * Remove deprecation messages related to AS::Deprecation behavior This was added about 2 years ago for Rails 3: https://github.com/rails/rails/commit/d4c7d3fd94e5a885a6366eaeb3b908bb58ffd4db * Remove some not used requires * Refactor delegate to avoid string conversions and if statements inside each block
* | Fix indentation in code example of DelegationTomasz Zurkowski2012-01-201-19/+19
| |
* | deprecates Module#local_constant_namesXavier Noria2012-01-121-2/+12
| |
* | removes the compatibility method Module#method_namesXavier Noria2011-12-251-5/+0
| |
* | removes the compatibility method Module#instance_method_namesXavier Noria2011-12-251-4/+0
| |
* | ruby 1.9 returns method names as symbolsSergey Nartimov2011-12-251-11/+6
| |
* | Module#name returns nil for anonymous class in ruby 1.9Vasiliy Ermolovich2011-12-251-6/+2
| |
* | remove deprecated Module#synchronize from ActiveSupportSergey Nartimov2011-12-241-45/+0
| |
* | Remove more dead code from AS.José Valim2011-12-201-18/+6
| |
* | Initial pass at removing dead 1.8.x code from Active Support.José Valim2011-12-201-21/+2
| | | | | | | | | | | | There are a bunch of other implicit branches that adds 1.8.x specific code that still needs to be removed. Pull requests for those cases are welcome.
* | Module#synchronize is deprecated with no replacement. Please use `monitor` ↵Aaron Patterson2011-11-291-0/+2
| | | | | | | | from ruby's standard library.
* | defines Module#qualified_const_(defined?|get|set) and String#deconstantizeXavier Noria2011-10-291-0/+64
| | | | | | | | | | | | | | | | | | | | This commit also implements a faster version of #demodulize I was unable to isolate with git add --patch. Not a big fan of the name #deconstantize. It complements #demodulize getting rid of the rightmost constant, hence the name, but it is unrelated to the well-known #constantize. So unsure. Could not come with anything better, please feel free to rename.
* | Use safe_constantize where possible.José Valim2011-09-231-3/+1
|/
* Revert all the stuff to do with disallowing non-public methods for ↵Jon Leighton2011-08-251-6/+2
| | | | Module#delegate
* prefer ends_with? over slicingXavier Noria2011-08-161-1/+2
|
* Add a test for delegating a method ending in '=' as this is a special case.Jon Leighton2011-08-151-0/+1
|
* Need to include public_sendArun Agrawal2011-08-151-0/+1
|
* Split up the definitions in Module#delegate depending on :allow_nil, and ↵Jon Leighton2011-08-151-17/+22
| | | | don't use exceptions for flow control in the :allow_nil => true case.