From a8df9721d3f3d37955696f23389a63184eb5ecbd Mon Sep 17 00:00:00 2001 From: David Given Date: Wed, 12 Sep 2018 22:27:39 +0200 Subject: [PATCH] Adding new tokens to the assembler isn't quite as easy as I thought: ensure that NUMBERF is stored properly in the temporary file. --- mach/proto/as/comm5.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mach/proto/as/comm5.c b/mach/proto/as/comm5.c index b91ad3466..9dc7a80bb 100644 --- a/mach/proto/as/comm5.c +++ b/mach/proto/as/comm5.c @@ -144,6 +144,7 @@ void putval(int c) break; #endif case STRING: + case NUMBERF: v = stringlen; putc(c, tempfile); putc(c >> 8, tempfile); @@ -238,6 +239,7 @@ int getval(int c) break; #endif case STRING: + case NUMBERF: getval(getc(tempfile) + NUMBER0); stringlen = n = yylval.y_valu; p = stringbuf; @@ -456,6 +458,7 @@ floatconstant: *p++ = c; c = nextchar(); } while (isdigit(c) || (c == '.') || (c == 'E') || (c == '+') || (c == '-')); + peekc = c; *p = '\0'; stringbuf = strdup(num); -- 2.34.1