summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-12-10 06:19:21 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-12-10 06:19:21 +0000
commit735574cfa87af30c7de4b5fad26e39dcbac5a7d8 (patch)
tree4ceace9e4f2b28712a8696d5ee4f464c1f325a7e
parentfc1443e142ca3ce4c0e254f2222b968ad44b5f71 (diff)
downloadruby-735574cfa87af30c7de4b5fad26e39dcbac5a7d8.tar.gz
ruby-735574cfa87af30c7de4b5fad26e39dcbac5a7d8.tar.xz
ruby-735574cfa87af30c7de4b5fad26e39dcbac5a7d8.zip
* eval.c (mnew): original class of method defined in module should
be the module not intermediate class. [ruby-dev:19040] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@3121 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--eval.c1
2 files changed, 6 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 14f6be731..95c6c895d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Tue Dec 10 12:01:15 2002 Nobuyoshi Nakada <nobu.nokada@softhome.net>
+
+ * eval.c (mnew): original class of method defined in module should
+ be the module not intermediate class. [ruby-dev:19040]
+
Wed Dec 4 16:37:11 2002 Yukihiro Matsumoto <matz@ruby-lang.org>
* object.c (copy_object): copy finalizers as well if any.
diff --git a/eval.c b/eval.c
index d35b9b739..1daf12e6c 100644
--- a/eval.c
+++ b/eval.c
@@ -6878,6 +6878,7 @@ mnew(klass, obj, id, mklass)
goto again;
}
+ if (TYPE(klass) == T_ICLASS) klass = RBASIC(klass)->klass;
method = Data_Make_Struct(mklass, struct METHOD, bm_mark, free, data);
data->klass = klass;
data->recv = obj;