mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* eval.c (method_inspect, method_name, mnew): Bug fix when
method created from an alias. Based on a patch by Peter Vanbroekhoven [ruby-core:22040] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@25693 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
7c3869368c
commit
9c197735be
3 changed files with 12 additions and 6 deletions
|
@ -1,3 +1,9 @@
|
|||
Mon Nov 9 01:55:10 2009 Marc-Andre Lafortune <ruby-core@marc-andre.ca>
|
||||
|
||||
* eval.c (method_inspect, method_name, mnew): Bug fix when
|
||||
method created from an alias.
|
||||
Based on a patch by Peter Vanbroekhoven [ruby-core:22040]
|
||||
|
||||
Fri Nov 6 17:13:45 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* lib/mkmf.rb (create_header): split the line by tabs.
|
||||
|
|
8
eval.c
8
eval.c
|
@ -9390,8 +9390,8 @@ mnew(klass, obj, id, mklass)
|
|||
ID oid = id;
|
||||
|
||||
again:
|
||||
if ((body = rb_get_method_body(&klass, &id, &noex)) == 0) {
|
||||
print_undef(rklass, oid);
|
||||
if ((body = rb_get_method_body(&klass, &oid, &noex)) == 0) {
|
||||
print_undef(rklass, id);
|
||||
}
|
||||
|
||||
if (nd_type(body) == NODE_ZSUPER) {
|
||||
|
@ -9532,7 +9532,7 @@ method_name(obj)
|
|||
struct METHOD *data;
|
||||
|
||||
Data_Get_Struct(obj, struct METHOD, data);
|
||||
return rb_str_new2(rb_id2name(data->oid));
|
||||
return rb_str_new2(rb_id2name(data->id));
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -9959,7 +9959,7 @@ method_inspect(method)
|
|||
}
|
||||
}
|
||||
rb_str_buf_cat2(str, sharp);
|
||||
rb_str_buf_cat2(str, rb_id2name(data->oid));
|
||||
rb_str_buf_cat2(str, rb_id2name(data->id));
|
||||
rb_str_buf_cat2(str, ">");
|
||||
|
||||
return str;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
require 'test/unit'
|
||||
|
||||
rcsid = %w$Id$
|
||||
Version = rcsid[2].scan(/\d+/).collect!(&method(:Integer)).freeze
|
||||
Release = rcsid[3].freeze
|
||||
Version = rcsid[2].scan(/\d+/).collect!(&method(:Integer)).freeze rescue nil
|
||||
Release = rcsid[3].freeze rescue nil
|
||||
|
||||
exit Test::Unit::AutoRunner.run(true, File.dirname($0))
|
||||
|
|
Loading…
Add table
Reference in a new issue