diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-24 16:38:44 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-24 16:38:44 +0000 |
commit | b9ce5706b5b7d53868f1d76010d269e80f246a9a (patch) | |
tree | cbea16e53963e2f2a0ad8bb830f07fc43f458eb1 /numeric.c | |
parent | 368a41151e2969097787eb663ba1bb5c1fb09efd (diff) | |
download | ruby-b9ce5706b5b7d53868f1d76010d269e80f246a9a.tar.gz ruby-b9ce5706b5b7d53868f1d76010d269e80f246a9a.tar.xz ruby-b9ce5706b5b7d53868f1d76010d269e80f246a9a.zip |
* proc.c (method_name): preserve Symbol's encoding.
* numeric.c (fix_id2name): ditto.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@14620 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'numeric.c')
-rw-r--r-- | numeric.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -2809,8 +2809,8 @@ fix_abs(VALUE fix) static VALUE fix_id2name(VALUE fix) { - const char *name = rb_id2name(FIX2UINT(fix)); - if (name) return rb_str_new2(name); + VALUE name = rb_id2str(FIX2UINT(fix)); + if (name) return rb_str_dup(name); return Qnil; } |