In the course of splitting the scanner, so that we have a more state-less scanner and therefore more freedom in the parser, there are two "features" that I would like to discuss, because I don't think we should keep them (as are).
- Adding a trailing semi-colon I think we should not. I understand worries about backward compatibility, but I'm not sure there are really projects using this feature of Bison, because, as I already reported, I have mainly seen projects using Bison as a Yacc, in which case the semicolon is no longer added. How about making a warning in 2.4, and removing the "feature" in the future? - The "arbitrary C-code after %union". This should follow the same path IMHO. Actually, I can't imagine anything but a simple id to be valid here, so I also propose to replace immediately the "arbitrary C-code after %union" by a simple id. This is the last issue where we need some form of state in our grammar scanner.
