Files
sx/examples/expected/0044-basic-default-arg-expansion.stdout
agra 297f127821 test(ir): lock call lowering with .ir snapshots + classification tests (A3.2 convergence step 1)
Test-first scaffolding before the CallPlan convergence — no call-code
change. Locks current call behavior so the later lowerCall rewrite is
guarded.

- .ir snapshots for representative call forms: 0031 (direct local-fn +
  dot-shorthand enum ctor), 0032 (UFCS/struct method), 0301 (closure/
  fn-pointer slot), 0400 (protocol dispatch + static-through-impl).
- New focused example 0044-basic-default-arg-expansion + .ir snapshot,
  pinning call-site default expansion (scale(5)->scale(ctx,5,2),
  label(1)->label(ctx,1,"v","!")). Foreign-class instance+static is
  already pinned by the existing FFI .ir set.
- Broaden calls.test.zig (scope-free classification): remaining reflection
  builtins, sqrt->f64, cast->resolved type arg, enum_literal->target_type.

1033 (#caller_location) was rejected as a snapshot: it embeds the absolute
source path as a length-typed string that normalize_ir can't reconcile;
default-arg coverage uses the path-free 0044 instead.

Gate green: zig build, zig build test, tests/run_examples.sh -> 357/0.
2026-06-02 19:20:14 +03:00

6 lines
37 B
Plaintext

default: 10
explicit: 15
v1!
x2!
y3?