pub enum TypeData<'t> {
Primitive {
primitive_type: PrimitiveType,
indirection: Indirection,
},
Class {
kind: ClassKind,
count: u16,
properties: TypeProperties,
fields: Option<TypeIndex>,
derived_from: Option<TypeIndex>,
vtable_shape: Option<TypeIndex>,
data_length: u16,
name: RawString<'t>,
},
Member {
attributes: FieldAttributes,
field_type: TypeIndex,
offset: u16,
name: RawString<'t>,
},
MemberFunction {
return_type: TypeIndex,
class_type: TypeIndex,
this_pointer_type: TypeIndex,
attributes: FunctionAttributes,
parameter_count: u16,
argument_list: TypeIndex,
this_adjustment: u32,
},
OverloadedMethod {
count: u16,
method_list: TypeIndex,
name: RawString<'t>,
},
Method {
attributes: FieldAttributes,
method_type: TypeIndex,
vtable_offset: Option<u32>,
name: RawString<'t>,
},
StaticMember {
attributes: FieldAttributes,
field_type: TypeIndex,
name: RawString<'t>,
},
NestedType {
attributes: FieldAttributes,
nested_type: TypeIndex,
name: RawString<'t>,
},
BaseClass {
kind: ClassKind,
attributes: FieldAttributes,
base_class: TypeIndex,
offset: u32,
},
VirtualBaseClass {
direct: bool,
attributes: FieldAttributes,
base_class: TypeIndex,
base_pointer: TypeIndex,
base_pointer_offset: u32,
virtual_base_offset: u32,
},
VirtualFunctionTable {
table: TypeIndex,
},
Procedure {
return_type: TypeIndex,
attributes: FunctionAttributes,
parameter_count: u16,
argument_list: TypeIndex,
},
Pointer {
underlying_type: TypeIndex,
attributes: PointerAttributes,
},
Modifier {
underlying_type: TypeIndex,
constant: bool,
volatile: bool,
unaligned: bool,
},
Enumeration {
count: u16,
properties: TypeProperties,
underlying_type: TypeIndex,
fields: TypeIndex,
name: RawString<'t>,
},
Enumerate {
attributes: FieldAttributes,
value: EnumValue,
name: RawString<'t>,
},
Array {
element_type: TypeIndex,
indexing_type: TypeIndex,
stride: Option<u32>,
dimensions: Vec<u32>,
},
Union {
count: u16,
properties: TypeProperties,
fields: TypeIndex,
size: u32,
name: RawString<'t>,
},
Bitfield {
underlying_type: TypeIndex,
length: u8,
position: u8,
},
FieldList {
fields: Vec<TypeData<'t>>,
continuation: Option<TypeIndex>,
},
ArgumentList {
arguments: Vec<TypeIndex>,
},
MethodList {
method_list: Vec<MethodListEntry>,
},
}
Encapsulates parsed data about a Type
.
Variants
Primitive
Represents a primitive type like void
or char *
.
Fields of Primitive
primitive_type: PrimitiveType | The primitive type described by this TypeIndex
|
indirection: Indirection | What kind of indirection was applied to the underlying type
|
Class
Class
represents a class
, struct,
or interface
.
Fields of Class
kind: ClassKind | |
count: u16 | Count of number of elements in this class
|
properties: TypeProperties | |
fields: Option<TypeIndex> | Type index which describes the fields of this class
|
derived_from: Option<TypeIndex> | Type index which describes the class from which this class is derived, if any
|
vtable_shape: Option<TypeIndex> | Type index which describes the shape of the vtable for this class, if any
|
data_length: u16 | |
name: RawString<'t> | |
Member
Fields of Member
MemberFunction
Fields of MemberFunction
OverloadedMethod
Fields of OverloadedMethod
Method
Fields of Method
StaticMember
Fields of StaticMember
NestedType
Fields of NestedType
BaseClass
Fields of BaseClass
kind: ClassKind | |
attributes: FieldAttributes | |
base_class: TypeIndex | |
offset: u32 | Describes the offset of the base class within the class
|
VirtualBaseClass
Fields of VirtualBaseClass
VirtualFunctionTable
Fields of VirtualFunctionTable
Procedure
Fields of Procedure
Pointer
Fields of Pointer
underlying_type: TypeIndex | |
attributes: PointerAttributes | |
Modifier
Fields of Modifier
Enumeration
Fields of Enumeration
Enumerate
Fields of Enumerate
attributes: FieldAttributes | |
value: EnumValue | |
name: RawString<'t> | |
Array
Fields of Array
Union
Fields of Union
Bitfield
Fields of Bitfield
FieldList
Fields of FieldList
fields: Vec<TypeData<'t>> | |
continuation: Option<TypeIndex> | Sometimes fields can't all fit in a single FieldList, in which case the FieldList
refers to another FieldList in a chain.
|
ArgumentList
Fields of ArgumentList
MethodList
Fields of MethodList
method_list: Vec<MethodListEntry> | |
Methods
Return the name of this TypeData, if any
Trait Implementations
Formats the value using the given formatter.
fn eq(&self, __arg_0: &TypeData<'t>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &TypeData<'t>) -> bool
This method tests for !=
.