yaml / yaml-test-suite

Comprehensive, language independent Test Suite for YAML
MIT License
172 stars 58 forks source link

K54U out.yaml #131

Closed jfudickar closed 2 months ago

jfudickar commented 3 months ago

Why has the out.yaml a explicit document closure?

in.yaml

--- scalar

out.yaml

--- scalar ...

This does not seems logic to me :-)

test.event

+STR +DOC --- =VAL :scalar -DOC -STR

jfudickar commented 3 months ago

Anychance to get some help?

I'm trying to build a new parser in yaml and do not understand why and how the results are generated as they are.

matajoh commented 2 months ago

+1 I am also unclear on why this document end marker is here. It would be good to get some clear guidance on this.

matajoh commented 2 months ago

This also happens in PUW8:

# in.yaml
---
a: b
---
# out.yaml
---
a: b
---
...

Given that 6XDY is almost identical and omits the docend marker, it makes it very hard to write an emitter which agrees with these dump/emit files.

matajoh commented 2 months ago

Also XLQ9.

jfudickar commented 2 months ago

For the PUW8 i have a possible explanation: The document in the stream has been started, but no further activities. To signal that it's over the endmark is shown.

At the end I have some more unclear sets. My current list is at 19 (from 140 i'm currently handling) :-)

jfudickar commented 2 months ago

I will close this now. I had a discussion the yaml dev chat, and the out.yaml are more to be seen as an example then as a hard guideline. The main rule for passing the test is the test.event comparison. I will do additionally a reparsing of my result yaml to see if in the second run the same events are detected. This should mean that my output is in the minimum correct generated.

jfudickar commented 2 months ago

+1 I am also unclear on why this document end marker is here. It would be good to get some clear guidance on this.

I would suggest for further questions also to use the matrix based dev chat: #chat-dev:yaml.io