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

contradictory documentation regarding json::find #565

Closed
Fytch opened this issue Apr 20, 2017 · 1 comment
Closed

contradictory documentation regarding json::find #565

Fytch opened this issue Apr 20, 2017 · 1 comment
Assignees
Milestone

Comments

@Fytch
Copy link

Fytch commented Apr 20, 2017

Consider the table Container function overview. It states that json::find will always return json::end() for objects. Likewise ought json::count to return 0. However, the source code makes it very clear, that said information pertains to any JSON value type but objects. My guess is that both remarks (returns end()) and (returns 0) are supposed to be in the column 'array', not in the column 'object'. This assumption is supported by the fact that another part of the documentation also patently states that objects, not arrays, are the exception with respect to json::find and json::count.

nlohmann added a commit that referenced this issue Apr 23, 2017
The documentation mismatched the actual code.
@nlohmann
Copy link
Owner

Thanks a lot!

@nlohmann nlohmann self-assigned this Apr 23, 2017
@nlohmann nlohmann added this to the Release 3.0.0 milestone Apr 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants