Trait rustc_ap_rustc_target::abi::MaybeResult [−][src]
pub trait MaybeResult<T> { type Error; fn from(x: Result<T, Self::Error>) -> Self; fn to_result(self) -> Result<T, Self::Error>; }
Expand description
The TyAndLayout
above will always be a MaybeResult<TyAndLayout<'_, Self>>
.
We can’t add the bound due to the lifetime, but this trait is still useful when
writing code that’s generic over the LayoutOf
impl.
Associated Types
Required methods
Implementations on Foreign Types
impl<T, E> MaybeResult<T> for Result<T, E>
[src]
impl<T, E> MaybeResult<T> for Result<T, E>
[src]