Expand description
ApplySecond type class.
This module defines the ApplySecond trait, which provides the ability to sequence two computations
but discard the result of the first computation, keeping only the result of the second.
§Examples
use fp_library::{brands::*, functions::*};
let x = Some(5);
let y = Some(10);
let z = apply_second::<OptionBrand, _, _>(x, y);
assert_eq!(z, Some(10));Traits§
- Apply
Second - A type class for types that support combining two contexts, keeping the second value.
Functions§
- apply_
second - Combines two contexts, keeping the value from the second context.