// ets_tracing: off import type * as T from "../../../../Effect/index.js" import * as CH from "../../Channel/index.js" import * as C from "../core.js" /** * Executes the provided finalizer after this stream's finalizers run. */ export function ensuring_( self: C.Stream, fin: T.Effect ): C.Stream { return new C.Stream(CH.ensuring_(self.channel, fin)) } /** * Executes the provided finalizer after this stream's finalizers run. * * @ets_data_first ensuring_ */ export function ensuring(fin: T.Effect) { return (self: C.Stream) => ensuring_(self, fin) }