mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 18:22:07 +00:00
Allow binary AND to be sometimes constant (#976)
This commit is contained in:
17
test/asm/const-and.asm
Normal file
17
test/asm/const-and.asm
Normal file
@@ -0,0 +1,17 @@
|
||||
|
||||
println @ & 0 ; This should produce an error, but not crash
|
||||
|
||||
SECTION "Test", ROM0,ALIGN[4,2]
|
||||
|
||||
ds 40
|
||||
Aligned:
|
||||
|
||||
println Aligned & $0f
|
||||
println ~$fffc & Aligned
|
||||
println Aligned & $1f ; Not constant
|
||||
println @ & $0f
|
||||
|
||||
SECTION "Unaligned", ROM0
|
||||
|
||||
println @ & 0
|
||||
println @ & 1 ; Nope
|
||||
Reference in New Issue
Block a user