From f419f206e54157411ee5276f855c731281c8078a Mon Sep 17 00:00:00 2001 From: Rangi42 Date: Wed, 6 Mar 2024 15:14:17 -0500 Subject: [PATCH] Fix a latent bug with parsing macro args This seems to only have worked by coincidence; `$$` was an undefined value that happened to equal `$1` already. --- src/asm/parser.y | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/asm/parser.y b/src/asm/parser.y index b40d7432..a88f2a7d 100644 --- a/src/asm/parser.y +++ b/src/asm/parser.y @@ -525,7 +525,8 @@ macroargs: fatalerror("Failed to allocate memory for macro arguments: %s\n", strerror(errno)); } | macroargs T_STRING { - $$->append($2); + $1->append($2); + $$ = $1; } ;