[−][src]Enum boa::syntax::ast::op::LogOp
Logical operators are typically used with Boolean (logical) values; when they are, they return a Boolean value.
However, the &&
and ||
operators actually return the value of one of the specified operands,
so if these operators are used with non-Boolean values, they may return a non-Boolean value.
More information:
Variants
The logical AND operator returns the value of the first operand if it can be coerced into false
;
otherwise, it returns the second operand.
Syntax: x && y
More information:
The logical OR operator returns the value the first operand if it can be coerced into true
;
otherwise, it returns the second operand.
Syntax: x || y
More information:
- [ECMAScript reference](
- [MDN documentation][mdn]
[spec]: https://tc39.es/ecma262/#prod-LogicalORExpression) [mdn]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Logical_Operators#Logical_OR
Trait Implementations
impl Clone for LogOp
[src]
impl Copy for LogOp
[src]
impl Debug for LogOp
[src]
impl Display for LogOp
[src]
impl Finalize for LogOp
[src]
impl From<LogOp> for BinOp
[src]
impl PartialEq<LogOp> for LogOp
[src]
impl StructuralPartialEq for LogOp
[src]
impl Trace for LogOp
[src]
Auto Trait Implementations
impl RefUnwindSafe for LogOp
impl Send for LogOp
impl Sync for LogOp
impl Unpin for LogOp
impl UnwindSafe for LogOp
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> NativeObject for T where
T: Any + Debug + Trace,
[src]
T: Any + Debug + Trace,
fn as_any(&Self) -> &(dyn Any + 'static)
[src]
fn as_mut_any(&mut Self) -> &mut (dyn Any + 'static)
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> 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<U> 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<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,