-
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
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
Support for bad commas #1429
Labels
solution: duplicate
the issue is a duplicate; refer to the linked issue instead
Comments
Wouldn't that be breaking the JSON spec though? I'm pretty sure there are tests where that is specifically and explicitly supposed to fail and those conformance tests would no longer pass then? |
Maybe there could be a library wide switch or #define toggling this behavior. |
This is a duplicate of #376. This library will not support inputs that are not conforming to RFC 8259. |
nlohmann
added
the
solution: duplicate
the issue is a duplicate; refer to the linked issue instead
label
Jan 14, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Some of the projects I work on use man-made Jsons as config files. At start it is nice, then people start to forget some commas at the end of objects/arrays. When using Newtonsoft's Json.Net, it handles it gracefully, just ignoring. When using yours, it gives me an error. Thus, I have to correct some files from time to time so that they can be read.
I love your lib and that feature would make my life easier.
A minimal Json with bad commas:
As I see it, the comma puts the lib in a state where it expects some other member, but it gets a } instead. Thus, the grammar must be slightly altered to allow , } as just being a }. Same goes for ,] being threated as just a ]
Thanks for the Lib :)
The text was updated successfully, but these errors were encountered: