test: banner purge + WHY-only comment sweep (rule 8)

Every section banner dies (103 -> 0) across test/lang, the observer
suites, the C carriers, and the five comment-heavy corpus fixtures;
banner provenance (#N cites, carrier numbers, repair-cluster labels)
folded into headers or adjacent WHY comments. Narration deleted; row
provenance, ref cites, divergence pins, and layout contracts kept
(fwd-ref decl-order guards and bootstrap-gate corpus rationale
restored where the sweep over-cut). Comment-only proven: all 3742
wwbuild workdir .s byte-identical before/after; test-commit and
test-byteid (161 lang + 1399 data, 0 pinned-divergent) green.
This commit is contained in:
2026-08-08 21:40:23 +09:00
parent aadc6618f0
commit 83f5956df2
120 changed files with 184 additions and 530 deletions

View File

@@ -164,8 +164,6 @@ fn cxrootsrc() str = {
"fn main() i32 = { return (cea.val(): i32) + (ceb.val(): i32); };\n");
};
// produce a package's .wwi (w6c -I, .s discarded); the production
// itself must succeed.
fn produce(td: str, name: str, unit: str, wwi: str) void = {
let av: []str = [testenv.driver("w6c"), "-I", wwi, "-o", "/dev/null",
unit];
@@ -222,7 +220,6 @@ fn keystone(td: str, label: str, bodies: str, sepu: str) void = {
};
};
// compile (-c) + assemble one package unit through one toolchain.
fn buildpkg(td: str, name: str, comp: str, asmtool: str, unit: str,
sf: str, of: str) void = {
let cav: []str = [testenv.driver(comp), "-c", "-o", sf, unit];
@@ -235,7 +232,6 @@ fn buildpkg(td: str, name: str, comp: str, asmtool: str, unit: str,
};
};
// materialize leaf.ww + leaf.wwi + mid.prod.ww + mid.wwi under td.
fn producecore(td: str) void = {
let leafww: str = strings.concat(td, "/leaf.ww");
testenv.writefile(leafww, leafsrc());
@@ -248,7 +244,6 @@ fn producecore(td: str) void = {
produce(td, "mid", prod, strings.concat(td, "/mid.wwi"));
};
// materialize sleaf.ww + sleaf.wwi (+ optionally smid.wwi) under td.
fn producestr(td: str, withsmid: bool) void = {
let sleafww: str = strings.concat(td, "/sleaf.ww");
testenv.writefile(sleafww, sleafsrc());

View File

@@ -69,8 +69,6 @@ fn samefile(label: str, what: str, a: str, b: str) void = {
};
};
// ---- sepbuild (#46): real chain root->os->{rt,time} --------------------
// A package directory's *.ww bodies (less *test.ww), byte-sorted, each
// newline-terminated — mirrors the driver's body enumeration so the
// substituted bodies-unit matches the sep-unit structurally.
@@ -241,8 +239,6 @@ fn composebodies(unit: str, libdir: str) str = {
testenv.clean(td);
};
// ---- seproot (#69 BUG-1): export-over-unexported-type root -------------
@test fn seproot() void = {
let td: str = testenv.fresh();
assert(os.mkdir(strings.concat(td, "/lib"), 493) == 0);
@@ -340,8 +336,6 @@ fn composebodies(unit: str, libdir: str) str = {
testenv.clean(td);
};
// ---- sepstructdef (#70 BUG-2): aggregate-init def prototypes -----------
@test fn sepstructdef() void = {
let td: str = testenv.fresh();
assert(os.mkdir(strings.concat(td, "/lib"), 493) == 0);
@@ -420,8 +414,6 @@ fn composebodies(unit: str, libdir: str) str = {
testenv.clean(td);
};
// ---- wwispread (#95): `...` spread marker round-trip -------------------
fn spreadshape(name: str, entry: str, wwi: str, marker: str) void = {
let td: str = testenv.fresh();
let src: str = strings.concat(testenv.repo(), "/", entry);

View File

@@ -84,8 +84,6 @@ fn cmpsepwork(label: str, csdir: str, wwdir: str) void = {
if (seen == 0) { fail(label, "no .s/.wwi in cs sepwork"); };
};
// ---- coloimport (#98) --------------------------------------------------
@test fn coloimport() void = {
let td: str = testenv.fresh();
let inc: str = strings.concat(testenv.repo(), "/test/wcc/data/colo98");
@@ -116,8 +114,6 @@ fn cmpsepwork(label: str, csdir: str, wwdir: str) void = {
testenv.clean(td);
};
// ---- depmain (#99) -----------------------------------------------------
// column-0 anchored `TEXT main,` labels across every .s under `dir`;
// the leading '\n' prepend also counts a file-leading label.
fn countbaremain(dir: str) i32 = {
@@ -183,8 +179,6 @@ fn depmainrow(label: str, entry: str, want: i32, deps: str,
"cc.s", "TEXT cc.main,");
};
// ---- declns modfn coexist (#23/#30) ------------------------------------
@test fn declns() void = {
let td: str = testenv.fresh();
let lays: []str = ["modfn_coexist", "modfn_coexist_vbu"];
@@ -278,8 +272,6 @@ fn depmainrow(label: str, entry: str, want: i32, deps: str,
testenv.clean(td);
};
// ---- slttypepref (#58/#50 c1) ------------------------------------------
// fresh two-directory tree per (row,driver); relative build with the
// tree as cwd (canonical dir-package build, binary lands in cwd).
fn sltbuild(drv: str, param: str) i32 = {

View File

@@ -19,7 +19,7 @@ package seplink_test;
// exit non-zero, name "duplicate symbol", and leave no partial
// binary. Non-vacuity flip: a distinct symbol builds + runs (exit 3).
//
// cycle (#46 commit-4) — a 3-package import cycle
// cycle (#46 commit-4 A) — a 3-package import cycle
// root->pkga->pkgb->pkgc->pkga is LOUD-rejected: non-zero exit, the
// `dependency cycle: pkga -> pkgb -> pkgc -> pkga` chain named, no
// partial binary, and cs stderr == ww stderr BYTE-IDENTICAL (the
@@ -65,8 +65,6 @@ fn runcode(dir: str, name: str, argv: []str) i32 = {
return co.code;
};
// ---- archive (#46 commit-5a) -------------------------------------------
@test fn archive() void = {
let td: str = testenv.fresh();
assert(os.mkdir(strings.concat(td, "/helper"), 493) == 0);
@@ -140,8 +138,6 @@ fn runcode(dir: str, name: str, argv: []str) i32 = {
testenv.clean(td);
};
// ---- archivedup (#31 through .a, PASS 3) -------------------------------
@test fn archivedup() void = {
let td: str = testenv.fresh();
assert(os.mkdir(strings.concat(td, "/pkga"), 493) == 0);
@@ -208,8 +204,6 @@ fn runcode(dir: str, name: str, argv: []str) i32 = {
testenv.clean(td);
};
// ---- cycle (#46 commit-4 A) --------------------------------------------
@test fn cycle() void = {
let td: str = testenv.fresh();
assert(os.mkdir(strings.concat(td, "/pkga"), 493) == 0);
@@ -289,8 +283,6 @@ fn runcode(dir: str, name: str, argv: []str) i32 = {
testenv.clean(td);
};
// ---- linkdup (#31 at the linker) ---------------------------------------
@test fn linkdup() void = {
let td: str = testenv.fresh();
let u1: str = strings.concat(td, "/u1.ww");