Add more checks to section creation in RGBASM

Fixes rednex#471, but also backports a couple more checks from RGBLINK
This commit is contained in:
ISSOtm
2020-02-04 02:05:33 +01:00
parent a4fe274c25
commit 8c4b473d6f
5 changed files with 37 additions and 14 deletions

15
test/asm/fixed-oob.err Normal file
View File

@@ -0,0 +1,15 @@
ERROR: fixed-oob.asm(1):
Section "ROM0"'s fixed address 0xbabe is outside of range [0; 0x7fff]
ERROR: fixed-oob.asm(3):
Section "ROMX"'s fixed address 0xbeef is outside of range [0x4000; 0x7fff]
ERROR: fixed-oob.asm(5):
Section "VRAM"'s fixed address 0xc0de is outside of range [0x8000; 0x9fff]
ERROR: fixed-oob.asm(7):
Section "SRAM"'s fixed address 0xcafe is outside of range [0xa000; 0xbfff]
ERROR: fixed-oob.asm(11):
Section "WRAMX"'s fixed address 0xdad is outside of range [0xd000; 0xdfff]
ERROR: fixed-oob.asm(13):
Section "OAM"'s fixed address 0xcab is outside of range [0xfe00; 0xfe9f]
ERROR: fixed-oob.asm(15):
Section "HRAM"'s fixed address 0xbad is outside of range [0xff80; 0xfffe]
error: Assembly aborted (7 errors)!