ruby-changes:37817
From: ko1 <ko1@a...>
Date: Mon, 9 Mar 2015 06:44:19 +0900 (JST)
Subject: [ruby-changes:37817] ko1:r49898 (trunk): * vm_insnhelper.c (lep_svar_set): add WBs.
ko1 2015-03-09 06:44:00 +0900 (Mon, 09 Mar 2015) New Revision: 49898 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=49898 Log: * vm_insnhelper.c (lep_svar_set): add WBs. Modified files: trunk/ChangeLog trunk/vm_insnhelper.c Index: ChangeLog =================================================================== --- ChangeLog (revision 49897) +++ ChangeLog (revision 49898) @@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Mon Mar 9 06:43:21 2015 Koichi Sasada <ko1@a...> + + * vm_insnhelper.c (lep_svar_set): add WBs. + Mon Mar 9 06:19:06 2015 Koichi Sasada <ko1@a...> * internal.h: define rb_cref_t and change to use it. Index: vm_insnhelper.c =================================================================== --- vm_insnhelper.c (revision 49897) +++ vm_insnhelper.c (revision 49898) @@ -196,21 +196,21 @@ lep_svar_set(rb_thread_t *th, VALUE *lep https://github.com/ruby/ruby/blob/trunk/vm_insnhelper.c#L196 else if (nd_type(svar) == NODE_CREF) { const rb_cref_t *cref = (rb_cref_t *)svar; svar = *svar_place = NEW_IF(Qnil, Qnil, Qnil); - svar->nd_reserved = (VALUE)cref; + RB_OBJ_WRITE(svar, &svar->nd_reserved, (VALUE)cref); } switch (key) { case VM_SVAR_LASTLINE: - svar->u1.value = val; + RB_OBJ_WRITE(svar, &svar->u1.value, val); return; case VM_SVAR_BACKREF: - svar->u2.value = val; + RB_OBJ_WRITE(svar, &svar->u2.value, val); return; default: { VALUE ary = svar->u3.value; if (NIL_P(ary)) { - svar->u3.value = ary = rb_ary_new(); + RB_OBJ_WRITE(svar, &svar->u3.value, ary = rb_ary_new()); } rb_ary_store(ary, key - VM_SVAR_EXTRA_START, val); } -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/