1 | var _curry2 =
|
2 |
|
3 | require("./_curry2");
|
4 |
|
5 | var _xfBase =
|
6 |
|
7 | require("./_xfBase");
|
8 |
|
9 | var XMap =
|
10 |
|
11 | function () {
|
12 | function XMap(f, xf) {
|
13 | this.xf = xf;
|
14 | this.f = f;
|
15 | }
|
16 |
|
17 | XMap.prototype['@@transducer/init'] = _xfBase.init;
|
18 | XMap.prototype['@@transducer/result'] = _xfBase.result;
|
19 |
|
20 | XMap.prototype['@@transducer/step'] = function (result, input) {
|
21 | return this.xf['@@transducer/step'](result, this.f(input));
|
22 | };
|
23 |
|
24 | return XMap;
|
25 | }();
|
26 |
|
27 | var _xmap =
|
28 |
|
29 | _curry2(function _xmap(f, xf) {
|
30 | return new XMap(f, xf);
|
31 | });
|
32 |
|
33 | module.exports = _xmap; |
\ | No newline at end of file |