You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Robert Kuhfß edited this page Oct 30, 2018
·
1 revision
Labels in SPASM are much like TASM 3.2. The preferred style of label is the colon terminated, like this:
label:
ld a,30
ret
With labels, you can use this syntax:
label: ld a,25 \ ret
Also permitted is the non-colon terminated line label.
label
xor a
ld (ram_loc), a
ret
Like above, the following is acceptable:
label2 inc a
ld (ram_loc+1),a
ret
Arithmetic
SPASM uses no-questions-asked order of operations: left-to-right. This is prefered for speed reasons as well as ambiguity between operators -- who really knows which of these operators should come first? % or &?
The operators available are as follows: * / - + % ^ & | << >>