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
pub trait Foo {
type Bar;
}
pub trait Broken {
type Assoc;
fn broken(&self)->Vec<<Self::Assoc as Foo>::Bar> where Self::Assoc: Foo;
}
impl<T> Broken for T {
type Assoc = ();
fn broken(&self)->Vec<<Self::Assoc as Foo>::Bar> where Self::Assoc: Foo {
Vec::new()
}
}
fn main() {
let _m: &Broken<Assoc=()> = &();
}
What's the expected behavior here? A compiler error on trait impl or a compiler error if the fn is called?
The text was updated successfully, but these errors were encountered:
I tried to instantiate the types in #36839 with a
Vec
and received the original ICE.playground
What's the expected behavior here? A compiler error on trait impl or a compiler error if the fn is called?
The text was updated successfully, but these errors were encountered: