From 187f88aa50f253eb670cdc415e9bc315ca289bb6 Mon Sep 17 00:00:00 2001 From: ISSOtm Date: Thu, 26 Mar 2020 23:10:51 +0100 Subject: [PATCH] Only copy necessary characters for bare labels --- src/asm/asmy.y | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/asm/asmy.y b/src/asm/asmy.y index 945af5bd..4e02ae64 100644 --- a/src/asm/asmy.y +++ b/src/asm/asmy.y @@ -669,8 +669,11 @@ line : label scoped_label_bare : T_LABEL { warning(WARNING_OBSOLETE, "Non-local labels without a colon are deprecated"); + strcpy($$, $1); + } + | T_LOCAL_ID { + strcpy($$, $1); } - | T_LOCAL_ID ; scoped_label : T_LABEL ':' { strcpy($$, $1);