|
|
@@ -7,7 +7,7 @@ export type Done = typeof Done
|
|
|
|
|
|
export interface Sink<T, Mat> {
|
|
|
builder: SinkBuilder<Mat>
|
|
|
- __phanthom__: T
|
|
|
+ __phantom__: T
|
|
|
}
|
|
|
|
|
|
interface SinkBuilder<M> {
|
|
|
@@ -27,7 +27,7 @@ export const sum: Sink<number, number> = {
|
|
|
}).on('finish', () => out(result))
|
|
|
},
|
|
|
},
|
|
|
- __phanthom__: Phantom(),
|
|
|
+ __phantom__: Phantom(),
|
|
|
}
|
|
|
|
|
|
export const ignore: Sink<any, Done> = {
|
|
|
@@ -41,7 +41,7 @@ export const ignore: Sink<any, Done> = {
|
|
|
}).on('finish', () => out(Done))
|
|
|
},
|
|
|
},
|
|
|
- __phanthom__: Phantom(),
|
|
|
+ __phantom__: Phantom(),
|
|
|
}
|
|
|
|
|
|
export function reduce<V, Mat>(reduceFn: (acc: Mat, v: V) => Mat, zero: Mat): Sink<V, Mat> {
|
|
|
@@ -58,7 +58,7 @@ export function reduce<V, Mat>(reduceFn: (acc: Mat, v: V) => Mat, zero: Mat): Si
|
|
|
}).on('finish', () => out(acc))
|
|
|
},
|
|
|
},
|
|
|
- __phanthom__: Phantom(),
|
|
|
+ __phantom__: Phantom(),
|
|
|
}
|
|
|
}
|
|
|
|
|
|
@@ -75,6 +75,6 @@ export function forEach<T>(fn: (t: T) => void): Sink<T, Done> {
|
|
|
}).on('finish', () => out(Done))
|
|
|
},
|
|
|
},
|
|
|
- __phanthom__: Phantom(),
|
|
|
+ __phantom__: Phantom(),
|
|
|
}
|
|
|
}
|