rust/tests/ui/transmute-equal-assoc-types.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

12 lines
139 B
Rust
Raw Normal View History

// check-pass
trait Foo {
type Bar;
}
unsafe fn noop<F: Foo>(foo: F::Bar) -> F::Bar {
::std::mem::transmute(foo)
}
fn main() {}