Add support for ANSI escape sequences in the Lexer. In most cases, this merely provides a superior error recovery experience (we diagnose and skip over them, as we do with Unicode whitespace), but for ANSI color codes, normalize them and include them in identifiers, as suggested on slides 52 and 53 of this presentation by Bjarne Stroustrup:
Details
Details
- Reviewers
- None
Diff Detail
Diff Detail
Event Timeline
Comment Actions
Any chance of test cases?
Does this produce any ambiguities in the grammar? Or is it strictly turning invalid cases into valid ones?