pub struct BinaryExpr {
pub op: BinaryOperation,
pub op_source: Fragment,
pub lhs: Box<Expr>,
pub rhs: Box<Expr>,
}Available on crate feature
ast-models only.Expand description
A binary operation, such as a + b.
Fields§
§op: BinaryOperationThe operation being applied.
op_source: FragmentThe source of the operator token.
lhs: Box<Expr>The left hand side.
rhs: Box<Expr>The right hand side.
Trait Implementations§
Source§impl Clone for BinaryExpr
impl Clone for BinaryExpr
Source§impl Debug for BinaryExpr
impl Debug for BinaryExpr
Source§impl PartialEq for BinaryExpr
impl PartialEq for BinaryExpr
impl StructuralPartialEq for BinaryExpr
Auto Trait Implementations§
impl Forget for BinaryExpr
impl Freeze for BinaryExpr
impl RefUnwindSafe for BinaryExpr
impl Send for BinaryExpr
impl Sync for BinaryExpr
impl Unpin for BinaryExpr
impl UnsafeUnpin for BinaryExpr
impl UnwindSafe for BinaryExpr
Blanket Implementations§
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,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more