mirror of https://github.com/status-im/NimYAML.git
(hopefully) final event output fix
This commit is contained in:
parent
b15f3dbae9
commit
d6ace28775
|
@ -1120,7 +1120,10 @@ proc display*(p: YamlParser, event: YamlStreamEvent): string
|
|||
result = "+DOC"
|
||||
when defined(yamlScalarRepInd):
|
||||
if event.explicitDirectivesEnd: result &= " ---"
|
||||
of yamlEndDoc: result = "-DOC"
|
||||
of yamlEndDoc:
|
||||
result = "-DOC"
|
||||
when defined(yamlScalarRepInd):
|
||||
if event.explicitDocumentEnd: result &= " ..."
|
||||
of yamlStartMap:
|
||||
result = "+MAP" & p.renderAttrs(event.mapTag, event.mapAnchor, true)
|
||||
of yamlStartSeq:
|
||||
|
|
|
@ -270,7 +270,10 @@ proc `$`*(event: YamlStreamEvent): string {.raises: [].} =
|
|||
result = "+DOC"
|
||||
when defined(yamlScalarRepInd):
|
||||
if event.explicitDirectivesEnd: result &= " ---"
|
||||
of yamlEndDoc: result = "-DOC"
|
||||
of yamlEndDoc:
|
||||
result = "-DOC"
|
||||
when defined(yamlScalarRepInd):
|
||||
if event.explicitDocumentEnd: result &= " ..."
|
||||
of yamlStartMap: result = "+MAP" & renderAttrs(event.mapTag, event.mapAnchor)
|
||||
of yamlStartSeq: result = "+SEQ" & renderAttrs(event.seqTag, event.seqAnchor)
|
||||
of yamlScalar:
|
||||
|
|
Loading…
Reference in New Issue