]> git.lizzy.rs Git - rust.git/blob - src/test/ui/newtype-temporary.rs
Rollup merge of #87343 - steffahn:fix_unsound_zip_optimization_only_regression_fix...
[rust.git] / src / test / ui / newtype-temporary.rs
1 // run-pass
2
3 #[derive(PartialEq, Debug)]
4 struct Foo(usize);
5
6 fn foo() -> Foo {
7     Foo(42)
8 }
9
10 pub fn main() {
11     assert_eq!(foo(), Foo(42));
12 }