Enum gimli::read::UnitType

source ·
pub enum UnitType<Offset>
where Offset: ReaderOffset,
{ Compilation, Type { type_signature: DebugTypeSignature, type_offset: UnitOffset<Offset>, }, Partial, Skeleton(DwoId), SplitCompilation(DwoId), SplitType { type_signature: DebugTypeSignature, type_offset: UnitOffset<Offset>, }, }
Expand description

This enum specifies the type of the unit and any type specific data carried in the header (e.g. the type signature/type offset of a type unit).

Variants§

§

Compilation

In DWARF5, a unit with type DW_UT_compile. In previous DWARF versions, any unit appearing in the .debug_info section.

§

Type

In DWARF5, a unit with type DW_UT_type. In DWARF4, any unit appearing in the .debug_types section.

Fields

§type_signature: DebugTypeSignature

The unique type signature for this type unit.

§type_offset: UnitOffset<Offset>

The offset within this type unit where the type is defined.

§

Partial

A unit with type DW_UT_partial. The root DIE of this unit should be a DW_TAG_partial_unit.

§

Skeleton(DwoId)

A unit with type DW_UT_skeleton. The enclosed dwo_id can be used to link this with the corresponding SplitCompilation unit in a dwo file. NB: The non-standard GNU split DWARF extension to DWARF 4 will instead be a Compilation unit with the dwo_id present as an attribute on the root DIE.

§

SplitCompilation(DwoId)

A unit with type DW_UT_split_compile. The enclosed dwo_id can be used to link this with the corresponding Skeleton unit in the original binary. NB: The non-standard GNU split DWARF extension to DWARF 4 will instead be a Compilation unit with the dwo_id present as an attribute on the root DIE.

§

SplitType

A unit with type DW_UT_split_type. A split type unit is identical to a conventional type unit except for the section in which it appears.

Fields

§type_signature: DebugTypeSignature

The unique type signature for this type unit.

§type_offset: UnitOffset<Offset>

The offset within this type unit where the type is defined.

Trait Implementations§

source§

impl<Offset> Clone for UnitType<Offset>
where Offset: ReaderOffset + Clone,

source§

fn clone(&self) -> UnitType<Offset>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<Offset> Debug for UnitType<Offset>
where Offset: ReaderOffset + Debug,

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<Offset> PartialEq for UnitType<Offset>
where Offset: ReaderOffset + PartialEq,

source§

fn eq(&self, other: &UnitType<Offset>) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<Offset> Copy for UnitType<Offset>
where Offset: ReaderOffset + Copy,

source§

impl<Offset> Eq for UnitType<Offset>
where Offset: ReaderOffset + Eq,

source§

impl<Offset> StructuralPartialEq for UnitType<Offset>
where Offset: ReaderOffset,

Auto Trait Implementations§

§

impl<Offset> Freeze for UnitType<Offset>
where Offset: Freeze,

§

impl<Offset> RefUnwindSafe for UnitType<Offset>
where Offset: RefUnwindSafe,

§

impl<Offset> Send for UnitType<Offset>
where Offset: Send,

§

impl<Offset> Sync for UnitType<Offset>
where Offset: Sync,

§

impl<Offset> Unpin for UnitType<Offset>
where Offset: Unpin,

§

impl<Offset> UnwindSafe for UnitType<Offset>
where Offset: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where T: Copy,

source§

unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

default unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.