1 // run-pass 2 size_of_val<T>(_: &T) -> usize3fn size_of_val<T>(_: &T) -> usize { 4 std::mem::size_of::<T>() 5 } 6 7 struct Foo(i64); 8 9 // Test that the (symbol) mangling of `Foo` (the `struct` type) and that of 10 // `typeof Foo` (the function type of the `struct` constructor) don't collide. main()11fn main() { 12 size_of_val(&Foo(0)); 13 size_of_val(&Foo); 14 } 15