Skip to content

Conversation

@barcode
Copy link
Contributor

@barcode barcode commented Dec 26, 2022

(Second part of the points listed in #3110 (comment), the rest is done in a different PR to prevent mixing of separate issues / features)

  • Warn users about potential conflicts with newer versions, i.e., base members should avoid generic names to avoid clashes with future member additions to basic_json.
  • (Run reuse.)

Also adds a new method as_base_class to make it easier to access members of a custom base class shadowed by nlohmann::basic_json


Pull request checklist

Read the Contribution Guidelines for detailed information.

  • Changes are described in the pull request, or an existing issue is referenced.
  • The test suite compiles and runs without error.
  • Code coverage is 100%. Test cases can be added by editing the test suite.
  • The source code is amalgamated; that is, after making changes to the sources in the include/nlohmann directory, run make amalgamate to create the single-header files single_include/nlohmann/json.hpp and single_include/nlohmann/json_fwd.hpp. The whole process is described here.

@coveralls
Copy link

coveralls commented Dec 26, 2022

Coverage Status

coverage: 100.0%. remained the same when pulling 0f6d471 on barcode:clean_up_custom_base_class into 5d27543 on nlohmann:develop.

@barcode barcode force-pushed the clean_up_custom_base_class branch from ca8a059 to 93f2c35 Compare January 31, 2023 18:27
@barcode
Copy link
Contributor Author

barcode commented Feb 1, 2023

Work on this PR is done and it only needs a review.

@raphael-grimm raphael-grimm force-pushed the clean_up_custom_base_class branch from 93f2c35 to 0f6d471 Compare August 4, 2023 07:27
@github-actions
Copy link

github-actions bot commented Nov 1, 2025

This pull request has been marked as stale because it has had no activity for 30 days. While we won’t close it automatically, we encourage you to update or comment if it is still relevant. Keeping pull requests active and up-to-date helps us review and merge changes more efficiently. Thank you for your contributions!

@github-actions github-actions bot added the state: stale the issue has not been updated in a while and will be closed automatically soon unless it is updated label Nov 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation L state: stale the issue has not been updated in a while and will be closed automatically soon unless it is updated tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants