Closed andreasabel closed 4 years ago
LBNF does not support nested subtraction in regexps, like in
token Name (char - [ "(){};.@\"" ] - [ " \n\t" ]) + ;
It works with parentheses:
token Name ((char - [ "(){};.@\"" ]) - [ " \n\t" ]) + ;
This is translated to Alex as
(($u # [\( \) \{ \} \; \. \@ \"]) # [\ \n \t]) +
which is rejected by Alex. However, Alex supports it without parentheses:
($u # [\( \) \{ \} \; \. \@ \"] # [\ \n \t]) +
Both BNFC and Alex are behaving silly here, I must say.
Fixes:
LBNF does not support nested subtraction in regexps, like in
It works with parentheses:
This is translated to Alex as
which is rejected by Alex. However, Alex supports it without parentheses:
Both BNFC and Alex are behaving silly here, I must say.