export declare function getAsyncIteratorWithCancel(asyncIterator: AsyncIterator, onCancel: (value?: TReturn) => void | Promise): AsyncIterator; export declare function getAsyncIterableWithCancel, TReturn = any>(asyncIterable: TAsyncIterable, onCancel: (value?: TReturn) => void | Promise): TAsyncIterable; export { getAsyncIterableWithCancel as withCancel };