You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Generic body uses a field of an unbounded type parameter: fn f[T](x: T) -> i32: x.v passes check and prints 0 #1981
Found by the Sema/MIR wave (wave-sema). fn f[T](x: T) -> i32: x.v called as f(3) passes with check and prints 0. A generic body is checked against its bounds, not its instantiations: T has no bound that provides a field v, so x.v must be a check error at the definition ("type parameter 'T' has no field 'v'; add a bound…"). Today the field access is apparently resolved per instantiation and an i32 has no field, yet a value is produced — a silent fallback. Failing-first: a compile_errors fixture; also confirm a bounded T whose trait provides an accessor still works.
Fixed on main in c884c1c (stack #2001 → #2010, seed-driven battery GREEN on b932ef6, tree identical to main). Fixture coverage is in the stack's commits.
Activity
Sema: a field access on a type with no fields is an error, not an unt…
Sema: one arity check for every call path (#1973); owned ?? / unwrap_…
ehartford commentedon Oct 3, 2026
Fixed on main in c884c1c (stack #2001 → #2010, seed-driven battery GREEN on b932ef6, tree identical to main). Fixture coverage is in the stack's commits.