Enum target_lexicon::CDataModel [−][src]
#[non_exhaustive] pub enum CDataModel { LP32, ILP32, LLP64, LP64, ILP64, }
The C data model used on a target.
See also https://en.cppreference.com/w/c/language/arithmetic_types
Variants (Non-exhaustive)
The data model used most commonly on Win16. long
and pointer
are 32 bits.
The data model used most commonly on Win32 and 32-bit Unix systems.
int
, long
, and pointer
are all 32 bits.
The data model used most commonly on Win64
long long
, and pointer
are 64 bits.
The data model used most commonly on 64-bit Unix systems
long
, and pointer
are 64 bits.
A rare data model used on early 64-bit Unix systems
int
, long
, and pointer
are all 64 bits.
Implementations
impl CDataModel
[src]
impl CDataModel
[src]pub fn pointer_width(self) -> Size
[src]
The width of a pointer (in the default address space).
pub fn short_size(self) -> Size
[src]
The size of a C short
. This is required to be at least 16 bits.
pub fn int_size(self) -> Size
[src]
The size of a C int
. This is required to be at least 16 bits.
pub fn long_size(self) -> Size
[src]
The size of a C long
. This is required to be at least 32 bits.
pub fn long_long_size(self) -> Size
[src]
The size of a C long long
. This is required (in C99+) to be at least 64 bits.
pub fn float_size(self) -> Size
[src]
The size of a C float
.
pub fn double_size(self) -> Size
[src]
The size of a C double
.
Trait Implementations
impl Clone for CDataModel
[src]
impl Clone for CDataModel
[src]fn clone(&self) -> CDataModel
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Hash for CDataModel
[src]
impl Hash for CDataModel
[src]impl PartialEq<CDataModel> for CDataModel
[src]
impl PartialEq<CDataModel> for CDataModel
[src]fn eq(&self, other: &CDataModel) -> bool
[src]
#[must_use]pub fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl Copy for CDataModel
[src]
impl Eq for CDataModel
[src]
impl StructuralEq for CDataModel
[src]
impl StructuralPartialEq for CDataModel
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
The resulting type after obtaining ownership.