Prevent SET from overriding constant symbols

Fixes #341
This commit is contained in:
ISSOtm
2019-08-27 21:07:42 +02:00
parent e33e6e2413
commit e3e18063c6
5 changed files with 37 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
V set 0
V set 1
PRINTT "V={V}\n"
W equ 1
W set 0
rsset 1
X rb 0
X set 0
SECTION "Test", ROM0[1]
Y:
Y set 0

View File

@@ -0,0 +1,8 @@
ERROR: symbol-override.asm(6):
'W' already defined as constant at symbol-override.asm(5)
ERROR: symbol-override.asm(10):
'X' already defined as constant at symbol-override.asm(9)
ERROR: symbol-override.asm(14):
'Y' already defined as non-constant at symbol-override.asm(13)
error: Assembly aborted (3 errors)!
V=$1

View File

@@ -0,0 +1,8 @@
ERROR: -(6):
'W' already defined as constant at -(5)
ERROR: -(10):
'X' already defined as constant at -(9)
ERROR: -(14):
'Y' already defined as non-constant at -(13)
error: Assembly aborted (3 errors)!
V=$1