Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add test for e.g. [[], :@] #83

Open
cemerick opened this issue Sep 29, 2021 · 1 comment
Open

Add test for e.g. [[], :@] #83

cemerick opened this issue Sep 29, 2021 · 1 comment

Comments

@cemerick
Copy link

Some parsers have demonstrated difficulty with colon-prefixed plain scalars within flow sequences, e.g.:

[[], :@]
---
[[], :%]
---
[[], :^]
---
[[], :$]
---
[[], ::]
---
[[], :\t]
---
[[], :`]

These are valid yaml documents, parsed as expected by e.g. libfyaml, libyaml, and others; but e.g. pyyaml, SnakeYAML, YAML:PP, Ruamel, and JS yaml (the last as a result of a regression, now fixed) fail on some or all of them, some requiring the leading flow sequence as the first element in the outer flow sequence, some not.

@ingydotnet
Copy link
Member

https://play.yaml.io/main/parser?input=Wzp4XQ==

[:x] causes the same results across all parsers as all the cases above.

Adding a test for that.

https://play.yaml.io/main/parser?input=Wz94XQ== is another interesting one. Even more parsers get that wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants