9c98769a33
Permit opcode names to be used as labels if and only if they are succeeded by a colon. Opcode names occurring when parsing expressions are all treated as labels; a leading colon occurred when parsing an instruction forces a parser restart with the instruction forcibly treated as an identifier.
10 lines
190 B
NASM
10 lines
190 B
NASM
;
|
|
; Test "instruction as label" -- make opcodes legal as labels if
|
|
; they are followed by a colon.
|
|
;
|
|
|
|
do: jmp incbin+2
|
|
dw do, add, sub, incbin
|
|
add: jmp add-2
|
|
sub: jmp do+2
|
|
incbin: dw $-sub
|