def close

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

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

1763# Closes the inbox and the journal. Each ask still in the inbox gets a failure, and no op is appended for it.
1764def close(-A: Data, r: Runner<A>) -> IO(Unit):
1765  Runner{j, s, +p, c, +ib, fs} = r
1766  do IO<Unit>:
1767    Chan.close(Msg<A>, ib)
1768    close.drain(A, Nat.add(2n, Res.capacity(p)), ib)
1769    log.close(j)

Uses (10)

Used by (1)