fix multiline comments
This commit is contained in:
parent
c103307469
commit
45b4528e73
1 changed files with 2 additions and 2 deletions
4
lexer.go
4
lexer.go
|
|
@ -185,9 +185,9 @@ func (l *Lexer) NextToken() (Token, error) {
|
|||
case '*':
|
||||
return l.makeToken(TokenStar), nil
|
||||
case '/':
|
||||
if l.match('*') {
|
||||
if l.accept('*') {
|
||||
for !l.isAtEnd() {
|
||||
if l.match('*') && l.match('/') {
|
||||
if l.accept('*') && l.accept('/') {
|
||||
break
|
||||
}
|
||||
l.advance()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue