flatMapTuple2<A, A2> function

TaskOption Function(TaskOption<A> o) flatMapTuple2<A, A2>(
  1. TaskOption<A2> f(
    1. A a
    )
)

A variant of flatMap that appends the result to a tuple.

Implementation

TaskOption<Tuple2<A, A2>> Function(TaskOption<A> o) flatMapTuple2<A, A2>(
  TaskOption<A2> Function(A a) f,
) =>
    flatMap((a) => f(a).p(map((b) => tuple2(a, b))));