pub enum Shape {
Base {
name: String,
encoding: Encoding,
size: u64,
},
Pointer {
to: Option<usize>,
size: u64,
},
Array {
of: usize,
count: Option<u64>,
},
Record {
union: bool,
name: Option<String>,
size: Option<u64>,
members: Option<Vec<Member>>,
},
Enumeration {
name: Option<String>,
of: usize,
size: u64,
values: Vec<Constant>,
},
Alias {
name: String,
of: Option<usize>,
},
Qualified {
which: Qualifier,
of: Option<usize>,
},
Subroutine(Sig),
}Expand description
One type, in the terms DWARF describes one.
Variants§
Base
A type whose bytes are read directly, which is every arithmetic type C has.
Fields
Pointer
A pointer, whose target is None for void *.
Fields
Array
An array, whose length is None when it has none a number can say.
That covers three C spellings at once: the flexible array member, the array of unknown length, and the array whose length is an expression. DWARF can describe the last of those with an expression of its own, which is worth doing and is not done here, and leaving the bound out is the answer a debugger already has to handle for the other two.
Fields
Record
A struct or a union, whose members are None when it is incomplete.
Fields
Enumeration
An enum.
Fields
Alias
A typedef name for another type.
Fields
Qualified
A qualified version of another type.
Fields
Subroutine(Sig)
A function type, which is what a pointer to a function points at.
Trait Implementations§
impl Eq for Shape
impl StructuralPartialEq for Shape
Auto Trait Implementations§
impl Freeze for Shape
impl RefUnwindSafe for Shape
impl Send for Shape
impl Sync for Shape
impl Unpin for Shape
impl UnsafeUnpin for Shape
impl UnwindSafe for Shape
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.