// compile-flags: -Znext-solver
// From #80800
trait SuperTrait {
type A;
type B;
}
trait Trait: SuperTrait::B> {}
fn transmute(x: A) -> B {
foo::>(x)
//~^ ERROR the trait bound `dyn Trait: Trait` is not satisfied
}
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]);
}