From 2b0dee5cb639b23fc59690c214acaa40b43380b2 Mon Sep 17 00:00:00 2001 From: matz Date: Mon, 28 Apr 2008 02:12:21 +0000 Subject: * proc.c (method_name): should return symbols instead of strings. [ruby-dev:34531] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@16223 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- proc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'proc.c') diff --git a/proc.c b/proc.c index a2c53ce69..57109eff7 100644 --- a/proc.c +++ b/proc.c @@ -905,7 +905,7 @@ method_receiver(VALUE obj) /* * call-seq: - * meth.name => string + * meth.name => symbol * * Returns the name of the method. */ @@ -916,7 +916,7 @@ method_name(VALUE obj) struct METHOD *data; Data_Get_Struct(obj, struct METHOD, data); - return rb_str_dup(rb_id2str(data->id)); + return ID2SYM(data->id); } /* -- cgit