diff --git a/apps/zasm/directive.asm b/apps/zasm/directive.asm index 6f00493..e83fcf4 100644 --- a/apps/zasm/directive.asm +++ b/apps/zasm/directive.asm @@ -50,7 +50,7 @@ handleDW: handleEQU: call zasmIsFirstPass - jr z, .begin + jr nz, .begin ; first pass? .equ are noops xor a ret @@ -74,7 +74,6 @@ handleEQU: call toWord call readWord ld hl, scratchpad - ld a, (hl) call parseNumberOrSymbol jr nz, .error ld hl, DIREC_SCRATCHPAD diff --git a/apps/zasm/tests/test1.asm b/apps/zasm/tests/test1.asm index 5b1c87c..aff03fb 100644 --- a/apps/zasm/tests/test1.asm +++ b/apps/zasm/tests/test1.asm @@ -11,5 +11,6 @@ label2: .dw 3742 .dw 0x3742 ld a, (label1) -.equ foobar 0x1234 - ld hl, foobar +.equ foo 0x1234 +.equ bar foo + ld hl, bar