diff options
author | Xavier Noria <fxn@hashref.com> | 2010-04-05 12:15:08 -0700 |
---|---|---|
committer | Xavier Noria <fxn@hashref.com> | 2010-04-05 12:15:08 -0700 |
commit | 89978f10afbad3f856e2959a811bed1982715408 (patch) | |
tree | 9913b04ec5a63e4e88dd70de023dc50029c43690 /activesupport/lib/active_support/core_ext/object | |
parent | c140aca361506a3a759fbe03fad8adc748c807bb (diff) | |
download | rails-89978f10afbad3f856e2959a811bed1982715408.tar.gz rails-89978f10afbad3f856e2959a811bed1982715408.tar.bz2 rails-89978f10afbad3f856e2959a811bed1982715408.zip |
moves Object#singleton_class to Kernel#singleton_class to match Ruby also there, same for #class_eval to simplify, and adds coverage for class_eval
Diffstat (limited to 'activesupport/lib/active_support/core_ext/object')
-rw-r--r-- | activesupport/lib/active_support/core_ext/object/singleton_class.rb | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/activesupport/lib/active_support/core_ext/object/singleton_class.rb b/activesupport/lib/active_support/core_ext/object/singleton_class.rb deleted file mode 100644 index 8dee54e71b..0000000000 --- a/activesupport/lib/active_support/core_ext/object/singleton_class.rb +++ /dev/null @@ -1,13 +0,0 @@ -class Object - # Returns the object's singleton class. - def singleton_class - class << self - self - end - end unless respond_to?(:singleton_class) - - # class_eval on an object acts like singleton_class_eval. - def class_eval(*args, &block) - singleton_class.class_eval(*args, &block) - end -end |