summaryrefslogtreecommitdiffstats
path: root/tests/ui/issues/issue-21174.rs
blob: 07827425116af2f42824c2e1753d9e13490f3150 (plain)
1
2
3
4
5
6
7
8
9
10
11
trait Trait<'a> {
    type A;
    type B;
}

fn foo<'a, T: Trait<'a>>(value: T::A) {
    let new: T::B = unsafe { std::mem::transmute(value) };
//~^ ERROR: cannot transmute between types of different sizes, or dependently-sized types
}

fn main() { }