#[non_exhaustive]#[repr(u8)]pub enum TypeCode {
Show 26 variants
NumEntry = 1,
Void = 2,
Float = 3,
Double = 4,
Label = 5,
Opaque = 6,
Integer = 7,
Pointer = 8,
FunctionOld = 9,
Half = 10,
Array = 11,
Vector = 12,
X86Fp80 = 13,
Fp128 = 14,
PpcFp128 = 15,
Metadata = 16,
X86Mmx = 17,
StructAnon = 18,
StructName = 19,
StructNamed = 20,
Function = 21,
Token = 22,
BFloat = 23,
X86Amx = 24,
OpaquePointer = 25,
TargetType = 26,
}Expand description
TYPE blocks have codes for each type primitive they use.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NumEntry = 1
NUMENTRY
Allows pre-allocating storage
[numentries]
Void = 2
VOID
Float = 3
FLOAT
Double = 4
DOUBLE
Label = 5
LABEL
Opaque = 6
OPAQUE
Integer = 7
INTEGER
[width]
Pointer = 8
Typed pointers are obsolete.
[pointee type]
FunctionOld = 9
Obsolete
[vararg, attrid, retty, paramty x N]
Half = 10
HALF
Array = 11
ARRAY
[num_elements, elements_type]
Vector = 12
VECTOR
[num_elements, elements_type]
X86Fp80 = 13
X86 LONG DOUBLE
Fp128 = 14
LONG DOUBLE (112 bit mantissa)
PpcFp128 = 15
PPC LONG DOUBLE (2 doubles)
Metadata = 16
METADATA
X86Mmx = 17
Unused
X86 MMX
StructAnon = 18
STRUCT_ANON
[ispacked, elements_type x N]
StructName = 19
STRUCT_NAME
[strchr x N]
StructNamed = 20
STRUCT_NAMED
[ispacked, elements_type x N]
Function = 21
FUNCTION
[vararg, retty, paramty x N]
Token = 22
TOKEN
BFloat = 23
BRAIN FLOATING POINT
X86Amx = 24
X86 AMX
OpaquePointer = 25
OPAQUE_POINTER
[addrspace]
TargetType = 26
TARGET_TYPE
Trait Implementations§
Source§impl TryFromPrimitive for TypeCode
impl TryFromPrimitive for TypeCode
impl Copy for TypeCode
Auto Trait Implementations§
impl Freeze for TypeCode
impl RefUnwindSafe for TypeCode
impl Send for TypeCode
impl Sync for TypeCode
impl Unpin for TypeCode
impl UnwindSafe for TypeCode
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more