biojppm / rapidyaml

Rapid YAML - a library to parse and emit YAML, and do it fast.
MIT License
583 stars 100 forks source link

Issue with empty keys #373

Closed Mr-S-Mirzoev closed 1 year ago

Mr-S-Mirzoev commented 1 year ago

Unlike in most other parsers, empty keys are not supported by ryml.

It is a strange case, but unfortunately, it appeared helpful in one of our company's endeavours.

%YAML 1.2
---
m:
  "": ""
image
biojppm commented 1 year ago

Thanks for reporting.

For the record, empty keys are supported: all of {"": ""}, "": "" and {m: {"":""}} are parsed correctly (and notice the latter is the flow-style equivalent of your example) .

Instead, what you are seeing is a parse failure . Allow some time for investigating and fixing.