Use assertion-like static assertions
This commit is contained in:
parent
8053f6319a
commit
68298a5087
3 changed files with 4 additions and 4 deletions
|
|
@ -1,5 +1,5 @@
|
|||
// compile-pass
|
||||
|
||||
static ASSERT: () = [()][(std::mem::size_of::<u32>() != 4) as usize];
|
||||
static ASSERT: () = [()][!(std::mem::size_of::<u32>() == 4) as usize];
|
||||
|
||||
fn main() {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue