rust/src/test/run-pass/issue-2895.rs

17 lines
209 B
Rust
Raw Normal View History

2012-10-15 19:09:05 -05:00
use sys::size_of;
extern mod std;
struct Cat {
x: int
}
struct Kitty {
x: int,
drop {}
}
fn main() {
assert (size_of::<Cat>() == 8 as uint);
assert (size_of::<Kitty>() == 16 as uint);
}