Trait BinaryOperable

Source
pub trait BinaryOperable {
    // Required method
    fn bin_op(self, op: BinOpKind, rhs: impl Into<Expr>) -> Binary;

    // Provided methods
    fn add(self, rhs: impl Into<Expr>) -> Binary
       where Self: Sized { ... }
    fn sub(self, rhs: impl Into<Expr>) -> Binary
       where Self: Sized { ... }
    fn mul(self, rhs: impl Into<Expr>) -> Binary
       where Self: Sized { ... }
    fn div(self, rhs: impl Into<Expr>) -> Binary
       where Self: Sized { ... }
}

Required Methods§

Source

fn bin_op(self, op: BinOpKind, rhs: impl Into<Expr>) -> Binary

Provided Methods§

Source

fn add(self, rhs: impl Into<Expr>) -> Binary
where Self: Sized,

Source

fn sub(self, rhs: impl Into<Expr>) -> Binary
where Self: Sized,

Source

fn mul(self, rhs: impl Into<Expr>) -> Binary
where Self: Sized,

Source

fn div(self, rhs: impl Into<Expr>) -> Binary
where Self: Sized,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§