import * as tsplus_module_1 from "@tsplus/stdlib/collections/Chunk/range";
import * as tsplus_module_2 from "@tsplus/stdlib/collections/Chunk/map";
export const replicate = replicate_1;
/**
 * Replicates the given effect `n` times.
 *
 * @tsplus static ets/STM/Ops replicate
 */

function replicate_1(n, stm) {
  return tsplus_module_2.map_(tsplus_module_1.range(0, n - 1), stm);
}
/**
 * Replicates the given effect `n` times.
 *
 * @tsplus fluent ets/STM replicate
 */


export function replicateNow_(self, n) {
  return replicate_1(n, () => self);
}
/**
 * Replicates the given effect `n` times.
 *
 * @tsplus static ets/STM/Aspects replicate
 */

export const replicateNow = n => self => replicateNow_(self, n);
//# sourceMappingURL=replicate.mjs.map