mewmew / uc

A compiler for the µC language.
58 stars 5 forks source link

lexer: New line should not be part of line comment lexemes #22

Closed mewmew closed 8 years ago

mewmew commented 8 years ago

Currently the Gocc generated lexer and the hand-written lexer do not agree on whether trailing new line characters should be part of line comment lexemes.

After discussing the manner and evaluating how other projects handle this issue (e.g. the scanner package in Go), we've decided to not include trailing new line characters in the lexeme of line comments.

mewmew commented 8 years ago

It remains an open question whether the Gocc lexer should be patched to conform to this behaviour.