import { AttachSink } from './types'
import { Stream } from '@most/types'
import { curry2 } from '@most/prelude'
export const attach: AttachFn = curry2(__attach)
export type AttachFn = {
(sink: AttachSink, stream: Stream): Stream
(sink: AttachSink): (stream: Stream) => Stream
}
function __attach(sink: AttachSink, stream: Stream): Stream {
return sink.attach(stream)
}