git.iko.soy/rowtype-yoga/psfp
on 134dc56 help sign in
28 lines 743 B history raw
1// Generated by purs version 0.13.6
2"use strict";
3var Control_Apply = require("../Control.Apply/index.js");
4var Applicative = function (Apply0, pure) {
5 this.Apply0 = Apply0;
6 this.pure = pure;
7};
8var pure = function (dict) {
9 return dict.pure;
10};
11var liftA1 = function (dictApplicative) {
12 return function (f) {
13 return function (a) {
14 return Control_Apply.apply(dictApplicative.Apply0())(pure(dictApplicative)(f))(a);
15 };
16 };
17};
18var applicativeArray = new Applicative(function ($dollar__unused) {
19 return Control_Apply.applyArray;
20}, function (x) {
21 return [ x ];
22});
23module.exports = {
24 Applicative: Applicative,
25 pure: pure,
26 liftA1: liftA1,
27 applicativeArray: applicativeArray
28};