pub enum Outcome<M, E> {
Failed(E),
Module(M, Vec<E>),
}Expand description
What a checker hands ModuleWalker::check_in_order back for one module.
A module with errors can still have a shape: it has the interface its declarations
that canonicalized give it, whatever the typer says of them, and a typed tree for
each declaration the typer did not reject
(DEC-23 decisions 1, 2 and 5). So “checked” and
“failed” are not the only two answers: Module carries a module
together with everything wrong with it.
Variants§
Failed(E)
Nothing to publish.
Module(M, Vec<E>)
A module, and everything wrong with it. An empty list does not say the module checked: a checker may drop an error that restates another module’s failure, so the caller reads the module for whether it is whole as well.
Trait Implementations§
Auto Trait Implementations§
impl<M, E> Freeze for Outcome<M, E>
impl<M, E> RefUnwindSafe for Outcome<M, E>where
E: RefUnwindSafe,
M: RefUnwindSafe,
impl<M, E> Send for Outcome<M, E>
impl<M, E> Sync for Outcome<M, E>
impl<M, E> Unpin for Outcome<M, E>
impl<M, E> UnsafeUnpin for Outcome<M, E>where
E: UnsafeUnpin,
M: UnsafeUnpin,
impl<M, E> UnwindSafe for Outcome<M, E>where
E: UnwindSafe,
M: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more