ruby-changes:40285
From: ko1 <ko1@a...>
Date: Fri, 30 Oct 2015 06:14:38 +0900 (JST)
Subject: [ruby-changes:40285] ko1:r52366 (trunk): * vm_insnhelper.c (vm_check_frame_detail): should require me for
ko1 2015-10-30 06:14:29 +0900 (Fri, 30 Oct 2015) New Revision: 52366 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=52366 Log: * vm_insnhelper.c (vm_check_frame_detail): should require me for VM_FRAME_FLAG_BMETHOD type frame. Modified files: trunk/ChangeLog trunk/vm_insnhelper.c Index: ChangeLog =================================================================== --- ChangeLog (revision 52365) +++ ChangeLog (revision 52366) @@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Fri Oct 30 06:13:10 2015 Koichi Sasada <ko1@a...> + + * vm_insnhelper.c (vm_check_frame_detail): should require me for + VM_FRAME_FLAG_BMETHOD type frame. + Thu Oct 29 18:42:30 2015 Koichi Sasada <ko1@a...> * gc.c (gc_mark_ptr): specify NOINLINE so that gc_mark() can return Index: vm_insnhelper.c =================================================================== --- vm_insnhelper.c (revision 52365) +++ vm_insnhelper.c (revision 52366) @@ -67,13 +67,17 @@ callable_method_entry_p(const rb_callabl https://github.com/ruby/ruby/blob/trunk/vm_insnhelper.c#L67 } static void -vm_check_frame_detail(int magic, int req_block, int req_me, int req_cref, VALUE specval, VALUE cref_or_me) +vm_check_frame_detail(VALUE type, int req_block, int req_me, int req_cref, VALUE specval, VALUE cref_or_me) { + int magic = (int)(type & VM_FRAME_MAGIC_MASK); enum imemo_type cref_or_me_type = imemo_none; if (RB_TYPE_P(cref_or_me, T_IMEMO)) { cref_or_me_type = imemo_type(cref_or_me); } + if (type & VM_FRAME_FLAG_BMETHOD) { + req_me = TRUE; + } if (req_block && !VM_ENVVAL_BLOCK_PTR_P(specval)) { rb_bug("vm_push_frame: specval (%p) should be a block_ptr on %x frame", (void *)specval, magic); @@ -119,7 +123,7 @@ vm_check_frame(VALUE type, https://github.com/ruby/ruby/blob/trunk/vm_insnhelper.c#L123 { int magic = (int)(type & VM_FRAME_MAGIC_MASK); -#define CHECK(magic, req_block, req_me, req_cref) case magic: vm_check_frame_detail(magic, req_block, req_me, req_cref, specval, cref_or_me); break; +#define CHECK(magic, req_block, req_me, req_cref) case magic: vm_check_frame_detail(type, req_block, req_me, req_cref, specval, cref_or_me); break; switch (magic) { /* BLK ME CREF */ CHECK(VM_FRAME_MAGIC_METHOD, TRUE, TRUE, FALSE); -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/