constant: Support suffixes for integers that otherwise would be narrowed.

This commit is contained in:
Emilio Cobos Álvarez
2022-06-07 16:03:55 +02:00
parent a79a10d9a6
commit 597b033ccf
14 changed files with 129 additions and 21 deletions
+10 -1
View File
@@ -29,5 +29,14 @@ bitflags! {
}
}
bitflags! {
#[repr(C)]
pub struct LargeFlags: u64 {
/// Flag with a very large shift that usually would be narrowed.
const LARGE_SHIFT = 1u64 << 44;
}
}
#[no_mangle]
pub extern "C" fn root(flags: AlignFlags, bigger_flags: DebugFlags) {}
pub extern "C" fn root(flags: AlignFlags, bigger_flags: DebugFlags, largest_flags: LargeFlags) {}