def close.answer

bend-kit-runner@0.13.0.1 · runner.bend:1729

import bend-kit-runner@0.13.0.1/runner.bend as Runner
import Base

1729def close.answer(-A: Data, m: Msg<A>) -> IO(Unit):
1730  match m:
1731    case Ended{id, o}:
1732      IO.pure(Unit, Unit{})
1733    case Add{d, x, rep}:
1734      do IO<Unit>:
1735        y : Result<&1, &1, Out(Nat), Unit> <- Chan.send(Out(Nat), rep, Fail{(32, "runner: the runner closed")})
1736        return Unit{}
1737    case Drop{i, rep}:
1738      do IO<Unit>:
1739        y : Result<&1, &1, Out(Unit), Unit> <- Chan.send(Out(Unit), rep, Fail{(32, "runner: the runner closed")})
1740        return Unit{}

Uses (10)

Used by (1)