Struct gimli::read::Expression
source · [−]pub struct Expression<R: Reader>(pub R);
Expand description
The bytecode for a DWARF expression or location description.
Tuple Fields
0: R
Implementations
sourceimpl<R: Reader> Expression<R>
impl<R: Reader> Expression<R>
sourcepub fn evaluation(self, encoding: Encoding) -> Evaluation<R>
pub fn evaluation(self, encoding: Encoding) -> Evaluation<R>
Create an evaluation for this expression.
The encoding
is determined by the
CompilationUnitHeader
or
TypeUnitHeader
that this expression
relates to.
Examples
use gimli::Expression;
let expression = gimli::Expression(bytecode);
let mut eval = expression.evaluation(unit.encoding());
let mut result = eval.evaluate().unwrap();
sourcepub fn operations(self, encoding: Encoding) -> OperationIter<R>
pub fn operations(self, encoding: Encoding) -> OperationIter<R>
Return an iterator for the operations in the expression.
Trait Implementations
sourceimpl<R: Clone + Reader> Clone for Expression<R>
impl<R: Clone + Reader> Clone for Expression<R>
sourcefn clone(&self) -> Expression<R>
fn clone(&self) -> Expression<R>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<R: Debug + Reader> Debug for Expression<R>
impl<R: Debug + Reader> Debug for Expression<R>
sourceimpl<R: Hash + Reader> Hash for Expression<R>
impl<R: Hash + Reader> Hash for Expression<R>
sourceimpl<R: PartialEq + Reader> PartialEq<Expression<R>> for Expression<R>
impl<R: PartialEq + Reader> PartialEq<Expression<R>> for Expression<R>
sourcefn eq(&self, other: &Expression<R>) -> bool
fn eq(&self, other: &Expression<R>) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &Expression<R>) -> bool
fn ne(&self, other: &Expression<R>) -> bool
This method tests for !=
.
impl<R: Copy + Reader> Copy for Expression<R>
impl<R: Eq + Reader> Eq for Expression<R>
impl<R: Reader> StructuralEq for Expression<R>
impl<R: Reader> StructuralPartialEq for Expression<R>
Auto Trait Implementations
impl<R> RefUnwindSafe for Expression<R> where
R: RefUnwindSafe,
impl<R> Send for Expression<R> where
R: Send,
impl<R> Sync for Expression<R> where
R: Sync,
impl<R> Unpin for Expression<R> where
R: Unpin,
impl<R> UnwindSafe for Expression<R> where
R: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Q where
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to key
and return true
if they are equal.
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more