Repository navigation
[deep-audit A3] Fix four data-facing builtin divergences (UNVERIFIED-BY-CAPTAIN) - #2668
Merged
Merged
Conversation
GNU sources cited (bash 5.3.20, vendored tree): - type slash names: builtins/type.def describe_command disk-file branch prints the command verbatim (findcmd.c absolute_program); the executor type face absolutized slash names via the session cwd. - declare -p sparse order: array.c:948 array_to_assign walks the element list in ascending index order; the storage mirror printed insertion order. Re-render through the sorted map exactly when the verbatim segment order is not ascending (in-order mirrors stay byte-identical). - read IFS backslash: builtins/read.def:823-833 consumes a backslash as an escape introducer before testing the delimiter; the split loop tested IFS membership first, so IFS='\' ended the field. - mapfile callback: builtins/mapfile.def:142-218 re-looks-up the array after run_callback; both drivers kept a local entry map and overwrote callback modifications at the final render. Re-read the live array after each callback. Regression tests (10 tests, all green via scrubbed_cargo): tests/a3_r58b_type_slash_names.rs, tests/a3_f1_sparse_declare_order.rs, tests/a3_f3_read_ifs_backslash.rs, tests/a3_f4_mapfile_callback_modifies.rs. Full probe corpora re-run: no new diffs; remaining diffs are the report-only findings documented in deep-audit/a3/REPORT.md. UNVERIFIED-BY-CAPTAIN.
caomengxuan666
marked this pull request as ready for review
November 3, 2026 17:22
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.
Deep-audit hunt lane A3 (rubash data-facing builtins value semantics), base master 75b2aa5.
Fixes (each twice-reproduced vs GNU bash 5.3.20, regression tests included):
Report-only findings (mechanism/architecture owners, see deep-audit/a3/REPORT.md): R58-A buffered-builtin-output interleaving, declare filtered-listing vs -p divergence for dynamic variables, THIS_SH visibility (needs owner decision), assoc assignment with bracket keys retaining value quotes, printf %()T Olson TZ fallback to UTC, readonly diagnostics bypassing redirections, test -v blind to FUNCNAME/BASH_SOURCE.
Verification: 10 new regression tests green via scrubbed_cargo; 12 adjacent mapfile/read/type/declare targets green; full probe corpora re-run shows no new diffs.
UNVERIFIED-BY-CAPTAIN. Refs-only draft; full findings report at deep-audit/a3/REPORT.md (lane workdir, not in this repo).