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

Conformance report for reference #90

Open
miloyip opened this issue Sep 9, 2016 · 1 comment
Open

Conformance report for reference #90

miloyip opened this issue Sep 9, 2016 · 1 comment

Comments

@miloyip
Copy link

miloyip commented Sep 9, 2016

https://github.com/miloyip/nativejson-benchmark/blob/master/sample/conformance_PicoJSON%20(C%2B%2B).md

@kazuho
Copy link
Owner

kazuho commented Sep 9, 2016

Great test! Thank you for reporting this!

For the first three failures reported for validation, we consider them as non-issues. The API of picojson is designed to parse until it sees the end of JSON. And with some of the provided APIs it is possible to obtain the end of the JSON. For example:

const char* json_end = picojson::parse(v, json, json + strlen(json), &err);

The fourth failure (handling of 013) is indeed a bug. Thank you for catching this.

Regarding the roundtrip tests, parsing and encoding of the numbers are done using sprintf / sscanf in picojson. If there is any error, your libc should be blamed for.

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