]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-35815.rs
Merge commit '6ed6f1e6a1a8f414ba7e6d9b8222e7e5a1686e42' into clippyup
[rust.git] / src / test / ui / issues / issue-35815.rs
1 // run-pass
2 #![allow(dead_code)]
3 use std::mem;
4
5 struct Foo<T: ?Sized> {
6     a: i64,
7     b: bool,
8     c: T,
9 }
10
11 fn main() {
12     let foo: &Foo<i32> = &Foo { a: 1, b: false, c: 2i32 };
13     let foo_unsized: &Foo<dyn Send> = foo;
14     assert_eq!(mem::size_of_val(foo), mem::size_of_val(foo_unsized));
15 }