mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 23:04:33 +00:00
9d79cd5f79
Implement T-types suggested logic for perfect non-local impl detection This implement [T-types suggested logic](https://github.com/rust-lang/rust/issues/121621#issuecomment-1976826895) for perfect non-local impl detection: > for each impl, instantiate all local types with inference vars and then assemble candidates for that goal, if there are more than 1 (non-private impls), it does not leak This extension to the current logic is meant to address issues reported in https://github.com/rust-lang/rust/issues/121621. This PR also re-enables the lint `non_local_definitions` to warn-by-default. Implementation was discussed in this [zulip thread](https://rust-lang.zulipchat.com/#narrow/stream/144729-t-types/topic/Implementing.20new.20non-local.20impl.20defs.20logic). Fixes https://github.com/rust-lang/rust/issues/121621 Fixes https://github.com/rust-lang/rust/issues/121746 r? `@lcnr` *(feel free to re-roll)* |
||
---|---|---|
.. | ||
src | ||
Cargo.toml | ||
messages.ftl |