Skip to main content

Pure

Trait Pure 

Source
pub trait Pure<A> {
    // Required method
    fn pure(value: A) -> Self;
}
Expand description

Pure lets you construct a value of type F<A> using a single value of A.

Required Methods§

Source

fn pure(value: A) -> Self

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementations on Foreign Types§

Source§

impl<A, B, S> Pure<(A, B)> for HashMap<A, B, S>
where A: Hash + Eq, B: Hash + Eq, S: BuildHasher + Default,

Source§

fn pure(value: (A, B)) -> Self

Source§

impl<A, B> Pure<(A, B)> for BTreeMap<A, B>
where A: Ord, B: Ord,

Source§

fn pure(value: (A, B)) -> Self

Source§

impl<A, E> Pure<A> for Result<A, E>

Source§

fn pure(value: A) -> Self

Source§

impl<A, S> Pure<A> for HashSet<A, S>
where A: Hash + Eq, S: BuildHasher + Default,

Source§

fn pure(value: A) -> Self

Source§

impl<A> Pure<A> for BTreeSet<A>
where A: Ord,

Source§

fn pure(value: A) -> Self

Source§

impl<A> Pure<A> for BinaryHeap<A>
where A: Ord,

Source§

fn pure(value: A) -> Self

Source§

impl<A> Pure<A> for LinkedList<A>

Source§

fn pure(value: A) -> Self

Source§

impl<A> Pure<A> for Option<A>

Source§

fn pure(value: A) -> Self

Source§

impl<A> Pure<A> for Vec<A>

Source§

fn pure(value: A) -> Self

Source§

impl<A> Pure<A> for VecDeque<A>

Source§

fn pure(value: A) -> Self

Implementors§