import type * as HKT from "@principia/prelude/HKT"; import type { FiberId } from "../../Fiber/FiberId"; export type Cause = Empty | Fail | Die | Interrupt | Then | Both; export interface Empty { readonly _tag: "Empty"; } export interface Fail { readonly _tag: "Fail"; readonly value: E; } export interface Die { readonly _tag: "Die"; readonly value: unknown; } export interface Interrupt { readonly _tag: "Interrupt"; readonly fiberId: FiberId; } export interface Then { readonly _tag: "Then"; readonly left: Cause; readonly right: Cause; } export interface Both { readonly _tag: "Both"; readonly left: Cause; readonly right: Cause; } export const URI = "Cause"; export type URI = typeof URI; export type V = HKT.Auto;