import * as tsplus_module_1 from "@effect/core/io/Random/definition";
import * as tsplus_module_2 from "@effect/core/io/definition";
import * as tsplus_module_3 from "@effect/core/io/FiberRef/operations/getWith";
/**
 * Retreives the `Random` service from the environment and uses it to run the
 * specified workflow.
 *
 * @tsplus static ets/Effect/Ops randomWith
 */

export function randomWith(f, __tsplusTrace) {
  return tsplus_module_3.getWith_(tsplus_module_2.services.value, services => f(services.get(tsplus_module_1.Random.Tag)), __tsplusTrace);
}
//# sourceMappingURL=randomWith.mjs.map