andThen<U> method
Returns a Result
value as Err<U, E> if this Result
is Err<T, E>,
otherwise calls fn
with the held Ok value and returns the returned Result
.
See also:
Rust: Result::and_then()
Implementation
Result<U, E> andThen<U>(Result<U, E> Function(T) fn) => switch (this) {
Ok(:T v) => fn(v),
Err(:E e) => Err(e)
};