pub enum ExprKind {
Lit(Lit),
Var(VarRef),
Vaddr(MappingId),
Paddr(MappingId),
Call(Call),
Cast {
expr: Box<Expr>,
ty: Ty,
},
Sizeof {
ty: Ty,
size: u64,
},
Unary {
op: UnaryOp,
operand: Box<Expr>,
},
Binary {
op: BinaryOp,
lhs: Box<Expr>,
rhs: Box<Expr>,
},
Field {
base: Box<Expr>,
field: u32,
offset: u64,
},
}Expand description
The expression forms.
Variants§
Lit(Lit)
A literal, of the node’s type.
Var(VarRef)
A variable or const.
Vaddr(MappingId)
m.vaddr: a mapping’s virtual address, Addr(its region).
Paddr(MappingId)
m.paddr: the physical address of a mapping’s region, Address.
Call(Call)
alias.f(args) with a value: ret is the node’s type.
Cast
expr as T: the value in another integer type, with Rust’s
semantics (widening lossless, narrowing modulo 2ⁿ).
Sizeof
sizeof(T), folded.
Unary
-e, !e, ~e.
Binary
lhs op rhs.
Field
base.f on a struct value.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ExprKind
impl RefUnwindSafe for ExprKind
impl Send for ExprKind
impl Sync for ExprKind
impl Unpin for ExprKind
impl UnsafeUnpin for ExprKind
impl UnwindSafe for ExprKind
Blanket Implementations§
§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Returns the layout of the type.