Add an option for converting usize/isize into size_t/ptrdiff_t
This commit is contained in:
committed by
Emilio Cobos Álvarez
parent
050863a249
commit
398b28ca30
@@ -0,0 +1,15 @@
|
||||
type Usize = usize;
|
||||
type Isize = isize;
|
||||
|
||||
#[repr(usize)]
|
||||
enum UE {
|
||||
UV,
|
||||
}
|
||||
|
||||
#[repr(isize)]
|
||||
enum IE {
|
||||
IV,
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn root(_: Usize, _: Isize, _: UE, _: IE) {}
|
||||
@@ -0,0 +1 @@
|
||||
usize_is_size_t = true
|
||||
Reference in New Issue
Block a user