summaryrefslogtreecommitdiff
path: root/dis.c
diff options
context:
space:
mode:
Diffstat (limited to 'dis.c')
-rw-r--r--dis.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/dis.c b/dis.c
index 2939384..0ca77e7 100644
--- a/dis.c
+++ b/dis.c
@@ -60,6 +60,11 @@ static size_t disasm_instr_h(Chunk *ch, size_t ip, int depth) {
printf("call #%hhu\n",nargs);
break;
}
+ case OP_TAILCALL: {
+ uint8_t nargs = ch->bc.d[ip++];
+ printf("\033[31mtailcall\033[0m #%hhu\n",nargs);
+ break;
+ }
case OP_ENDSCOPE: {
uint8_t nlocals = ch->bc.d[ip++];
printf("endscope #%hhu\n",nlocals);
@@ -107,7 +112,6 @@ static size_t disasm_instr_h(Chunk *ch, size_t ip, int depth) {
default:
printf("unknown opcode %d\n", instr);
- exit(2);
}