mirror of
https://github.com/open-simh/simtools.git
synced 2026-01-13 15:27:18 +00:00
Too bad we can't issue a diagnostic here now; we just return failure and the caller will probably next try a whitespace delimited string next.
36 lines
857 B
Plaintext
36 lines
857 B
Plaintext
;;;;;
|
|
;
|
|
; Test that commas create empty macro arguments.
|
|
;
|
|
.macro tstarg a1,a2,a3,a4
|
|
.narg label
|
|
.endm
|
|
|
|
start: tstarg ; 0 args
|
|
tstarg 123 ; 1 arg
|
|
tstarg 1, ; 2 args
|
|
tstarg ,2 ; 2 args
|
|
tstarg , ; 2 args
|
|
tstarg ,, ; 3 args
|
|
tstarg 1,, ; 3 args
|
|
tstarg ,,3 ; 3 args
|
|
tstarg 1,,3 ; 3 args
|
|
tstarg 1,2,3 ; 3 args
|
|
|
|
;;;;;
|
|
;
|
|
; Test what happens if we have invalid bracketed strings.
|
|
; For now we fall back to treating them like unbracketed strings,
|
|
; that will hopefully alert the user the best.
|
|
;
|
|
.macro braket arg
|
|
; arg
|
|
.endm
|
|
|
|
braket <plain>
|
|
braket ^/simple/
|
|
braket <broken
|
|
braket ^/broken
|
|
braket <bro<ken>
|
|
braket <bro<ken> string
|