// compile-flags: -Ztrait-solver=next
// From #80800
trait SuperTrait {
type A;
type B;
}
trait Trait: SuperTrait::B> {}
fn transmute(x: A) -> B {
foo::>(x)
//~^ ERROR type annotations needed: cannot satisfy `dyn Trait: Trait`
}
fn foo(x: T::A) -> B
where
T: Trait,
{
x
}
static X: u8 = 0;
fn main() {
let x = transmute::<&u8, &[u8; 1_000_000]>(&X);
println!("{:?}", x[100_000]);
}