File tree 3 files changed +13
-1
lines changed
3 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -63,6 +63,8 @@ const char* get_opcode_name(Opcode opnum)
63
63
case OP_SUBSCRIPT_W: return " subsw" ;
64
64
case OP_SUBSCRIPT_R: return " subsr" ;
65
65
case OP_BIND: return " bind" ;
66
+ case OP_BSCOPE: return " bscope" ;
67
+ case OP_ESCOPE: return " escope" ;
66
68
EMPTY_SWITCH_DEFAULT_CASE ();
67
69
}
68
70
#undef CASE
Original file line number Diff line number Diff line change @@ -60,7 +60,9 @@ namespace clever {
60
60
&&OP_BW_RS, \
61
61
&&OP_SUBSCRIPT_W,\
62
62
&&OP_SUBSCRIPT_R,\
63
- &&OP_BIND
63
+ &&OP_BIND, \
64
+ &&OP_BSCOPE, \
65
+ &&OP_ESCOPE
64
66
#endif
65
67
66
68
// / VM opcodes
@@ -114,6 +116,8 @@ enum Opcode {
114
116
OP_SUBSCRIPT_W,// Used for subscript operator (write mode)
115
117
OP_SUBSCRIPT_R,// Used for subscript operator (read mode)
116
118
OP_BIND, // Used for runtime binding
119
+ OP_BSCOPE, // Used for begin scope marker
120
+ OP_ESCOPE, // 50 - Used for end scope marker
117
121
NUM_OPCODES
118
122
};
119
123
Original file line number Diff line number Diff line change @@ -983,6 +983,12 @@ void VM::run()
983
983
}
984
984
DISPATCH;
985
985
986
+ OP (OP_BSCOPE):
987
+ DISPATCH;
988
+
989
+ OP (OP_ESCOPE):
990
+ DISPATCH;
991
+
986
992
OP (OP_HALT): goto exit ;
987
993
END_OPCODES;
988
994
You can’t perform that action at this time.
0 commit comments