Trait libspecr::MonadicReturn

source ·
pub trait MonadicReturn {
    type Inner;

    // Required method
    fn monadic_return(t: Self::Inner) -> Self;
}
Expand description

Satisfied by types that can be constructed from some inner types.

Required Associated Types§

source

type Inner

The inner type.

Required Methods§

source

fn monadic_return(t: Self::Inner) -> Self

Wraps a value of Self::Inner into a Self.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl<T> MonadicReturn for Option<T>

§

type Inner = T

source§

fn monadic_return(t: T) -> Self

source§

impl<T, E> MonadicReturn for Result<T, E>

§

type Inner = T

source§

fn monadic_return(t: T) -> Self

Implementors§

source§

impl<T> MonadicReturn for Nondet<T>

§

type Inner = T

source§

impl<T, E> MonadicReturn for NdResult<T, E>

§

type Inner = T