mirror of
https://github.com/nim-lang/Nim.git
synced 2026-01-08 22:13:29 +00:00
fix bug with unexpected tkInvalid,tkEof,tkComment
This commit is contained in:
@@ -303,6 +303,8 @@ proc parseSymbol(p: var TParser, allowNil = false): PNode =
|
||||
if accm == "":
|
||||
parMessage(p, errIdentifierExpected, p.tok)
|
||||
break
|
||||
of tkEof, tkInvalid, tkComment:
|
||||
parMessage(p, errIdentifierExpected, p.tok)
|
||||
else:
|
||||
accm.add(tokToStr(p.tok))
|
||||
getTok(p)
|
||||
|
||||
Reference in New Issue
Block a user