зеркало из https://github.com/github/ruby.git
* 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:
Родитель
c41cefd492
Коммит
4937f8cf34
|
@ -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
9
eval.c
|
@ -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);
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче