[−][src]Struct cranelift_codegen::ir::SourceLoc
A source location.
This is an opaque 32-bit number attached to each Cranelift IR instruction. Cranelift does not interpret source locations in any way, they are simply preserved from the input to the output.
The default source location uses the all-ones bit pattern !0
. It is used for instructions
that can't be given a real source location.
Methods
impl SourceLoc
[src]
pub fn new(bits: u32) -> Self
[src]
Create a new source location with the given bits.
pub fn is_default(self) -> bool
[src]
Is this the default source location?
pub fn bits(self) -> u32
[src]
Read the bits of this source location.
Trait Implementations
impl Copy for SourceLoc
[src]
impl Display for SourceLoc
[src]
impl Debug for SourceLoc
[src]
impl PartialEq<SourceLoc> for SourceLoc
[src]
impl Eq for SourceLoc
[src]
impl Clone for SourceLoc
[src]
fn clone(&self) -> SourceLoc
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Default for SourceLoc
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,