summaryrefslogtreecommitdiffstats
path: root/bytecode.c
diff options
context:
space:
mode:
authorStephen Dolan <mu@netsoc.tcd.ie>2012-12-03 20:00:36 +0000
committerStephen Dolan <mu@netsoc.tcd.ie>2012-12-03 20:02:02 +0000
commit5f6a95c7b574c6d0f52e62e2405c550606a5ce75 (patch)
treeb31fc40e29095972db981ed9dc18429dd4aabce7 /bytecode.c
parentfadeb66365cb8da2cddf3993ad139736922852ae (diff)
General cleanup - rename a few things, delete dead code.
Diffstat (limited to 'bytecode.c')
-rw-r--r--bytecode.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/bytecode.c b/bytecode.c
index a18f0d90..26f8d36d 100644
--- a/bytecode.c
+++ b/bytecode.c
@@ -6,7 +6,7 @@
#include "opcode.h"
static int bytecode_operation_length(uint16_t* codeptr) {
- if (opcode_describe(*codeptr)->flags & OP_HAS_VARIABLE_LENGTH_ARGLIST) {
+ if (*codeptr == CALL_JQ) {
return 4 + codeptr[1] * 2;
} else {
return opcode_length(*codeptr);
@@ -41,7 +41,7 @@ void dump_operation(struct bytecode* bc, uint16_t* codeptr) {
printf("%s", op->name);
if (op->length > 1) {
uint16_t imm = bc->code[pc++];
- if (op->flags & OP_HAS_VARIABLE_LENGTH_ARGLIST) {
+ if (op->op == CALL_JQ) {
for (int i=0; i<imm+1; i++) {
uint16_t level = bc->code[pc++];
uint16_t idx = bc->code[pc++];