Template Function rsl::mbind(tl::expected<T, E> const&, Fn)
Defined in File monad.hpp
Function Documentation
-
template<typename T, typename E, typename Fn>
constexpr auto rsl::mbind(tl::expected<T, E> const &exp, Fn fn) -> std::invoke_result_t<Fn, T> Monad tl::expected<T,E>
- Parameters:
exp – tl::expected<T,E> input
fn – Function to apply
- Template Parameters:
T – Type for the input expected
E – Error type
Fn – Function
- Returns:
Return type of the function