UNPKG

@effect-ts/system

Version:

Effect-TS is a zero dependency set of libraries to write highly productive, purely functional TypeScript at scale.

11 lines (10 loc) 379 B
import { empty } from "../Cause/cause.mjs"; import { foldCauseM_, succeed } from "./core.mjs"; /** * Returns an effect that succeeds with the cause of failure of this effect, * or `Cause.empty` if the effect did not succeed. */ export function cause(effect, __trace) { return foldCauseM_(effect, succeed, () => succeed(empty), __trace); } //# sourceMappingURL=cause.mjs.map