Trait Contexting

Source
pub trait Contexting<Atom>:
    Sized
    + Add<Atom, Output = Self>
    + BitOr<Output = Self>
    + ProvideElement {
    // Required method
    fn new(atom: Atom) -> Self;
}
Expand description

Contexting is a trait used to report failure and error. This idea is too have a tree of context that will help final user to understand the error. It’s can also help for debugging purpose.

Required Methods§

Source

fn new(atom: Atom) -> Self

Create a new Context from a Atom. Implementation should try to avoid allocate for only one Atom.

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§