Skip to main content

Convolutional

Trait Convolutional 

Source
pub trait Convolutional<F: HKT>: Semigroupal<F> { }
Expand description

Marker. Promises that ฯ† associates under Day convolution: a monoid object in (End(๐’ž), โŠ›, Id).

The promise is zip(zip(a, b), c) โ‰… zip(a, zip(b, c)) up to reassociation, together with the naturality of ฯ†. The compiler cannot check either, so implementing this trait is an assertion by the developer.

Carries the same no-inference discipline as Compositional, and the same coherence obligation when a witness holds both.

Dyn Compatibilityยง

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementorsยง