Skip to main content

UpdateTry

Trait UpdateTry 

Source
pub trait UpdateTry {
    // Required method
    spec fn branch(self) -> UpdateControlFlow;
}

Required Methods§

Dyn Compatibility§

This trait is dyn compatible.

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

Implementations on Foreign Types§

Source§

impl UpdateTry for ()

Source§

open spec fn branch(self) -> UpdateControlFlow

{ UpdateControlFlow::Commit }
Source§

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

Source§

open spec fn branch(self) -> UpdateControlFlow

{
    match self {
        Ok(_) => UpdateControlFlow::Commit,
        Err(_) => UpdateControlFlow::Abort,
    }
}

Implementors§

Source§

impl<T> UpdateTry for Commit<T>