From 364172ff5b0b2be295917b111346ee885a1c46ab Mon Sep 17 00:00:00 2001 From: Devine Lu Linvega Date: Wed, 3 Apr 2024 09:07:51 -0700 Subject: [PATCH] (uxnasm) Fixed issue with long hex values --- src/uxnasm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/uxnasm.c b/src/uxnasm.c index 654778c..d6ef190 100644 --- a/src/uxnasm.c +++ b/src/uxnasm.c @@ -303,7 +303,7 @@ parse(char *w, FILE *f, Context *ctx) case '@': return makelabel(w + 1, 1, ctx); case '&': return makelabel(w, 0, ctx); case '}': return makelabel(makelambda(lambda_stack[--lambda_ptr]), 0, ctx); - case '#': return ishex(w + 1) && writehex(w, ctx); + case '#': return writehex(w, ctx); case '_': return makeref(w + 1, w[0], ptr) && writebyte(0xff, ctx); case ',': return makeref(w + 1, w[0], ptr + 1) && writebyte(findopcode("LIT"), ctx) && writebyte(0xff, ctx); case '-': return makeref(w + 1, w[0], ptr) && writebyte(0xff, ctx); @@ -403,7 +403,7 @@ main(int argc, char *argv[]) { ptr = PAGE; copy("on-reset", scope, 0); - if(argc == 2 && scmp(argv[1], "-v", 2)) return !printf("Uxnasm - Uxntal Assembler, 2 Apr 2024.\n"); + if(argc == 2 && scmp(argv[1], "-v", 2)) return !printf("Uxnasm - Uxntal Assembler, 3 Apr 2024.\n"); if(argc != 3) return error_top("usage", "uxnasm [-v] input.tal output.rom"); if(!assemble(argv[1])) return 1; if(!resolve(argv[2])) return 1;