minor fixes

This commit is contained in:
underscorediscovery
2019-10-01 23:28:01 -07:00
parent 19548ec411
commit c4497933e7
2 changed files with 6 additions and 1 deletions

View File

@ -2197,7 +2197,7 @@ static void field(Compiler* compiler, bool canAssign)
// Compiles a read or assignment to [variable].
static void bareName(Compiler* compiler, bool canAssign, Variable variable)
{
// If there's an "=" after a bare name, it's a variable assignment.
// If there's an assignment after a bare name, it's a variable assignment.
if (canAssign && isAssignment(compiler))
{
// Compile the assignment and right-hand side.

View File

@ -177,6 +177,11 @@ static int dumpInstruction(WrenVM* vm, ObjFn* fn, int i, int* lastLine)
case CODE_STORE_FIELD: BYTE_INSTRUCTION("STORE_FIELD");
case CODE_POP: printf("POP\n"); break;
case CODE_PUSH: {
int count = READ_BYTE();
printf("PUSH %d\n", count);
break;
}
case CODE_CALL_0:
case CODE_CALL_1: