From cd7a2e97836e48b854e42e553dcf21ee3c1fdde0 Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Thu, 2 Jul 2020 10:25:32 -0700 Subject: [PATCH] binpac: Squash two rules into one with a wildcard --- tools/binpac/src/pac_scan.ll | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/tools/binpac/src/pac_scan.ll b/tools/binpac/src/pac_scan.ll index 7eab510cee..7917fa98a1 100644 --- a/tools/binpac/src/pac_scan.ll +++ b/tools/binpac/src/pac_scan.ll @@ -217,12 +217,7 @@ ESCSEQ (\\([^\n]|[0-7]{3}|x[[:xdigit:]]{2})) return TOK_NUMBER; } -{ID} { - yylval.id = new ID(yytext); - return TOK_ID; - } - -{ID}::{ID} { +{ID}(::{ID})* { yylval.id = new ID(yytext); return TOK_ID; }