From: Paul Eggert Date: Fri, 29 Nov 2002 08:44:40 +0000 (+0000) Subject: "," now elicits a warning, rather than being X-Git-Tag: BISON-1_875~190 X-Git-Url: https://git.saurik.com/bison.git/commitdiff_plain/763ed7a6879a9e57a387bb538607c6be5aa09af4?ds=inline "," now elicits a warning, rather than being a token; this is more compatible with byacc. --- diff --git a/src/scan-gram.l b/src/scan-gram.l index b7d8b509..2ed043f0 100644 --- a/src/scan-gram.l +++ b/src/scan-gram.l @@ -266,11 +266,15 @@ splice (\\[ \f\t\v]*\n)* "=" return EQUAL; ":" rule_length = 0; return COLON; "|" rule_length = 0; return PIPE; - "," return COMMA; ";" return SEMICOLON; [ \f\n\t\v] STEP; + "," { + warn_at (*loc, _("stray `,' treated as white space")); + STEP; + } + {id} { val->symbol = symbol_get (yytext, *loc); rule_length++;