import { AsyncStream } from '../uri'; /** * A useful recursion pattern for processing an {@link AsyncStream} to produce * a new array, often used for "chopping" up the input {@link AsyncStream}. * * Typically `chop` is called with some function that will consume an initial * prefix of the {@link AsyncStream} and produce a value and the rest of the * {@link AsyncStream}. * * @export * @template A The value type. * @template B The chopped value type. * @param {(fa: AsyncStream) => [ B, AsyncStream ] | Promise<[ B, AsyncStream ]>} f The chop function. * @return {(fa: AsyncStream) => AsyncStream} A function that takes a stream to * chop the first element of it. * * @__PURE__ */ export declare function chop(f: (fa: AsyncStream) => [B, AsyncStream] | Promise<[B, AsyncStream]>): (fa: AsyncStream) => AsyncStream;