Repository navigation
Re-amalgamate single_include - #5745
Merged
Merged
Conversation
#5737 changed 13 headers under include/ but merged without the matching single_include/nlohmann/json.hpp update, so the amalgamated header still had, among others, the GCC C++20 -Wignored-attributes pragma block and the clang -Wdocumentation push/pop that #5737 removed, the forwarding from_json tuple/array helpers it replaced with const references, and lacked the output_adapter char_traits changes it added. Regenerated with `make amalgamate` (astyle 3.4.13). The diff is exactly `git diff b54ed18 e5a89d6 -- include/` (164+/95-); json_fwd.hpp and json_literals.hpp were already up to date. Signed-off-by: Niels Lohmann <mail@nlohmann.me>
#5737 was merged 39 seconds after its last push, while its own check_amalgamation run was still queued (earlier runs had been cancelled by the concurrency group), so the stale single_include reached develop without any failing check. Also run the check on pushes to develop, without cancelling in-progress develop runs. The "save" job (PR number/author for the comment workflow) only runs for pull requests, the checkout falls back to github.sha, and comment_check_amalgamation.yml only comments for PR-triggered runs, since push runs have no PR and no "pr" artifact. Signed-off-by: Niels Lohmann <mail@nlohmann.me>
This was referenced Oct 1, 2026
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.
single_include/nlohmann/json.hppon develop is stale: forcingmake amalgamateon e5a89d6 changes 259 lines. All of it comes from #5737, which changed 13 headers underinclude/and merged without the matching amalgamation. The regenerated diff equalsgit diff b54ed188e e5a89d671 -- include/(+164/−95), and every spot-checked hunk traces back to #5737 withgit log -S. The PRs merged just before it (#5548, #5729, #5731, #5732) updated single_include correctly.json_fwd.hppandjson_literals.hppwere already up to date.What single_include was missing from #5737:
-Wignored-attributespragma block from Fix GCC C++20 modules compilation #5103 #5164. This was intentional (Lint and static-analysis config: clang-tidy checks disabled "to get the CI going", no-op scan-build job, stale NOLINTs, library-wide warning suppressions in tests, stale GCC flags and frozen clang-tidy image #5725 item 9): the pragma could not suppress the hard errors in Build issue when compiling with gcc (any modules-capable version) in a C++ modules project #5103. It was removed outright, not moved. The note insrc/modules/json.cppmpredates it (Fix GCC C++20 modules compilation #5103 #5164).-Wdocumentationpush/pop, and the doc-comment fixes it made possible (\\uescapes,@complexity→Complexity:,@liveexample,@tparamin@return,unescape's@param[in,out])from_jsontuple/pair/array helpers now takeconst BasicJsonType&instead of forwarding. The forwards were no-ops becauseat()always returns an lvalue.output_adapterno longer namesstd::basic_string/std::basic_ostreamfor non-characterCharType(Lint and static-analysis config: clang-tidy checks disabled "to get the CI going", no-op scan-build job, stale NOLINTs, library-wide warning suppressions in tests, stale GCC flags and frozen clang-tidy image #5725 item 2), plus the-Wdocumentation-deprecated-syncsuppression around the deprecatedsax_parseoverloadbugprone-std-namespace-modification,misc-anonymous-namespace-in-header,portability-template-virtual-member-function, the double forward incontainer_input_adapter_factory), and droppingLCOV_EXCL_LINEfrom thejson_pointerout_of_range.410 throwWhy this went unnoticed, and the second commit
#5737 merged 39 seconds after its last push. Its
check_amalgamationrun was still queued, and earlier runs had been cancelled by the concurrency group, so no failing check was ever reported.check_amalgamation.ymlonly runs onpull_request, so nothing on develop caught it afterwards either.The second commit adds
push: branches: [develop]tocheck_amalgamation.yml:savejob (PR number/author) only runs for pull requestsgithub.event.pull_request.head.sha || github.shacomment_check_amalgamation.ymlonly comments for PR-triggered runs, because push runs have no PR and noprartifactA failure on develop then shows up as a red check on the merge commit, with the ready-to-apply
amalgamation-patchartifact. This doesn't stop the merge itself; only making the check a required status check would do that. If you'd rather keep the workflow PR-only, drop the second commit.Public API
No breaking changes. single_include now matches include/.
This PR was written by Claude Code.
🤖 Generated with Claude Code