mirror of https://github.com/status-im/NimYAML.git
Fixed parser code
This commit is contained in:
parent
6edee9c81b
commit
9bd12797d2
|
@ -472,9 +472,8 @@ proc parse*(parser: YamlSequentialParser, s: Stream): YamlStream =
|
|||
assert level.mode == mImplicitBlockMapKey
|
||||
leaveMoreIndentedLevels()
|
||||
case level.mode
|
||||
of mUnknown, mImplicitBlockMapKey, mImplicitBlockMapValue,
|
||||
mExplicitBlockMapKey, mExplicitBlockMapValue,
|
||||
mBlockSequenceItem:
|
||||
of mUnknown, mImplicitBlockMapKey, mBlockMapValue,
|
||||
mExplicitBlockMapKey, mBlockSequenceItem:
|
||||
state = ypBlockAfterAlias
|
||||
else:
|
||||
raiseError("Unexpected alias")
|
||||
|
@ -1012,4 +1011,4 @@ proc parse*(parser: YamlSequentialParser, s: Stream): YamlStream =
|
|||
yieldUnexpectedToken("document end")
|
||||
token = nextToken(lex)
|
||||
if token == tError:
|
||||
raiseError("Lexer error: " & lex.content)
|
||||
raiseError("Lexer error: " & lex.content)
|
||||
|
|
Loading…
Reference in New Issue