1 // Licensed under the Apache License, Version 2.0 2 // <LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0> or the MIT license 3 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your option. 4 // All files in the project carrying such notice may not be copied, modified, or distributed 5 // except according to those terms. 6 //! Type definitions for the basic sized types. 7 use ctypes::{__int64, __uint64, c_int, c_schar, c_short, c_uchar, c_uint, c_ushort}; 8 pub type POINTER_64_INT = usize; 9 pub type INT8 = c_schar; 10 pub type PINT8 = *mut c_schar; 11 pub type INT16 = c_short; 12 pub type PINT16 = *mut c_short; 13 pub type INT32 = c_int; 14 pub type PINT32 = *mut c_int; 15 pub type INT64 = __int64; 16 pub type PINT64 = *mut __int64; 17 pub type UINT8 = c_uchar; 18 pub type PUINT8 = *mut c_uchar; 19 pub type UINT16 = c_ushort; 20 pub type PUINT16 = *mut c_ushort; 21 pub type UINT32 = c_uint; 22 pub type PUINT32 = *mut c_uint; 23 pub type UINT64 = __uint64; 24 pub type PUINT64 = *mut __uint64; 25 pub type LONG32 = c_int; 26 pub type PLONG32 = *mut c_int; 27 pub type ULONG32 = c_uint; 28 pub type PULONG32 = *mut c_uint; 29 pub type DWORD32 = c_uint; 30 pub type PDWORD32 = *mut c_uint; 31 pub type INT_PTR = isize; 32 pub type PINT_PTR = *mut isize; 33 pub type UINT_PTR = usize; 34 pub type PUINT_PTR = *mut usize; 35 pub type LONG_PTR = isize; 36 pub type PLONG_PTR = *mut isize; 37 pub type ULONG_PTR = usize; 38 pub type PULONG_PTR = *mut usize; 39 pub type SHANDLE_PTR = isize; 40 pub type HANDLE_PTR = usize; 41 #[cfg(target_pointer_width = "32")] 42 pub type UHALF_PTR = c_ushort; 43 #[cfg(target_pointer_width = "64")] 44 pub type UHALF_PTR = c_uint; 45 #[cfg(target_pointer_width = "32")] 46 pub type PUHALF_PTR = *mut c_ushort; 47 #[cfg(target_pointer_width = "64")] 48 pub type PUHALF_PTR = *mut c_uint; 49 #[cfg(target_pointer_width = "32")] 50 pub type HALF_PTR = c_short; 51 #[cfg(target_pointer_width = "64")] 52 pub type HALF_PTR = c_int; 53 #[cfg(target_pointer_width = "32")] 54 pub type PHALF_PTR = *mut c_short; 55 #[cfg(target_pointer_width = "64")] 56 pub type PHALF_PTR = *mut c_int; 57 pub type SIZE_T = ULONG_PTR; 58 pub type PSIZE_T = *mut ULONG_PTR; 59 pub type SSIZE_T = LONG_PTR; 60 pub type PSSIZE_T = *mut LONG_PTR; 61 pub type DWORD_PTR = ULONG_PTR; 62 pub type PDWORD_PTR = *mut ULONG_PTR; 63 pub type LONG64 = __int64; 64 pub type PLONG64 = *mut __int64; 65 pub type ULONG64 = __uint64; 66 pub type PULONG64 = *mut __uint64; 67 pub type DWORD64 = __uint64; 68 pub type PDWORD64 = *mut __uint64; 69 pub type KAFFINITY = ULONG_PTR; 70 pub type PKAFFINITY = *mut KAFFINITY; 71