Innovenergy_trunk/frontend/node_modules/fp-ts/lib/Strong.js

26 lines
739 B
JavaScript
Raw Normal View History

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.fanout = exports.splitStrong = exports.fanOut = exports.split = void 0;
var function_1 = require("./function");
function split(S, C) {
return function (pab, pcd) {
return C.compose(S.second(pcd), S.first(pab));
};
}
exports.split = split;
function fanOut(S, C) {
var splitSC = split(S, C);
return function (pab, pac) {
return C.compose(splitSC(pab, pac), S.promap(C.id(), function_1.identity, function (a) { return [a, a]; }));
};
}
exports.fanOut = fanOut;
function splitStrong(F) {
return split(F, F);
}
exports.splitStrong = splitStrong;
function fanout(F) {
return fanOut(F, F);
}
exports.fanout = fanout;