"use strict";Object.defineProperty(exports, "__esModule", {value: true});

var _chunkS2Z5L3RBjs = require('./chunk-S2Z5L3RB.js');


var _chunkS3T27X3Ujs = require('./chunk-S3T27X3U.js');




var _chunkOTKMOSH2js = require('./chunk-OTKMOSH2.js');


var _chunk6C3VEZWHjs = require('./chunk-6C3VEZWH.js');

// src/ValidationT.ts
var ValidationT_exports = {};
_chunk6C3VEZWHjs.__export.call(void 0, ValidationT_exports, {
  getValidationM: () => getValidationM
});
function getValidationM(S, M) {
  const A = _chunkS3T27X3Ujs.getApplicativeComposition.call(void 0, M, _chunkS2Z5L3RBjs.getApplicativeValidation.call(void 0, S));
  return {
    map: A.map,
    ap: A.ap,
    of: A.of,
    chain: (ma, f) => M.chain(ma, (e) => _chunkOTKMOSH2js.isLeft.call(void 0, e) ? M.of(_chunkOTKMOSH2js.left.call(void 0, e.left)) : f(e.right)),
    alt: (me, that) => M.chain(
      me,
      (e1) => _chunkOTKMOSH2js.isRight.call(void 0, e1) ? M.of(e1) : M.map(that(), (e2) => _chunkOTKMOSH2js.isLeft.call(void 0, e2) ? _chunkOTKMOSH2js.left.call(void 0, S.concat(e1.left, e2.left)) : e2)
    )
  };
}




exports.getValidationM = getValidationM; exports.ValidationT_exports = ValidationT_exports;
