Fix comments lexer
This commit is contained in:
@@ -61,7 +61,8 @@ void Lexer::skip_whitespace() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void Lexer::skip_comment() {
|
void Lexer::skip_comment() {
|
||||||
if (peek() == '/' && peek_next() == '/') {
|
if (peek() == '/') {
|
||||||
|
advance();
|
||||||
while (peek() != '\n' && !is_at_end()) {
|
while (peek() != '\n' && !is_at_end()) {
|
||||||
advance();
|
advance();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user