diff options
Diffstat (limited to 'dis.c')
-rw-r--r-- | dis.c | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -39,6 +39,11 @@ static size_t disasm_instr_h(Chunk *ch, size_t ip, int depth) { print_const(ch, ix); break; } + case OP_GETLOCAL: { + uint8_t ix = ch->bc.d[ip++]; + printf("getlocal #%d\n",ix); + break; + } case OP_SETGLOBAL: { uint8_t ix = ch->bc.d[ip++]; printf("setglobal #%d\t; ",ix); @@ -50,6 +55,11 @@ static size_t disasm_instr_h(Chunk *ch, size_t ip, int depth) { printf("call #%hhu\n",nargs); break; } + case OP_ENDSCOPE: { + uint8_t nlocals = ch->bc.d[ip++]; + printf("endscope #%hhu\n",nlocals); + break; + } #define RSHORT() (uint16_t)( ch->bc.d[ip-2] | ch->bc.d[ip-1] << 8 ) case OP_SKIP: { ip += 2; |