Remove deprecated RGBASM features (#1215)

- Escaped commas "\," inside strings
- `name: MACRO` syntax
- `__FILE__` and `__LINE__`
- `-H/--nop-after-halt` and `-l/--auto-ldh` on by default
This commit is contained in:
Rangi
2023-11-04 18:22:46 -04:00
committed by GitHub
parent 28d92b7be3
commit 46e67ee078
20 changed files with 60 additions and 152 deletions

1
test/asm/.gitignore vendored
View File

@@ -1,3 +1,2 @@
/quote\"file.*
/version.asm
/version.out

View File

@@ -1 +0,0 @@
PRINTLN "{__FILE__}"

View File

@@ -1,2 +0,0 @@
warning: file-sym.asm(1): [-Wobsolete]
`__FILE__` is deprecated

View File

@@ -1 +0,0 @@
"file-sym.asm"

View File

@@ -1,4 +1,3 @@
SECTION "Label testing", WRAMX
Lab:
@@ -7,7 +6,7 @@ SECTION "Label testing", WRAMX
: ; anonymous
mac: MACRO
MACRO mac
println "\1"
ENDM
mac :

View File

@@ -1,2 +0,0 @@
warning: label-indent.asm(10): [-Wobsolete]
`mac: MACRO` is deprecated; use `MACRO mac`

View File

@@ -1 +1 @@
:
:

View File

@@ -1,15 +1,12 @@
MACRO new ; comment
println "in with the ", \1
ENDM ; comment
new 2
old: MACRO ; comment
println "out with the ", \1
ENDM ; comment
MACRO new ; comment
println "in with the ", \1
ENDM ; comment
old 1
new 2
bad1: MACRO bad2 ; comment
println "which?"
ENDM ; comment

View File

@@ -1,7 +1,7 @@
warning: macro-syntax.asm(2): [-Wobsolete]
`old: MACRO` is deprecated; use `MACRO old`
error: macro-syntax.asm(13):
syntax error, unexpected identifier, expecting newline
error: macro-syntax.asm(15):
error: macro-syntax.asm(7):
syntax error, unexpected MACRO
error: macro-syntax.asm(8):
Macro argument '\1' not defined
error: macro-syntax.asm(9):
syntax error, unexpected ENDM
error: Assembly aborted (2 errors)!
error: Assembly aborted (3 errors)!

View File

@@ -1,3 +1,2 @@
out with the $1
in with the $2
which?
out with the

View File

@@ -1,5 +1,7 @@
error: macro-syntax.asm(13):
error: macro-syntax.asm(7):
syntax error
error: macro-syntax.asm(15):
error: macro-syntax.asm(8):
Macro argument '\1' not defined
error: macro-syntax.asm(9):
syntax error
error: Assembly aborted (2 errors)!
error: Assembly aborted (3 errors)!