зеркало из https://github.com/github/ruby.git
* eval.c (DMETHOD_P): accessing wrong frame. [ruby-dev:28181]
* eval.c (proc_invoke): preserve FRAME_DMETH flag. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9931 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
3770f98992
Коммит
14afb53073
|
@ -1,3 +1,9 @@
|
|||
Tue Feb 14 18:48:33 2006 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||
|
||||
* eval.c (DMETHOD_P): accessing wrong frame. [ruby-dev:28181]
|
||||
|
||||
* eval.c (proc_invoke): preserve FRAME_DMETH flag.
|
||||
|
||||
Tue Feb 14 15:15:22 2006 Hirokazu Yamamoto <ocean@m2.ccsnet.ne.jp>
|
||||
|
||||
* ext/zlib/zlib.c: supress warning on test/zlib. [ruby-dev:28323]
|
||||
|
|
3
eval.c
3
eval.c
|
@ -780,7 +780,7 @@ struct RVarmap *ruby_dyna_vars;
|
|||
|
||||
#define DVAR_DONT_RECYCLE FL_USER2
|
||||
|
||||
#define DMETHOD_P() (ruby_frame->prev ? (ruby_frame->prev->flags & FRAME_DMETH) : 0)
|
||||
#define DMETHOD_P() (ruby_frame->flags & FRAME_DMETH)
|
||||
|
||||
static struct RVarmap*
|
||||
new_dvar(ID id, VALUE value, struct RVarmap *prev)
|
||||
|
@ -8323,6 +8323,7 @@ proc_invoke(VALUE proc, VALUE args /* OK */, VALUE self, VALUE klass)
|
|||
if (self != Qundef) _block.frame.self = self;
|
||||
if (klass) _block.frame.this_class = klass;
|
||||
_block.frame.argc = RARRAY(tmp)->len;
|
||||
_block.frame.flags = ruby_frame->flags;
|
||||
if (_block.frame.argc && (ruby_frame->flags & FRAME_DMETH)) {
|
||||
NEWOBJ(scope, struct SCOPE);
|
||||
OBJSETUP(scope, tmp, T_SCOPE);
|
||||
|
|
Загрузка…
Ссылка в новой задаче