1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* eval.c (rb_obj_instance_eval): evaluates under special singleton

classes as for special constants.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6783 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2004-08-18 03:53:50 +00:00
parent c41cefd492
commit 4937f8cf34
2 changed files with 6 additions and 8 deletions

View file

@ -1,3 +1,8 @@
Wed Aug 18 12:52:55 2004 Nobuyoshi Nakada <nobu@ruby-lang.org>
* eval.c (rb_obj_instance_eval): evaluates under special singleton
classes as for special constants.
Wed Aug 18 11:22:52 2004 Nobuyoshi Nakada <nobu@ruby-lang.org>
* win32/win32.c (init_env): initialize HOME and USER environment

9
eval.c
View file

@ -6380,14 +6380,7 @@ rb_obj_instance_eval(argc, argv, self)
VALUE *argv;
VALUE self;
{
VALUE klass;
if (rb_special_const_p(self)) {
klass = Qnil;
}
else {
klass = rb_singleton_class(self);
}
VALUE klass = rb_singleton_class(self);
return specific_eval(argc, argv, klass, self);
}