pub trait LinearType: PrimitiveType {
    // Required method
    fn is_linear(&self) -> bool;
}
Expand description

Primitive type which supports a notion of linearity. Linear types are types that can be used in arithmetic ops.

Required Methods§

source

fn is_linear(&self) -> bool

Returns true iff this type is linear.

Implementors§

source§

impl LinearType for Num

Numbers are linear, Boolean values are not.