Add bits/stdc++.h replacement helper and support generator.sh #4
Loading…
Reference in a new issue
No description provided.
Delete branch "haire/fix_check_problems"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
check_problem.shnow acceptsgenerator.sh(nicer than generator, since editors highlight.sh), and thebits/stdc++.hfailure now points at a new helper,scripts/bits-replacer.py, that rewrites the include into the minimal real headers. CI policy is unchanged:bits/stdc++.hstill fails the check.Also fixes the source-file scan to include
.cxx/.c++/.h++, which were silently skipped before.The helper is a manual, opt-in tool, not run at compile time or by CI, vendored from
hairez/bits-replacer.@ -4,3 +4,3 @@output-format = "grouped"target-version = "py310"extend-exclude = ["./testdata_tools/", "problems/*/submissions/*/deepseek_*.py", "problems/*/submissions/*/openai_*.py"]extend-exclude = ["./testdata_tools/", "./scripts/bits-replacer.py", "problems/*/submissions/*/deepseek_*.py", "problems/*/submissions/*/openai_*.py"]Why is the script added as an exception?
@ -0,0 +158,4 @@# A stable, roughly canonical ordering for emitted includes (C then C++ containers# then algorithms then I/O), falling back to alphabetical for anything unlisted.ORDER = [Why not just alphabetical over all?
That is simpler. Committed upstream in
github.com/hairez/bits-replacer@d677428aed@ -32,0 +33,4 @@if [ -x generator.sh ]; thengen=(./generator.sh)elif [ -f generator.sh ]; thengen=(bash generator.sh)Generator should be executable, this should be an error in my opinion
@ -32,0 +35,4 @@elif [ -f generator.sh ]; thengen=(bash generator.sh)elsegen=(./generator)I think it's fair to emit a warning here as having the extension is nicer.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.