Commit Graph

608 Commits

Author SHA1 Message Date
e0afe48c21 test: port the xmod typecheck reject observers to ww
test/xmod/typecheck_test.ww replaces 989_callarg_typecheck.c and
989_tagged_subset_reject.c. Preserved: both -T __wwtests reservation
faces (both stages, diagnostic required), the shape-mismatch collision
(both stages), the cstage-only same-shape #37 pin, and both tagged
leaf-bridge xmod rows. Not ported, owned elsewhere per the audit: the
carriers' twelve ordinary call-arg rows (r989_callarg_* fixtures) and
the three w6c-vs-w6c_ww byte-id rows (test-data-byteid over
r989_tagsubset_{flatten_subset,slice_subset,nested_wrap}).
2026-08-08 14:34:53 +09:00
cf74d59e87 test: port the fn/mklabel mangle observers to ww
test/xmod/label_test.ww replaces 706_fnlabel_mangle.c and
750_mklabel_modscoped.c with every assertion preserved (fnlabelmangle
fixture run-112 both stages; three mklabel rows with run exits and
module-qualified label needles). Strengthened: fnlabel adds the
cs==ww sepwork .s byte-id the carrier never asserted.
2026-08-08 14:34:53 +09:00
3f0b7647f6 test: port the M1 mangle/usehint run observers to ww
test/xmod/m1_test.ww replaces 989_m1mangle_run.c and
989_m1usehint_run.c with every assertion preserved (5 tree rows +
2 usehint rows, both stages, plus the leaf_collision byte-id leg;
concat order strengthened from shell glob to byte-sorted listdir).
2026-08-08 14:34:53 +09:00
57675431e2 test: port the xmod collide observers to ww; birth test/xmod
test/xmod/collide_test.ww replaces 989_fnptrcollide_run.c and
989_barefn_collide_run.c with every assertion preserved (build-reject
both stages; run-exit 9 + exactly-one TEXT main.run/aa.run + cs==ww).
Makefile grows the XMOD_WW_TESTS block mirroring SEP_WW_TESTS, wired
into test-compiler.
2026-08-08 14:34:53 +09:00
89a4b82ba3 test: port 944_alias_cgen_b5_run to a compile fixture
944_alias_cgen_b5_run.c -> alias_g73_heapfill (//ww:compile), joining
its migrated alias_* siblings. The carrier's stated fixture blocker
('//ww:compile links') is stale: the COMPILE cell runs the bare
frontend, no link. The live #24 field(SB) deref-read leak enters
DATABYTEID_DIVERGED, upgrading the carrier's silent byte-id waiver
with a graduation tripwire.
2026-08-08 14:33:23 +09:00
5a8b662d6e test: port 839_xmod_nominal_typeeqast to corpus fixtures
839_xmod_nominal_typeeqast.c -> r839_xmod_nominal_match (run-exit 42),
  r839_xmod_a6_concrete (run), r839_xmod_incompat_concrete (error
  'not assignable'), r839_xmod_distinct_alias (error 'ambiguous
  without nominal layout').

r839_xmod_nominal_match enters DATABYTEID_DIVERGED: the carrier waived
byte-id for the pre-existing cross-module tagged-return spill
divergence; the DIVERGED row makes it loud-on-fix instead. The
typeeqast-layer discriminator itself stays with the lib byteid gate
(test/byteid/libbyteid_test.ww), as the carrier documented.
2026-08-08 14:33:23 +09:00
ff7bf08d81 test: port the M3 .wwi-consumer keystone to ww; retire 989_m3sep
m3sep_test.ww drives the raw w6c/w6a/w6l toolchains (+_ww twins) over
hand-composed //ww:module units splicing produced .wwi bytes: the
bodies==.wwi keystone on both stages per package (mid/root/smid) with
determinism, rule-10 and the value-global DATA guard; the end-to-end
i32 chain (exit 59) with final-exe byte-id; and the #49 str-label /
#53 export-leaf link legs (exits 160/140) with their .s needle
proofs. Each @test re-produces its .wwi cold instead of sharing the
carrier's single scratch dir (same claims, sharper isolation).
2026-08-08 14:13:50 +09:00
92d5f1cb56 test: port the ww-test sep observer to ww; retire 989_septest
septest_test.ww keeps all five rows (pass/fail run-exits, the
userman + badsig @test rejects, the collide_run user-fn-run coexist)
plus the full-sepwork .s/.wwi byte-id sweep and the -T synth
TEXT-main / CALL-test.run presence needles, both driver stages. The
pass/fail run-exit rows overlap package_test ownership but stay:
retiring them would drop audit-listed assertions from this gate. The
attest_* data fixtures remain in test/wcc/data (also consumed by the
911_attest_* carriers).
2026-08-08 14:13:50 +09:00
cd408195fa test: port the sep scratch-contract observer to ww; retire 989_sepscratch
sepscratch_test.ww pins the #59 build_one_sep scratch ownership on
both driver stages: build -o keeps <stem>.sepwork, `run` leaves no
/tmp/ww_run_<pid> root, and a foreign pre-existing .sepwork is
refused with exit exactly 1, sentinel intact. The C fork/execl pid
capture becomes `sh -c 'echo $$ ...; exec <drv> run ...'` -- exec
keeps the shell's pid and passes the full driver path as argv[0].
2026-08-08 14:13:50 +09:00
ad189c2ee2 test: port the sep archive/link observers to ww; retire 989_{separchive,sepcycle_dup}
seplink_test.ww carries the .a substrate legs (root-as-.o layout, .a
byte-id + 3x determinism, the #31 masked-dup PASS-3 reject with its
non-vacuity flip), the loud dependency-cycle reject with byte-equal
cs/ww stderr, and the w6l/w6l_ww bare-main duplicate-symbol reject
(achievable substring parity per the filed message divergence).
2026-08-08 14:13:50 +09:00
7c84c52db4 test: port the sep import/namespace observers to ww; retire 989_{coloimport,depmain,declns,slttypepref}
sepimport_test.ww re-hosts the #98 colo srcd-shadow `ww test` gate,
the #99 imported-dep bare-main mangle count, the #23/#30 modfn
coexist byte-id (incl. the cross-layout vbu order pin), and the
#58/#50 scopelookuptype mod-preference rows over the checked-in and
synthesized module trees. slttypepref's ww_ww-absent skip gate is
dropped: the Make target declares both drivers (mangle_test
precedent).
2026-08-08 14:13:50 +09:00
cd49966539 test: port the sep-layout observers to ww; retire 989_{sepbuild,seproot_export,sepstructdef,wwispread}
Birth test/sep/ (single-file ww observers on test/testenv, run by the
new SEP_WW_TARGETS pattern rule under test-compiler) with
sepbuild_test.ww: the build_one_sep real-chain gate incl. the
bodies==.wwi keystone recompile, the #69 root-without--I contract, the
#70 aggregate-def .wwi prototypes, and the #95 spread-marker
round-trip. Every carrier assertion has a successor row; the C
cleanup-accounting ledgers collapse into testenv.clean.
2026-08-08 14:13:50 +09:00
d127c95630 make: restore the dropped ffivariadic callee-archive rule 2026-08-08 14:12:58 +09:00
956246b3f0 test: migrate 700_e2e rows to corpus fixtures; retire the carrier
136 rows migrated, 0 already owned, 3 wwstage-failing rows held out.
2026-08-08 14:10:46 +09:00
3ad10bcef1 test: enroll lib/regex in test-library; retire 989_regex_run 2026-08-08 13:47:55 +09:00
81e7f95548 test: port the asm-pattern observers to ww; byteid carrier partition empty
Four ww tests carry the last eight native byteid carriers' assertions:
asmwindow (753 convwrap beta/main/alpha order + window polarity, 754
slice stride + negative scale scan, 755 amp-dot-idx four rows, 758
first-CALL-line extraction + tab-framed disp literals, direct
w6c/w6c_ww never ww build), freenoop (930 byte-id strengthened to
per-stream compare + negative 'free' grep), structabi (946 param/ret
MOVSD windows with polarity tables and SEND/RECV agreement), mangle
(989_m1mangle needles + concat byte-id, glob order strengthened to
byte-lexicographic). Dead want/stage_mask row fields documented, not
invented into runtime legs; the w6c_ww-absent skip gates drop because
the Make target declares the tools.

BYTEID_WRAPPER_SOURCES, its bins, and test-native-byteid are deleted —
the native byte/artifact partition is EMPTY (11 -> 0 this session);
docs counts move to 123 carriers.
2026-08-08 04:41:42 +09:00
fa4b9a134b lib: migrate every test file to the canonical *_test.ww name
25 renames (git mv, content untouched). _test.ww is what the package
coordinator's test detection and the sep loader's canonical exclusion
key on; the old *test.ww spellings survived only through the
line-leading-@test compatibility scan. Consumers updated in place:
LIBRARY_TESTS, the libbyteid roster, the 901/974/975/976 carriers that
copy or invoke these files, and the check.c/check.ww + path/ftos
comments that cite them. Closes the open-driver-work migration bullet.
2026-08-08 04:29:31 +09:00
634f7a2b3f test: port the .wwi observers to ww; retire 989_m2wwi + 989_wwileaf
test/byteid/wwi_test.ww carries every assertion of both carriers: the
M2 producer gate (ascii/strings/getopt driver-combined positives with
byte-id + wwdump -a re-parse, the synth decl-kind/type-node sweep with
the #47 @symbol round-trip, the #48 types export-def gate, and the
negative private-nominal leak with both-stage identical reject
diagnostics), plus the #11 wwileaf decl-less-leaf rows (package-line
leaf, cross-stage .wwi byte-id, importer resolution + .s byte-id).
Byteid carriers 10 -> 8; docs counts move; the byteid ww target gains
the wwdump prereq its re-parse legs invoke.
2026-08-08 04:25:34 +09:00
cf80c603a8 test: port 989_lib_byteid to ww; birth test/testenv + test/byteid
test/testenv (package testenv) is the shared plumbing for ww-native
test drivers — subprocess launch with captured output, file IO, string
search, byte-sorted directory listing, scratch ownership — lifted from
the proven package_test.ww idiom; a utility, not a framework.

test/byteid/libbyteid_test.ww carries every assertion of the retired C
carrier: the 44-entry roster (fixtures + sentinel-guarded import probes
+ the zero-dep root-only build), both-stage sep builds with the
resolved-unit proof, per-package .s concat compare with the empty-concat
guard, the ID/DIVERGE/WWREJECT pin discipline, and the lib/ corpus
completeness scan (negative-verified against a planted un-enrolled
module). Concat order strengthened from shell-glob to explicit
byte-lexicographic. The roster fills by cursor-driven field writes
because append() rejects struct-call-result sources (#34).

Byteid carriers 11 -> 10; docs counts move; test-byteid runs the ww
test via the wwtest/ pattern with WW_TEST_REPO.
2026-08-08 04:22:04 +09:00
cccdd6e2c8 make: per-file lang/library test targets in -w workdirs
One phony target per test file so -jN parallelizes both suites, each
file building in its own persistent workdir so only changed packages
recompile. Tests always execute — the workdir caches builds, never
results. Lang tests keep their exact historical invocation (no -I);
library tests keep -I lib/ww. Warm -j4: test-library 19.0s -> 1.0s,
test-lang 19.8s -> 2.0s.
2026-08-08 04:10:52 +09:00
6148249927 make: test-incremental gate — -w reuse must equal a clean build
Cold populate, full-skip rerun, surgical staleness (one package's
artifacts deleted), and a 0-byte .o poison drill each build the w6a
graph through a persistent workdir and must be byte-identical to a
classic fresh-scratch build, on both driver stages, plus the
cross-stage clean compare. Wired into test-all; the inner-loop targets
stay untaxed.
2026-08-08 04:09:21 +09:00
9839778f3b make: derive precise tool prerequisites; scope tools to run targets
Per-binary source lists corrected against the real import closures
(strace of each cold sep build): every wwstage tool gains
lib/types/types.ww, wwdump_ww/w6c_ww gain lib/math/{floats,math}.ww and
drop the no-longer-imported lib/fmt/fmt.ww, ww_ww drops
lib/strconv/strconv.ww, and WWTEST_SRC gains the strconv split plus
math. Wrapper test binaries link only libwcc.a — the runtime tools they
exec move to the run targets that launch them, so a .ww edit no longer
relinks 111 carrier binaries. test-compiler-smoke declares the
w6a_ww/w6l_ww/ww_ww fleet its WW cell actually drives (latent
fresh-clone gap); test-package replaces the blanket all with its exact
tool set; test-lang/test-library name the cstage subset they invoke.
2026-08-08 04:08:13 +09:00
7bb31f8cb3 make: build driver-produced binaries in persistent -w workdirs
The five wwstage tools, wwtest, wwfixture, both exec-test binaries, and
the package-test binary move off the per-invocation mktemp workspace to
one persistent ww-build workdir per target under out/wwbuild/, publishing
into out/bin by one atomic mv. Package artifacts now survive across
rebuilds and reuse on exact content identity, so a toolchain-source
touch rebuilds in seconds instead of five from-scratch sep builds; the
per-target split keeps -jN recipe concurrency race-free. Rebuilt
binaries verified byte-identical to the mktemp-path builds for all ten
targets.
2026-08-08 03:54:29 +09:00
e1141330f2 test: retire 13 byteid carriers into the corpus blanket
Ten of the thirteen were already fully twinned — their runtime rows
migrated in earlier waves (r56_def_*, r79_*, r78_*, r926_*,
r989_m1union_*) and the carriers survived only for a cstage-vs-wwstage
byte-compare the blanket test-data-byteid comparator owns once the
source is a corpus fixture. The other three needed their remaining
inline sources added first: r756_* (4, alias-chain unwrap),
r844_bid_src (size(u64) untyped-int compare), r989_structframe_* (3,
struct-local frame layout). Every new fixture was verified both-stage:
compile exit 0 twice, .s byte-identical, runtime exit as pinned.

The five ww_ww-driver-leg carriers among them (785/786/789/790/
m1union) follow the 815/940/951 precedent: content identity owned by
their corpus twins, driver-leg identity owned by 989_lib_byteid's
sweep. Byte/artifact partition 24 -> 11; carriers 147 -> 134; corpus
pin 1495/2990; the stale 915 sweep figure in the docs corrected to
the true 1,157 non-error count.
2026-08-08 02:57:55 +09:00
0b23f9fb31 test: fold driver-parity byteid into 989_lib_byteid, retire 815/940/951
Wwstage-driver-leg byte identity gets one owner. The three carriers'
content identity is already blanket-owned by their r815_/r940_/r951_
corpus twins via test-data-byteid; their only non-redundant assertion
was the ww_ww driver leg, which 989_lib_byteid's 43-unit sweep covers
apart from the zero-dep root-only edge — folded in as a new probe row
(44 units). r940 fixture comments re-cited off the retired carrier.
2026-08-08 00:36:11 +09:00
8a9be47f65 test/wcc/data: pin the drained divergences at runtime
The four graduated pin families byte-compared under test-data-byteid
but their original fixtures masked the miscompiles at runtime (lone
frame slot, dead code path, pointer accident). Add the discriminating
programs as run fixtures: adjacent-element clobber for the 2-byte
deref store, second-variant match dispatch for fn-type dedup, payload
integrity across the tagged widen of a padded struct, and base64
clear() actually zeroing its buffers. Corpus pins move to 1,229
fixtures / 137 run / 766 run-exit / 2,458 cells with the new identity
hash; the data-byteid floor moves to 915.
2026-08-07 23:55:01 +09:00
0b1cc5ef7c check: populate fn-type params in the wwstage tinfo layer
The N_TFN arm stamped only size and return, so every fn tinfo carried
a nil param chain and typeeq judged any two same-return fn types
equal: tagged-union dedup collapsed (*fn(A) T | *fn(B) T) to a bare
8-byte pointer and match read the pointer word as a tag, falling
through every arm for a real second-variant value. Build the tparam
chain like cstage's N_TFN resolve (bare ... sets the FFI variadic
flag; a Hare T... param wraps to []T with a per-param variadic bit
that typeeq now compares, mirroring cstage type_eq). Graduates the
four r76_typeeq_fn pins; the DATABYTEID_DIVERGED ledger is empty.
2026-08-07 23:54:10 +09:00
06c20dbec4 check: stamp a str for-range binding u8 in the wwstage
cstage types the binding ty_u8; the wwstage single-binder arm peeled
the element only for slice/array iterables, so a str scrutinee fell to
the N_FORRANGE fallback decl and exprtype stamped the binding str.
The stamp-keyed call-arg marshal then pushed the 3-word str ABI for a
1-word scalar, and an uncast compare on the binding was falsely
rejected. Route str through the same synthetic-N_LET binder with a u8
element. Graduates r940_str_forrange_arg.
2026-08-07 23:52:08 +09:00
c717facf78 cgen: key the tagged-widen struct copy on natural size, not slot size
cgwidentaggedstorebp's struct-ident arms (local and module-global)
counted copy bytes from structinfo.totsize, the round-8 slot width, so
a struct whose natural size is not a multiple of 8 took the MOVQ word
loop and copied the source slot's dirty pad bytes over the zero-fill
the arm itself just established; the width-true tail emitter beneath
was dead code. cstage keys the same copy on su->size. Route both arms
through copysrcnatsize (the stamped-tinfo natural size, #71).
Graduates r71_tagged_return_scratch_mixed.
2026-08-07 23:51:07 +09:00
4559b52950 cgen: default the hi bound of an N_DOT array-field slice arg
pushargsrev's N_SLICE arm resolved esz and the base address from the
stamped tinfo of an N_DOT [N]T-field base but let the omitted hi bound
fall to $0, so the #258 array-to-slice borrow desugar handed callees a
zero-length slice: base64 clear()'s bytes.zero(e.ibuf) was a runtime
no-op under the wwstage frontend. Take the element count from the
field's array tinfo like the cgslice #252 arm and cstage's bu->alen.
Graduates r989_libprecond_decodedsize_aligned and the 989_lib_byteid
#59.3 base64 pin.
2026-08-07 23:50:02 +09:00
58641e97a5 cgen: narrow 2-byte deref stores in the wwstage assign arm
The plain `*p = v` arm's storeop map handled 1- and 4-byte pointees
but let a 2-byte one fall to MOVQ, an 8-byte over-store that clobbers
six adjacent bytes (masked in the pinned fixture by the lone frame
slot; loud with `&a[0]` of a [4]i16). cstage fldstoreop maps 2 to
MOVW. Graduates r660_i16_out_param_negative.
2026-08-07 23:48:36 +09:00
83c8a4f34f test/wcc: retire 990_selfhost; its live assertions move to their owners
Every probe's assertion is owned by a current gate: the compile and
link probes by make all and the bootstrap fixed point; build/run and
cs/ww byte identity by the fixture corpus, test-data-byteid, and
989_lib_byteid; wwstage driver and toolchain parity by 993/995;
checker-diagnostic parity by the corpus' both-stage //ww:error rows.
The wwdump -t/-a dump-parity probes gated the frontend port's
convergence, which the compiler-output identity gates now own end to
end; carrier ran green at retirement.

What was still uniquely alive migrates: smoke.ww becomes corpus
fixture selfhost_smoke (upgraded from a cstage-only build to both
frontends, byte-identical, exit 42 on both toolchains; corpus pins
move to 1,225/763/2,450 with the new identity hash in the same
commit), and sym_link.ww's scope/sym behavior rows become in-language
lib/ww/syntax/symtest.ww under LIBRARY_TESTS. uses.ww (parser-stub-era
-a fixture) and the already-orphaned tagged_ptr_ret.ww/trypromote.ww
retire with the probe corpus. Bootstrap native gates drop to six;
frontend numeric-sync comments now cite the rule-6 mirror instead of
the retired diff probe.
2026-08-07 23:34:44 +09:00
228a632a2f Makefile: test target graph v2; fold per-snippet byte identity into blanket gates
Presence-is-registration wrapper classification replaces the 296-entry
TESTS list, its per-wrapper rules, the test/run scheduler, the
last-green cache, and auto -j; test is five in-process units plus one
fixture smoke; test-commit composes behavior suites; byte identity,
bootstrap, and platform stay explicit gates. test-data-byteid builds
every non-error corpus fixture twice through the fixed cstage driver
swapping only WW_W6C and byte-compares every per-package .s, with a
910-fixture vacuity floor and the DATABYTEID_DIVERGED loud-pin ledger
(8 real cs/ww divergences: r660, r71, r76_typeeq_fn x4, r940, r989 -
the base64 #59 pin). The 61 carriers whose only assertion that
comparator subsumes retire with it, leaving the 27 survivors that
observe asm patterns, symbols, frames, .wwi round-trips, inline-only
sources, or the wwstage driver leg.

One commit because the wildcard classification sweeps any leftover .c
into test-compiler, where the retired carriers' --sep invocations
cannot run against the current driver; the 61 deletions, the 27-entry
byteid list, and the blanket comparator are a single consistent state.
tools/peellint and tools/sizelint (and the 944 gate wired to them)
retire with the target graph that carried them; rule-13 layout
discipline stays on the authoritative-helper rule.
2026-08-07 23:21:04 +09:00
350bcd8913 ww: own the scratch contract, drop the package cache, add -S
Scratch acquisition is one bare mkdir that refuses a pre-existing
.sepwork; the path reaches cleanup only after acquisition succeeds.
ww build and ww test -o keep the tree for the caller; ww run and
no-output ww test build under an owned /tmp/ww_{run,test}_<pid> dir
and remove it on every result, escalating rc on cleanup failure.
The content-keyed package cache is deleted from both stages; -S stops
after per-package .s emission; --sep is gone and unknown flags are
rejected; directory ww test delegates to the wwtest coordinator; the
wwstage driver routes every subprocess through os.exec.

The wwstage Makefile recipes move off the persistent <tool>_ww.d
build-in-place shape to a per-invocation mktemp workspace: the old
recipes relied on the retired pre-wipe semantics and any rebuild
would trip the new refusal on their leftover main.sepwork.

The three 989_pkgcache_* carriers lose their subject with the cache
and go with it; the rest of the wave's carrier adaptation follows in
its own commits.
2026-08-07 23:20:56 +09:00
0bb1f86c14 test: make T0 harness results complete 2026-08-05 18:19:40 +09:00
eb28dcd5b7 cgen: type-key the struct field-layout receiver arms via stamped tinfo (#31 c1)
wwstage cgen resolved struct field LAYOUT (offset + field type) by bare-leaf
name (structlookupchain / structlookup / letvarstructinfo) at nine field
READ / addr-of / let-copy receiver arms whose base is a *struct pointer, a
value struct, or a module global. Under a cross-module same-leaf collision
(two modules each exporting a `pair`, 16B vs 24B) the bare-leaf lookup
first-matches the wrong-size struct -> the field is read / addressed / copied
at the wrong offset with the wrong width. cstage type-keys off the stamped
node.type_ (type_chase_named(base->type)->fields) and is correct; this aligns
wwstage UP to it (ww-only change).

Route the nine arms off the stamped receiver tinfo: R1/R2 *struct reads via a
new shared choke-point cgptrfieldloadtf (the tinfo twin of cgptrfieldload);
A1/A2/A3 addr-of and W3 scalar global-store via tichase(recv.type_)->fields;
C1/W4a copy/size via structabisizetn(tichase(.type_)). Mirrors #21 (5ae6e34);
the *struct arms peel the pointee with tichase(.type_).sub, the faithful twin
of cstage type_chase_named(bu->sub).

The global value-struct arms (R2/R3/A3/W3/W4a) are converted-for-construction:
a global struct's type is always explicitly qualified, so the bare leaf already
resolved correctly and they cannot be reddened -- byte-id (cs.s==ww.s) is their
net, not a value pin. Labelled so the absent reddening pin is explained, not
silent.

Commit 1 of a 2-commit arc (RULING R2 / Opt-2, .ai/ken-31-spec.md): closes the
field-LAYOUT read/copy/addr surface. Commit 2 converts the W1/W2/W5/W4b store
loops to a tinfo-native fill (cgstructlitfilltn + sretretsizetn) and closes the
in-loop nested sub-arms by construction. Part of the #224 name-keyed-cgen
cluster retirement.

Pin: test/wcc/797 value-asserts R1 ptr-read / C1 let-copy / A1/A2 addr, each
reddening under independent per-arm revert (a ratchet proves nothing for this
silent-capable class).
2026-06-29 14:01:47 +09:00
5ae6e3419e cgen: type-key wwstage struct-layout at 3 sites via stamped tinfo (#21)
wwstage cgen resolved struct LAYOUT by bare-leaf name (structlookup /
structparamsize) at three caller-side sites — the by-value arg push
(cgenutil), the let-receive copy width (cgenstmt), and the field-read
offset (cgenexpr). Under a cross-module same-leaf collision (two modules
each exporting a `pair`, 16B vs 24B) the name lookup first-matches the
WRONG type, so the push dropped the 2nd eightbyte, the receive over-copied,
and the field read the wrong offset. cstage type-keys off the stamped
tinfo and is correct; this aligns wwstage UP to it (ww-only change).

Route all three sites through the stamped node.type_ via a new
structabisizetn(*tinfo) accessor (push + receive) and tichase(type_).fields
(field-read, structlookupchain removed). One commit (rule-11 carve-out):
the collision drives all three at once and no per-site fixture isolates, so
it cannot bisect-split. A scoped slice of the #209/#211 name-keyed-cgen
cluster retirement; the cgdot *struct-ptr/global and let-copy siblings stay
name-keyed and are filed (#31).

New table-driven test 793_xmod_struct_argpush_collide_run (4 scenarios:
push/recv/field over 16B and 12B tails) reddens under a revert of the three
cgen files. Full make test green (336 passed); make sizelint clean.
2026-06-29 11:45:08 +09:00
7b9488706b parse: enforce strict-package — reject package-less files (#24a)
Flip the soft-default to a hard "missing package clause" error symmetrically in
both stages (cmd/wcc/parse.c + lib/ww/syntax/parse.ww): the first real decl of a
primary section with empty pathmod/resetmod and no seen clause is now rejected.
Closes the documented soft-default divergence (the 63-wrapper carve-out).

The gate flip can't be split from the migration it breaks, so this is one atomic
commit: ~80 test/wcc wrappers gain `package main;` via a shared wwtestpkg.h
helper, 6 data fixtures plus 17 asm-grep assertions update for the bare->main.<leaf>
root-helper mangle shift, and rt/ declares `package rt;` with @symbol pinning the
bare rt_ensure/rt_malloc linker names.

Root mangling narrows: the executable entry `main` stays bare (existing
carve-out), but root helper symbols become main.X. The #84 cluster is rewritten
to assert main.run distinct from aa.run/test.run; its cgen fix and bare machinery
are retained — still load-bearing for package-less module-reset deps. New
table-driven test 782_strict_package.c (6 rows, both stages).

Retiring //ww:module-reset is deferred to #24b: it is load-bearing (clears the
.wwi pathmod so the body's package clause asserts), not a vestige; fusing its
removal here would be a silent mismatch.

All byte-id gates green; full make test reports "all 335 tests passed".
2026-06-29 03:55:26 +09:00
d34c90d932 test: ratchet LANGBYTEID floor 152->153 after #14 narrow-tail-widen pins 2026-06-28 15:16:52 +09:00
ac6e86cefe test: ratchet LANGBYTEID floor 151->152 after #9 arr-struct-subtail-frame pin 2026-06-28 12:20:28 +09:00
c6cdd8c2d6 test: ratchet LANGBYTEID floor 150->151 after #17 arrvar-union-slice pin 2026-06-28 10:43:34 +09:00
fa1b6b77d4 test: ratchet LANGBYTEID floor 149->150 after #16 global/chained-unwrap pin 2026-06-28 09:54:59 +09:00
01649598f4 test: ratchet LANGBYTEID floor 148->149 after #15 union-subtail-bp pin 2026-06-28 01:59:46 +09:00
b691a6d8c3 test: ratchet LANGBYTEID floor 147->148 after #12 struct-unwrap pin 2026-06-28 01:10:47 +09:00
3a0389ce60 test: ratchet LANGBYTEID floor 146->147 after #10 aggregate-tail pin 2026-06-27 23:44:58 +09:00
5b33ea3f7d test: ratchet LANGBYTEID floor 144->146 after #6 unwrap-callarg str+slice pins 2026-06-27 21:10:43 +09:00
5071996efe test: ratchet LANGBYTEID floor 143->144 after #11b idx-dot-src pin 2026-06-27 19:40:23 +09:00
737126ed69 test: ratchet LANGBYTEID floor 142->143 after #11 idx-dot-aggret pin 2026-06-27 18:49:24 +09:00
b8d55a729e test: ratchet LANGBYTEID floor 141->142 after #9 deref-callarg pin 2026-06-27 17:20:02 +09:00
597a6ba7ff test: ratchet LANGBYTEID floor 140->141 after C6a fn-ptr-autoderef pin 2026-06-27 14:49:53 +09:00