test: migrate 948_idx_compound to @test + runww rejects, retire C twin (fold-3)

#133 indexed-scalar compound-assign. The 21 rows split by observability:
18 value rows -> test/lang/idx_compound_test.ww (one @test fn each,
primitive-only asserts, slot-poison + neighbor-unchanged read-back);
3 reject rows -> test/wcc/data/idx_compound_{float_indexed,str_indexed,
chained_ptr_float}/case.ww as //ww:error, asserting BOTH stages reject on
the shared diagnostic body (cstage's leading prefix excluded). The C twin
is retired; its coverage is a strict superset of the original rows.

First reject-bearing fold-3 migration -- validates the runww dual-stage
home end to end. LANGBYTEID_EXPECTED_MIN 49 -> 50.
This commit is contained in:
2026-06-22 16:02:01 +09:00
parent e57fcf230b
commit af3c49a4c7
6 changed files with 180 additions and 428 deletions

View File

@@ -0,0 +1,12 @@
//ww:error "chained-ptr-field compound on float element not wired (#133/rule-7)"
// Lifted from test/wcc/948_idx_compound_run.c reject row "he_float_chained_ptr"
// (#133-expanded rule-7): a compound assign on a chained-pointer FLOAT field
// (d.i.v += ...) is unwired in both stages and MUST loud-fail. The substring is
// the shared diagnostic body up to "(#133/rule-7)" — cstage appends an extra
// "; field='v'" that wwstage omits, so the cited body is the most specific form
// present on BOTH stages (no file:line / "ww: " prefix, which differ cs vs ww).
package main;
type t = struct { v: f64 };
type w = struct { i: *t };
fn bad(d: *w) void = { d.i.v += 1.5; };
export fn main() i32 = { return 0; };