Closed
Description
I realize this isn't an issue that can be fixed by changing the definition of sys::size_of, however it seems like Rust (like any systems programming language) should have a mechanism for determining the size of a type.
a-la:
pub type MyType = u32;
// Couldn't really be done like this, but you get the idea
pub static MyTypeBits = sys::sizeof::<MyType>() * 8;
Could be implemented with a macro? Something like size_of!(MyType)
.