summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-05-31 00:11:53 +0000
committeryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-05-31 00:11:53 +0000
commit31dc2ea28fe807a9c793147ba6417cbf6f34e383 (patch)
tree8ded13ce3ba56bd9fb61feca48c4b4fb530837ea
parentd3398c196ba03dfceb46d71595e9716a216f6cc1 (diff)
merges r31507 from trunk into ruby_1_9_2.
-- * lib/forwardable.rb: support 'delegate :foo => :bar' for to meet by specification of RDOC. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_2@31833 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--lib/forwardable.rb4
-rw-r--r--version.h2
3 files changed, 8 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 0c9b9f6b2c..3c38cc9794 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Wed May 11 19:45:27 2011 Keiju Ishitsuka <keiju@ishitsuka.com>
+
+ * lib/forwardable.rb: support 'delegate :foo => :bar' for to meet
+ by specification of RDOC.
+
Sun May 8 19:39:16 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
* thread_pthread.c (native_cond_timedwait): add to care EINTR.
diff --git a/lib/forwardable.rb b/lib/forwardable.rb
index 06f157170d..a29dd71589 100644
--- a/lib/forwardable.rb
+++ b/lib/forwardable.rb
@@ -149,7 +149,7 @@ module Forwardable
#
def instance_delegate(hash)
hash.each{ |methods, accessor|
- methods = methods.to_s unless methods.respond_to?(:each)
+ methods = [methods] unless methods.respond_to?(:each)
methods.each{ |method|
def_instance_delegator(accessor, method)
}
@@ -214,7 +214,7 @@ module SingleForwardable
#
def single_delegate(hash)
hash.each{ |methods, accessor|
- methods = methods.to_s unless methods.respond_to?(:each)
+ methods = [methods] unless methods.respond_to?(:each)
methods.each{ |method|
def_single_delegator(accessor, method)
}
diff --git a/version.h b/version.h
index 91e82a74ad..712fdaca53 100644
--- a/version.h
+++ b/version.h
@@ -1,5 +1,5 @@
#define RUBY_VERSION "1.9.2"
-#define RUBY_PATCHLEVEL 250
+#define RUBY_PATCHLEVEL 251
#define RUBY_VERSION_MAJOR 1
#define RUBY_VERSION_MINOR 9
#define RUBY_VERSION_TEENY 1