Closed lcnr closed 5 months ago
fixing this will probably fix #109
this does not affect a test which uses an impl as indirection, as we prefer param env candidates over impls
trait IntoIterator<'a> {
type IntoIter;
}
trait Iterator<'a> {}
impl<'a, T: Iterator<'a>> IntoIterator<'a> for T {
type IntoIter = T;
}
trait Outer<'a>{}
impl<'a, T: ?Sized> Outer<'a> for T
where
T: IntoIterator<'a>,
T::IntoIter: Iterator<'a>,
{}
checking
T::Assoc: Trait<'a>
, we try to normalize the self typeT: Trait<'a>
either when checking for wf for coinduction(?), or currently indiscard_impls_shadowed_by_env
ParamEnv
candidates,T: Trait<'a>
andT::Assoc: Trait<'a>
T: Trait<'a>
holds, but adds a region constraint due to uniquificationT::Assoc: Trait<'a>
may hold ifT::Assoc
normalizes toT