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 #74

Open
miloyip opened this issue Sep 9, 2016 · 2 comments
Open

Conformance report for reference #74

miloyip opened this issue Sep 9, 2016 · 2 comments

Comments

@miloyip
Copy link

miloyip commented Sep 9, 2016

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

@tgockel
Copy link
Owner

tgockel commented Sep 10, 2016

This might seem odd, but the parse validation section are intentional mistakes. If you use the strict parser, these should all fail properly. Instead of using jsonv::parse(text), use jsonv::parse(text, jsonv::parse_options::create_strict()).

@miloyip
Copy link
Author

miloyip commented Sep 10, 2016

I just tried:

            // pr->root = parse(string_view(json, length));
            pr->root = parse(string_view(json, length), parse_options::create_strict());

But it failed on parsing this JSON

parsing error:15472:21: Numbers cannot start with a leading '0': "0.087"

and the 15472 line is:

    "completed_in": 0.087,

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