mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 10:12:06 +00:00
readIdentifier does not process characters that get truncated
Previously a '.' could be past the truncation limit but still cause the identifier to be marked as local, violating an assertion in `sym_AddLocalLabel`. Fixes #832
This commit is contained in:
11
test/asm/local-truncated.asm
Normal file
11
test/asm/local-truncated.asm
Normal file
@@ -0,0 +1,11 @@
|
||||
SECTION "Test", ROM0
|
||||
|
||||
MACRO a000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001
|
||||
println "truncated :("
|
||||
ENDM
|
||||
|
||||
a012:
|
||||
a012.local
|
||||
|
||||
a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000012:
|
||||
a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000012.local
|
||||
7
test/asm/local-truncated.err
Normal file
7
test/asm/local-truncated.err
Normal file
@@ -0,0 +1,7 @@
|
||||
warning: local-truncated.asm(10): [-Wlong-string]
|
||||
Symbol name too long, got truncated
|
||||
ERROR: local-truncated.asm(10):
|
||||
'a000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001' already defined at local-truncated.asm(3)
|
||||
warning: local-truncated.asm(11): [-Wlong-string]
|
||||
Symbol name too long, got truncated
|
||||
error: Assembly aborted (1 error)!
|
||||
1
test/asm/local-truncated.out
Normal file
1
test/asm/local-truncated.out
Normal file
@@ -0,0 +1 @@
|
||||
truncated :(
|
||||
Reference in New Issue
Block a user