Repository navigation
Add front methods to json_pointers (implements #4889) - #5152
Merged
Merged
Conversation
…der to facilitate root-to-leaf traversals of JSON object trees. (nlohmann#4889) Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com>
Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com>
trdesilva
force-pushed
the
jsonPointerFront4889
branch
from
April 28, 2026 03:05
c216462 to
acb6b66
Compare
🔴 Amalgamation check failed! 🔴The source code has not been amalgamated. @trdesilva |
…hods in mkdocs, and fixed errors in documented complexity for those methods. Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com>
nlohmann
requested changes
May 11, 2026
nlohmann
left a comment
Owner
There was a problem hiding this comment.
There is a compilation error for GCC 4.8, see https://github.com/nlohmann/json/actions/runs/25653351091/job/75317189719?pr=5152
Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com>
trdesilva
force-pushed
the
jsonPointerFront4889
branch
from
May 12, 2026 00:03
1372365 to
0616a72
Compare
Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com>
🔴 Amalgamation check failed! 🔴The source code has not been amalgamated. @trdesilva |
nlohmann
requested changes
May 12, 2026
nlohmann
left a comment
Owner
There was a problem hiding this comment.
Please amalgamate the source code.
Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com>
Owner
|
Thank you! |
GhostVaibhav
pushed a commit
to GhostVaibhav/json
that referenced
this pull request
May 19, 2026
…nn#5152) * Added front, pop_front, and push_front methods to json_pointers in order to facilitate root-to-leaf traversals of JSON object trees. (nlohmann#4889) Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * undid VS autoformatting in irrelevant code Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * Ran make amalgamate, added navigation to json_pointer's new front methods in mkdocs, and fixed errors in documented complexity for those methods. Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * Fixed GCC 4.8 compile error caused by const iterators Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * Fixed another gcc-4.8 compile error Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * amalgamated Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> --------- Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> Signed-off-by: Vaibhav Sharma <48472541+GhostVaibhav@users.noreply.github.com>
jwnimmer-tri
pushed a commit
to jwnimmer-tri/json
that referenced
this pull request
Sep 21, 2026
…nn#5152) * Added front, pop_front, and push_front methods to json_pointers in order to facilitate root-to-leaf traversals of JSON object trees. (nlohmann#4889) Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * undid VS autoformatting in irrelevant code Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * Ran make amalgamate, added navigation to json_pointer's new front methods in mkdocs, and fixed errors in documented complexity for those methods. Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * Fixed GCC 4.8 compile error caused by const iterators Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * Fixed another gcc-4.8 compile error Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> * amalgamated Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com> --------- Signed-off-by: trdesilva <5818730+trdesilva@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Added front, pop_front, and push_front methods to json_pointers in order to facilitate root-to-leaf traversals of JSON object trees. (#4889) These methods complement back, pop_back, and push_back, allowing json_pointers to be used as deques instead of just stacks. Example use case from the linked issue:
Also made a minor update in unit_json-pointer.cpp to use
CHECK_THROWS_WITH_ASinstead ofCHECK_THROWS_WITHto conform with current Contribution Guidelines. Didn't havemakeavailable in Windows dev environment, so amalgamate was run manually andmake prettywas skipped; hopefully CI can do this?make amalgamate.Read the Contribution Guidelines for detailed information.