import * as tsplus_module_1 from "@effect/core/stream/Sink/operations/map";
import * as tsplus_module_2 from "@effect/core/stream/Sink/operations/flatMap";
/**
 * Feeds inputs to this sink until it yields a result, then switches over to
 * the provided sink until it yields a result, finally combining the two
 * results with `f`.
 *
 * @tsplus fluent ets/Sink zipWith
 */

export function zipWith_(self, that, f, __tsplusTrace) {
  return tsplus_module_2.flatMap_(self, z => tsplus_module_1.map_(that(), z1 => f(z, z1), __tsplusTrace));
}
/**
 * Feeds inputs to this sink until it yields a result, then switches over to
 * the provided sink until it yields a result, finally combining the two
 * results with `f`.
 *
 * @tsplus static ets/Sink/Aspects zipWith
 */

export const zipWith = (that, f, __tsplusTrace) => self => zipWith_(self, that, f, __tsplusTrace);
//# sourceMappingURL=zipWith.mjs.map