MonadFail for OptionClass
This commit is contained in:
parent
bd361833b5
commit
41972e28c5
@ -123,6 +123,15 @@ impl LocalFunctor for OptionClass {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl MonadFail<()> for OptionClass {
|
||||||
|
fn fail<'a, A: 'a>(_e: ()) -> Self::F<'a, A>
|
||||||
|
where
|
||||||
|
Self: 'a,
|
||||||
|
(): 'a {
|
||||||
|
None
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod option_tests {
|
mod option_tests {
|
||||||
use super::{test_suite, tests, Functor};
|
use super::{test_suite, tests, Functor};
|
||||||
|
Loading…
Reference in New Issue
Block a user