Each argument bound to a `..xs: P` pack must conform to P — previously the constraint was decorative (any type was accepted). `lowerPackFnCall` now captures the pack param's constraint protocol and checks each pack arg via a new `packArgConformsTo`, which accepts: a plain-protocol impl (`protocol_thunk_map`), any parameterised impl `P(<args>) for T` (scan of `param_impl_map` for a `P\x00…\x00mangle(T)` key — the per-element type-args are inferred from the impl, not written out), or an arg already erased to P's own protocol struct. Non-conformers get a per-position error pointing at the argument. Only enforced for a known protocol constraint. Regression: examples/192-pack-non-conform.sx (a struct lacking `impl Show` in a `..xs: Show` pack → diagnostic, exit 1).
2 lines
2 B
Plaintext
2 lines
2 B
Plaintext
1
|