pub enum BinaryOperator {
Show 30 variants
Index,
Multiply,
Divide,
Modulo,
Plus,
Minus,
ShiftLeft,
ShiftRight,
Less,
Greater,
LessOrEqual,
GreaterOrEqual,
Equals,
NotEquals,
BitwiseAnd,
BitwiseXor,
BitwiseOr,
LogicalAnd,
LogicalOr,
Assign,
AssignMultiply,
AssignDivide,
AssignModulo,
AssignPlus,
AssignMinus,
AssignShiftLeft,
AssignShiftRight,
AssignBitwiseAnd,
AssignBitwiseXor,
AssignBitwiseOr,
}
Expand description
All operators with two operands
(C11 6.5)
Variants§
Index
lhs[rhs]
Multiply
lhs * rhs
Divide
lhs / rhs
Modulo
lhs % rhs
Plus
lhs + rhs
Minus
lhs - rhs
ShiftLeft
lhs << rhs
ShiftRight
lhs >> rhs
Less
lhs < rhs
Greater
lhs > rhs
LessOrEqual
lhs <= rhs
GreaterOrEqual
lhs >= rhs
Equals
lhs == rhs
NotEquals
lhs != rhs
BitwiseAnd
lhs & rhs
BitwiseXor
lhs ^ rhs
BitwiseOr
lhs | rhs
LogicalAnd
lhs && rhs
LogicalOr
lhs || rhs
Assign
lhs = rhs
AssignMultiply
lhs *= rhs
AssignDivide
lhs /= rhs
AssignModulo
lhs %= rhs
AssignPlus
lhs += rhs
AssignMinus
lhs -= rhs
AssignShiftLeft
lhs <<= rhs
AssignShiftRight
lhs >>= rhs
AssignBitwiseAnd
lhs &= rhs
AssignBitwiseXor
lhs ^= rhs
AssignBitwiseOr
lhs |= rhs
Trait Implementations§
Source§impl Clone for BinaryOperator
impl Clone for BinaryOperator
Source§fn clone(&self) -> BinaryOperator
fn clone(&self) -> BinaryOperator
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for BinaryOperator
impl Debug for BinaryOperator
Source§impl Hash for BinaryOperator
impl Hash for BinaryOperator
Source§impl PartialEq for BinaryOperator
impl PartialEq for BinaryOperator
impl Eq for BinaryOperator
impl StructuralPartialEq for BinaryOperator
Auto Trait Implementations§
impl Freeze for BinaryOperator
impl RefUnwindSafe for BinaryOperator
impl Send for BinaryOperator
impl Sync for BinaryOperator
impl Unpin for BinaryOperator
impl UnwindSafe for BinaryOperator
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