@@ -603,12 +603,12 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
603603 int imm = InstructionView (i).sc ();
604604 if (ttisinteger (v1)) {
605605 lua_Integer iv1 = ivalue (v1);
606- pc++; setivalue (ra, iop (L, iv1, imm));
606+ pc++; ra-> setInt ( iop (L, iv1, imm));
607607 }
608608 else if (ttisfloat (v1)) {
609609 lua_Number nb = fltvalue (v1);
610610 lua_Number fimm = cast_num (imm);
611- pc++; setfltvalue (ra, fop (L, nb, fimm));
611+ pc++; ra-> setFloat ( fop (L, nb, fimm));
612612 }
613613 };
614614
@@ -617,7 +617,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
617617 lua_Number n1, n2;
618618 if (tonumberns (v1, n1) && tonumberns (v2, n2)) {
619619 StkId ra = RA (i);
620- pc++; setfltvalue ( s2v (ra), fop (L, n1, n2));
620+ pc++; s2v (ra)-> setFloat ( fop (L, n1, n2));
621621 }
622622 };
623623
@@ -642,7 +642,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
642642 StkId ra = RA (i);
643643 lua_Integer i1 = ivalue (v1);
644644 lua_Integer i2 = ivalue (v2);
645- pc++; setivalue ( s2v (ra), iop (L, i1, i2));
645+ pc++; s2v (ra)-> setInt ( iop (L, i1, i2));
646646 }
647647 else {
648648 op_arithf_aux (v1, v2, fop, i);
@@ -672,7 +672,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
672672 lua_Integer i2 = ivalue (v2);
673673 if (tointegerns (v1, &i1)) {
674674 StkId ra = RA (i);
675- pc++; setivalue ( s2v (ra), op (i1, i2));
675+ pc++; s2v (ra)-> setInt ( op (i1, i2));
676676 }
677677 };
678678
@@ -683,7 +683,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
683683 lua_Integer i1, i2;
684684 if (tointegerns (v1, &i1) && tointegerns (v2, &i2)) {
685685 StkId ra = RA (i);
686- pc++; setivalue ( s2v (ra), op (i1, i2));
686+ pc++; s2v (ra)-> setInt ( op (i1, i2));
687687 }
688688 };
689689
@@ -768,13 +768,13 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
768768 vmcase (OP_LOADI) {
769769 StkId ra = RA (i);
770770 lua_Integer b = InstructionView (i).sbx ();
771- setivalue ( s2v (ra), b);
771+ s2v (ra)-> setInt ( b);
772772 vmbreak;
773773 }
774774 vmcase (OP_LOADF) {
775775 StkId ra = RA (i);
776776 int b = InstructionView (i).sbx ();
777- setfltvalue ( s2v (ra), cast_num (b));
777+ s2v (ra)-> setFloat ( cast_num (b));
778778 vmbreak;
779779 }
780780 vmcase (OP_LOADK) {
@@ -859,7 +859,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
859859 luaV_fastgeti (rb, c, s2v (ra), tag);
860860 if (tagisempty (tag)) {
861861 TValue key;
862- setivalue (& key, c);
862+ key. setInt ( c);
863863 Protect ([&]() { luaV_finishget (L, rb, &key, ra, tag); });
864864 }
865865 vmbreak;
@@ -915,7 +915,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
915915 luaV_finishfastset (L, s2v (ra), rc);
916916 else {
917917 TValue key;
918- setivalue (& key, b);
918+ key. setInt ( b);
919919 Protect ([&]() { luaV_finishset (L, s2v (ra), &key, rc, hres); });
920920 }
921921 vmbreak;
@@ -1018,7 +1018,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
10181018 int ic = InstructionView (i).sc ();
10191019 lua_Integer ib;
10201020 if (tointegerns (rb, &ib)) {
1021- pc++; setivalue ( s2v (ra), luaV_shiftl (ic, ib));
1021+ pc++; s2v (ra)-> setInt ( luaV_shiftl (ic, ib));
10221022 }
10231023 vmbreak;
10241024 }
@@ -1028,7 +1028,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
10281028 int ic = InstructionView (i).sc ();
10291029 lua_Integer ib;
10301030 if (tointegerns (rb, &ib)) {
1031- pc++; setivalue ( s2v (ra), luaV_shiftl (ib, -ic));
1031+ pc++; s2v (ra)-> setInt ( luaV_shiftl (ib, -ic));
10321032 }
10331033 vmbreak;
10341034 }
@@ -1118,10 +1118,10 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
11181118 lua_Number nb;
11191119 if (ttisinteger (rb)) {
11201120 lua_Integer ib = ivalue (rb);
1121- setivalue ( s2v (ra), intop (-, 0 , ib));
1121+ s2v (ra)-> setInt ( intop (-, 0 , ib));
11221122 }
11231123 else if (tonumberns (rb, nb)) {
1124- setfltvalue ( s2v (ra), luai_numunm (L, nb));
1124+ s2v (ra)-> setFloat ( luai_numunm (L, nb));
11251125 }
11261126 else
11271127 Protect ([&]() { luaT_trybinTM (L, rb, rb, ra, TMS::TM_UNM); });
@@ -1132,7 +1132,7 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
11321132 TValue *rb = vRB (i);
11331133 lua_Integer ib;
11341134 if (tointegerns (rb, &ib)) {
1135- setivalue ( s2v (ra), intop (^, ~l_castS2U (0 ), ib));
1135+ s2v (ra)-> setInt ( intop (^, ~l_castS2U (0 ), ib));
11361136 }
11371137 else
11381138 Protect ([&]() { luaT_trybinTM (L, rb, rb, ra, TMS::TM_BNOT); });
@@ -1368,9 +1368,9 @@ void luaV_execute (lua_State *L, CallInfo *ci) {
13681368 if (count > 0 ) { /* still more iterations? */
13691369 lua_Integer step = ivalue (s2v (ra + 1 ));
13701370 lua_Integer idx = ivalue (s2v (ra + 2 )); /* control variable */
1371- chgivalue ( s2v (ra), l_castU2S (count - 1 )); /* update counter */
1371+ s2v (ra)-> changeInt ( l_castU2S (count - 1 )); /* update counter */
13721372 idx = intop (+, idx, step); /* add step to index */
1373- chgivalue ( s2v (ra + 2 ), idx); /* update control variable */
1373+ s2v (ra + 2 )-> changeInt ( idx); /* update control variable */
13741374 pc -= InstructionView (i).bx (); /* jump back */
13751375 }
13761376 }
0 commit comments