Open lcnr opened 10 months ago
would this be fixed if we auto-elaborated item bounds, i.e. elaborate U: Copy
from T: WithAliasBound<Assoc = U>
?
yes it would, had the same convo with @BoxyUwU rn 😆 doing so is non-trivial however.
Instead of T: WithAliasBound<Assoc = U>
you can have T: WithIntoIteratorAliasBound<Assoc = Vec<U>>
. So if you now add Vec<u32>: IntoIterator
into the environment it probably shadows the actual impl, preventing you from normalizing <Vec<u32> as IntoIterator>::Item
. We probably want param env Trait
-candidates to prevent normalizing via impls due to #76/https://github.com/rust-lang/trait-system-refactor-initiative/issues/12
our current plan to soundly support coinductive traits is to require proving the item bounds of a trait when using an implementation. Afaict this should break the following example:
related issues