Struct haybale::Location[][src]

pub struct Location<'p> {
    pub module: &'p Module,
    pub func: &'p Function,
    pub bb: &'p BasicBlock,
    pub instr: BBInstrIndex,
    pub source_loc: Option<&'p DebugLoc>,
}

Fully describes a code location within the LLVM IR.

Fields

module: &'p Modulefunc: &'p Functionbb: &'p BasicBlockinstr: BBInstrIndexsource_loc: Option<&'p DebugLoc>

Source location which this IR location corresponds to, if available.

Implementations

impl<'p> Location<'p>[src]

pub fn to_string_with_module(&self) -> String[src]

Format this Location as a string, including the full module name

pub fn to_string_no_module(&self) -> String[src]

Format this Location as a string, omitting the module name

pub fn to_string_short_module(&self) -> String[src]

Format this Location as a string, including the short module name. The short module name is the part of the module name after the last /, if any; or the full module name, if the module name does not contain a /.

Trait Implementations

impl<'p> Clone for Location<'p>[src]

impl<'p> Debug for Location<'p>[src]

impl<'p> Eq for Location<'p>[src]

Our implementation of PartialEq satisfies the requirements of Eq

impl<'p> From<Location<'p>> for LocationDescription<'p>[src]

impl<'p> Hash for Location<'p>[src]

impl<'p> PartialEq<Location<'p>> for Location<'p>[src]

Implementation of PartialEq assumes that module names are unique; that function names are unique within a module; and that bb names are unique within a function

Auto Trait Implementations

impl<'p> RefUnwindSafe for Location<'p>[src]

impl<'p> Send for Location<'p>[src]

impl<'p> Sync for Location<'p>[src]

impl<'p> Unpin for Location<'p>[src]

impl<'p> UnwindSafe for Location<'p>[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.