pub trait ArqSpec {
type S: Clone;
type F: Clone;
// Required methods
fn op(a: &Self::S, b: &Self::S) -> Self::S;
fn identity() -> Self::S;
fn compose(f: &Self::F, g: &Self::F) -> Self::F;
fn apply(f: &Self::F, a: &Self::S, size: i64) -> Self::S;
}
Required Associated Types§
Required Methods§
Sourcefn op(a: &Self::S, b: &Self::S) -> Self::S
fn op(a: &Self::S, b: &Self::S) -> Self::S
Must satisfy the Associative Law: For all a,b,c, op(a, op(b, c)) = op(op(a, b), c)
Sourcefn identity() -> Self::S
fn identity() -> Self::S
Must satisfy the Identity Law: For all a, op(a, identity()) = op(identity(), a) = a
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.