uxn

Varvara Ordinator, written in ANSI C(SDL2)
git clone https://git.eamoncaddigan.net/uxn.git
Log | Files | Refs | README | LICENSE

commit e7f234f55b1998c899c60a3796ea1e0a6c3446b8
parent 3474b3a4f1e3e1b07a8a63f247e0dfcc890e846d
Author: Andrew Alderwick <andrew@alderwick.co.uk>
Date:   Wed, 21 Apr 2021 21:01:50 +0100

Reinstated check for labels in zero page

Diffstat:
Mprojects/examples/gui.animation.usm | 2+-
Msrc/assembler.c | 2++
2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/projects/examples/gui.animation.usm b/projects/examples/gui.animation.usm @@ -3,7 +3,7 @@ |00 @System [ &vector $2 &pad $6 &r $2 &g $2 &b $2 ] |20 @Screen [ &vector $2 &width $2 &height $2 &pad $2 &x $2 &y $2 &addr $2 &color $1 ] -|0100 +|0000 @dvd [ &x $2 &y $2 &dx $1 &dy $1 ] diff --git a/src/assembler.c b/src/assembler.c @@ -233,6 +233,8 @@ parsetoken(char *w) Label *l; Macro *m; if(w[0] == '.' && (l = findlabel(w + 1))) { /* zero-page */ + if(l->addr > 0xff) + return error("Address is not in zero page", w); pushbyte(l->addr, 1); return ++l->refs; } else if(w[0] == ',' && (l = findlabel(w + 1))) {