result-transformer-flow 0.0.2

Traits, macros and utilities for transforming Result values.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use crate::sync::flow::ErrFlow;

use crate::__internal::shared_step::ErrTapStep;

impl<InputErr, OutputErr, TapFn> ErrFlow<InputErr> for ErrTapStep<InputErr, OutputErr, TapFn>
where
    TapFn: Fn(InputErr) -> OutputErr,
{
    type OutputErr = OutputErr;

    /// Implementation of [`ErrFlow::apply_err`].
    fn apply_err(&self, input_ok: InputErr) -> Self::OutputErr {
        self.apply(input_ok)
    }
}