fold-2 chunk C5 (drew's Fam8-13 plan), the highest-risk chunk: 21 match/tagged value-row C drivers re-homed. 20 -> test/lang/*_test.ww @test row-tables + 12 runww //ww:error carriers (both stages reject). The global-tag cluster (globtag*/globstructwiden/taggedderefstore/...), which sits on the #15/#17 global-ptr fix, was empirically probed byte-id CLEAN -- the predicted hotspot surfaced ZERO fresh cs!=ww. Carves: variant_chain_b95 #81 -> _runonly (genuinely diverges at HEAD); callret_bound277 #277 -> slim C pin (cs-runs/ww-rejects), mutation-gated. 929_tagged_memarg kept whole (SSE-ABI asm conformance). 19 drivers deleted, 944_variant_chain slimmed to the #277 pin. The match-on-tagged-struct-field divergence (former #26) probed RESOLVED for all its cited shapes (938 voidstr_field/recursion_torture, tagnorm dedup_match all byte-id cs==ww + value-correct) -- closed no-reproducer-at-HEAD, attribution to #15/#17 INFERRED. Those rows migrate as normal byte-id @test and serve as the REGRESSION SENTINEL for the inferred close (a resurgence trips the gate). LANGBYTEID floor 93->113; test count 374->355 (19 deleted; 929 + 944_variant_chain kept). do-not-auto-batch (926_tagscr/940_global_sret/940_str_forrange) untouched.
59 lines
1.5 KiB
Plaintext
59 lines
1.5 KiB
Plaintext
// nested_union_widen_test — widening a nested named error-union (inner = !(i32|bool))
|
|
// into an enclosing (size | inner) union must keep the inner box distinguishable
|
|
// and destructurable across outer-arm select, fn-return, and let-init. Migrated
|
|
// from test/wcc/925_nested_union_widen_run.c (value rows). The same-shape
|
|
// collision row (two distinct names !(i32|bool)) loud-stops both stages and lives
|
|
// at test/wcc/data/nestunion_collision/ as a runww //ww:error carrier.
|
|
|
|
package nested_union_widen_test;
|
|
|
|
type inner = !(i32 | bool);
|
|
|
|
fn g_dr() (size | inner) = {
|
|
let e: inner = (5i32: inner);
|
|
return e;
|
|
};
|
|
|
|
@test fn outer_arm_select() void = {
|
|
let e: inner = (true: inner);
|
|
let r: (size | inner) = e;
|
|
match (r) {
|
|
case let n: size => { assert(false); };
|
|
case let x: inner => { };
|
|
};
|
|
};
|
|
|
|
@test fn destructure_return() void = {
|
|
match (g_dr()) {
|
|
case let s: size => { assert(false); };
|
|
case let x: inner => {
|
|
match (x) {
|
|
case let i: i32 => { assert(i == 5); };
|
|
case let b: bool => { assert(false); };
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
@test fn destructure_let() void = {
|
|
let e: inner = (7i32: inner);
|
|
let r: (size | inner) = e;
|
|
match (r) {
|
|
case let n: size => { assert(false); };
|
|
case let x: inner => {
|
|
match (x) {
|
|
case let i: i32 => { assert(i == 7); };
|
|
case let b: bool => { assert(false); };
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
@test fn single_variant() void = {
|
|
let r: (i32 | bool) = 7i32;
|
|
match (r) {
|
|
case let n: i32 => { assert(n == 7); };
|
|
case let b: bool => { assert(false); };
|
|
};
|
|
};
|