New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

bs-sentia-std

Package Overview
Dependencies
Maintainers
1
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bs-sentia-std - npm Package Compare versions

Comparing version 12.0.0 to 12.0.1

lib/js/src/list.js

2

bsconfig.json

@@ -9,4 +9,4 @@ // This is the configuration file used by BuckleScript's build system bsb. Its documentation lives here: http://bucklescript.github.io/bucklescript/docson/#build-schema.json

"sources": [
{"dir": "src"}
{"dir": "src", "public": ["Std"]}
]
}

@@ -9,2 +9,5 @@ // Generated by BUCKLESCRIPT VERSION 1.9.0, PLEASE EDIT WITH CARE

var Js_exn = require("bs-platform/lib/js/js_exn.js");
var Option = require("./option.js");
var Remote = require("./remote.js");
var Result = require("./result.js");
var $$String = require("bs-platform/lib/js/string.js");

@@ -56,392 +59,30 @@ var Js_dict = require("bs-platform/lib/js/js_dict.js");

function some(a) {
return /* Some */[a];
}
function map(f, opt) {
if (opt) {
return /* Some */[Curry._1(f, opt[0])];
} else {
return /* None */0;
}
}
function map2(f, opt1, opt2) {
if (opt1 && opt2) {
return /* Some */[Curry._2(f, opt1[0], opt2[0])];
} else {
return /* None */0;
}
}
function map3(f, opt1, opt2, opt3) {
if (opt1 && opt2 && opt3) {
return /* Some */[Curry._3(f, opt1[0], opt2[0], opt3[0])];
} else {
return /* None */0;
}
}
function flatten(opt) {
if (opt) {
return opt[0];
} else {
return /* None */0;
}
}
function flatMap(f, opt) {
if (opt) {
return Curry._1(f, opt[0]);
} else {
return /* None */0;
}
}
function withDefault(defaultValue, opt) {
if (opt) {
return opt[0];
} else {
return defaultValue;
}
}
function fromResult(res) {
if (res.tag) {
return /* Some */[res[0]];
} else {
return /* None */0;
}
}
function fromRemote(res) {
if (typeof res === "number" || res.tag !== 1) {
return /* None */0;
} else {
return /* Some */[res[0]];
}
}
function isNone(param) {
if (param) {
return /* false */0;
} else {
return /* true */1;
}
}
function isSome(param) {
if (param) {
return /* true */1;
} else {
return /* false */0;
}
}
function encode(encoder, param) {
if (param) {
return Curry._1(encoder, param[0]);
} else {
return null;
}
}
var Option = /* module */[
/* some */some,
/* none : None */0,
/* map */map,
/* map2 */map2,
/* map3 */map3,
/* flatten */flatten,
/* flatMap */flatMap,
/* withDefault */withDefault,
/* fromResult */fromResult,
/* fromRemote */fromRemote,
/* isNone */isNone,
/* isSome */isSome,
/* encode */encode,
/* decode */Json_decode.optional
var Option$1 = /* module */[
/* some */Option.some,
/* none */Option.none,
/* map */Option.map,
/* map2 */Option.map2,
/* map3 */Option.map3,
/* flatten */Option.flatten,
/* flatMap */Option.flatMap,
/* withDefault */Option.withDefault,
/* fromResult */Option.fromResult,
/* fromRemote */Option.fromRemote,
/* isNone */Option.isNone,
/* isSome */Option.isSome,
/* encode */Option.encode,
/* decode */Option.decode
];
function ready(a) {
return /* Ready */Block.__(1, [a]);
}
function error(x) {
return /* Failed */Block.__(0, [x]);
}
function map$1(f, remote) {
if (typeof remote === "number") {
if (remote) {
return /* Pending */1;
} else {
return /* NotAsked */0;
}
} else if (remote.tag) {
return /* Ready */Block.__(1, [Curry._1(f, remote[0])]);
} else {
return /* Failed */Block.__(0, [remote[0]]);
}
}
function map2$1(f, r1, r2) {
if (typeof r1 === "number") {
if (r1) {
return /* Pending */1;
} else {
return /* NotAsked */0;
}
} else if (r1.tag) {
if (typeof r2 === "number") {
if (r2) {
return /* Pending */1;
} else {
return /* NotAsked */0;
}
} else if (r2.tag) {
return /* Ready */Block.__(1, [Curry._2(f, r1[0], r2[0])]);
} else {
return /* Failed */Block.__(0, [r2[0]]);
}
} else {
return /* Failed */Block.__(0, [r1[0]]);
}
}
function map3$1(f, r1, r2, r3) {
if (typeof r1 === "number") {
if (r1) {
return /* Pending */1;
} else {
return /* NotAsked */0;
}
} else if (r1.tag) {
if (typeof r2 === "number") {
if (r2) {
return /* Pending */1;
} else {
return /* NotAsked */0;
}
} else if (r2.tag) {
if (typeof r3 === "number") {
if (r3) {
return /* Pending */1;
} else {
return /* NotAsked */0;
}
} else if (r3.tag) {
return /* Ready */Block.__(1, [Curry._3(f, r1[0], r2[0], r3[0])]);
} else {
return /* Failed */Block.__(0, [r3[0]]);
}
} else {
return /* Failed */Block.__(0, [r2[0]]);
}
} else {
return /* Failed */Block.__(0, [r1[0]]);
}
}
function flatten$1(r) {
if (typeof r === "number") {
if (r) {
return /* Pending */1;
} else {
return /* NotAsked */0;
}
} else if (r.tag) {
return r[0];
} else {
return /* Failed */Block.__(0, [r[0]]);
}
}
function flatMap$1(f, remote) {
if (typeof remote === "number") {
if (remote) {
return /* Pending */1;
} else {
return /* NotAsked */0;
}
} else if (remote.tag) {
return Curry._1(f, remote[0]);
} else {
return /* Failed */Block.__(0, [remote[0]]);
}
}
function withDefault$1(a, rem) {
if (typeof rem === "number" || rem.tag !== 1) {
return a;
} else {
return rem[0];
}
}
function fromResult$1(res) {
if (res.tag) {
return /* Ready */Block.__(1, [res[0]]);
} else {
return /* Failed */Block.__(0, [res[0]]);
}
}
function fromOption(opt) {
if (opt) {
return /* Ready */Block.__(1, [opt[0]]);
} else {
return /* NotAsked */0;
}
}
function isNotAsked(remote) {
if (typeof remote === "number" && remote === 0) {
return /* true */1;
} else {
return /* false */0;
}
}
function isPending(remote) {
if (typeof remote === "number" && remote !== 0) {
return /* true */1;
} else {
return /* false */0;
}
}
function isFailed(remote) {
if (typeof remote === "number" || remote.tag) {
return /* false */0;
} else {
return /* true */1;
}
}
function isReady(remote) {
if (typeof remote === "number" || remote.tag !== 1) {
return /* false */0;
} else {
return /* true */1;
}
}
function encode$1(failEncoder, successEncoder, r) {
if (typeof r === "number") {
if (r) {
return "Pending";
} else {
return "NotAsked";
}
} else if (r.tag) {
return Curry._1(successEncoder, r[0]);
} else {
return Curry._1(failEncoder, r[0]);
}
}
function map$2(f, res) {
if (res.tag) {
return /* Ok */Block.__(1, [Curry._1(f, res[0])]);
} else {
return /* Error */Block.__(0, [res[0]]);
}
}
function map2$2(f, r1, r2) {
if (r1.tag) {
if (r2.tag) {
return /* Ok */Block.__(1, [Curry._2(f, r1[0], r2[0])]);
} else {
return /* Error */Block.__(0, [r2[0]]);
}
} else {
return /* Error */Block.__(0, [r1[0]]);
}
}
function map3$2(f, r1, r2, r3) {
if (r1.tag) {
if (r2.tag) {
if (r3.tag) {
return /* Ok */Block.__(1, [Curry._3(f, r1[0], r2[0], r3[0])]);
} else {
return /* Error */Block.__(0, [r3[0]]);
}
} else {
return /* Error */Block.__(0, [r2[0]]);
}
} else {
return /* Error */Block.__(0, [r1[0]]);
}
}
function flatten$2(r) {
if (r.tag) {
return r[0];
} else {
return /* Error */Block.__(0, [r[0]]);
}
}
function flatMap$2(f, res) {
if (res.tag) {
return Curry._1(f, res[0]);
} else {
return /* Error */Block.__(0, [res[0]]);
}
}
function withDefault$2(a, res) {
if (res.tag) {
return res[0];
} else {
return a;
}
}
function fromOption$1(err, opt) {
if (opt) {
return /* Ok */Block.__(1, [opt[0]]);
} else {
return /* Error */Block.__(0, [err]);
}
}
function isError(res) {
if (res.tag) {
return /* false */0;
} else {
return /* true */1;
}
}
function isOk(res) {
if (res.tag) {
return /* true */1;
} else {
return /* false */0;
}
}
function encode$2(encodeError, encodeOk, param) {
if (param.tag) {
return Curry._1(encodeOk, param[0]);
} else {
return Curry._1(encodeError, param[0]);
}
}
var Result = /* module */[
/* map */map$2,
/* map2 */map2$2,
/* map3 */map3$2,
/* flatten */flatten$2,
/* flatMap */flatMap$2,
/* withDefault */withDefault$2,
/* fromOption */fromOption$1,
/* isError */isError,
/* isOk */isOk,
/* encode */encode$2
var Result$1 = /* module */[
/* map */Result.map,
/* map2 */Result.map2,
/* map3 */Result.map3,
/* flatten */Result.flatten,
/* flatMap */Result.flatMap,
/* withDefault */Result.withDefault,
/* fromOption */Result.fromOption,
/* isError */Result.isError,
/* isOk */Result.isOk,
/* encode */Result.encode
];

@@ -572,3 +213,3 @@

function flatten$3(xs) {
function flatten(xs) {
return foldLeft(append, /* [] */0, xs);

@@ -741,7 +382,7 @@ }

function map$3(f, xs) {
function map(f, xs) {
if (xs) {
return /* :: */[
Curry._1(f, xs[0]),
map$3(f, xs[1])
map(f, xs[1])
];

@@ -767,7 +408,7 @@ } else {

function map2$3(f, xs, ys) {
function map2(f, xs, ys) {
if (xs && ys) {
return /* :: */[
Curry._2(f, xs[0], ys[0]),
map2$3(f, xs[1], ys[1])
map2(f, xs[1], ys[1])
];

@@ -779,5 +420,5 @@ } else {

function flatMap$3(f, xs) {
function flatMap(f, xs) {
if (xs) {
return Pervasives.$at(Curry._1(f, xs[0]), flatMap$3(f, xs[1]));
return Pervasives.$at(Curry._1(f, xs[0]), flatMap(f, xs[1]));
} else {

@@ -890,3 +531,3 @@ return /* [] */0;

function any(f, xs) {
return isSome(find(f, xs));
return Option.isSome(find(f, xs));
}

@@ -1029,3 +670,3 @@

function contains$1(key, dict) {
return isSome(get(key, dict));
return Option.isSome(get(key, dict));
}

@@ -1060,3 +701,3 @@

function keys(dict) {
return map$3((function (param) {
return map((function (param) {
return param[0];

@@ -1067,3 +708,3 @@ }), dict);

function values(dict) {
return map$3((function (param) {
return map((function (param) {
return param[1];

@@ -1081,4 +722,4 @@ }), dict);

function map$4(f, dict) {
return map$3((function (param) {
function map$1(f, dict) {
return map((function (param) {
var k = param[0];

@@ -1093,3 +734,3 @@ return /* tuple */[

function mapValues(f, dict) {
return map$3((function (param) {
return map((function (param) {
return /* tuple */[

@@ -1103,3 +744,3 @@ param[0],

function mapKeys(f, dict) {
return map$3((function (param) {
return map((function (param) {
return /* tuple */[

@@ -1132,3 +773,3 @@ Curry._1(f, param[0]),

function encode$3(encodeKey, encodeValue, dict) {
function encode(encodeKey, encodeValue, dict) {
return Json_encode.object_(mapValues(encodeValue, mapKeys(encodeKey, dict)));

@@ -1152,3 +793,3 @@ }

/* iter */iter$1,
/* map */map$4,
/* map */map$1,
/* mapValues */mapValues,

@@ -1159,3 +800,3 @@ /* mapKeys */mapKeys,

/* foldRight */foldRight$1,
/* encode */encode$3,
/* encode */encode,
/* decode */decode

@@ -1438,3 +1079,3 @@ ];

function encode$4(prim) {
function encode$1(prim) {
return prim;

@@ -1463,3 +1104,3 @@ }

function map$5(f, task) {
function map$2(f, task) {
return (function (param, param$1) {

@@ -1472,3 +1113,3 @@ return Curry._2(task, param, (function (x) {

function map2$4(f, t1, t2) {
function map2$1(f, t1, t2) {
return (function (param, param$1) {

@@ -1483,3 +1124,3 @@ return Curry._2(t1, param, (function (a1) {

function map3$3(f, t1, t2, t3) {
function map3(f, t1, t2, t3) {
return (function (param, param$1) {

@@ -1496,3 +1137,3 @@ return Curry._2(t1, param, (function (a1) {

function flatMap$4(f, task) {
function flatMap$1(f, task) {
return (function (param, param$1) {

@@ -1532,3 +1173,3 @@ return Curry._2(task, param, (function (x) {

function fromOption$2(err, opt) {
function fromOption(err, opt) {
if (opt) {

@@ -1546,3 +1187,3 @@ var a = opt[0];

function fromResult$2(res) {
function fromResult(res) {
if (res.tag) {

@@ -1582,3 +1223,3 @@ var a = res[0];

if (exn[0] === Js_exn.$$Error) {
return /* Error */Block.__(0, [withDefault("Could not parse JSON", Js_primitive.undefined_to_opt(exn[1].message))]);
return /* Error */Block.__(0, [Option.withDefault("Could not parse JSON", Js_primitive.undefined_to_opt(exn[1].message))]);
} else {

@@ -1590,20 +1231,20 @@ throw exn;

var Remote = [
ready,
error,
/* Pending */1,
/* NotAsked */0,
map$1,
map2$1,
map3$1,
flatten$1,
flatMap$1,
withDefault$1,
fromResult$1,
fromOption,
isNotAsked,
isPending,
isFailed,
isReady,
encode$1
var Remote$1 = [
Remote.ready,
Remote.error,
Remote.pending,
Remote.notAsked,
Remote.map,
Remote.map2,
Remote.map3,
Remote.flatten,
Remote.flatMap,
Remote.withDefault,
Remote.fromResult,
Remote.fromOption,
Remote.isNotAsked,
Remote.isPending,
Remote.isFailed,
Remote.isReady,
Remote.encode
];

@@ -1620,3 +1261,3 @@

append,
flatten$3,
flatten,
zip,

@@ -1635,6 +1276,6 @@ head,

filter,
map$3,
map,
mapIndexed,
map2$3,
flatMap$3,
map2,
flatMap,
flatMap2,

@@ -1703,3 +1344,3 @@ filterMap,

contains$2,
encode$4,
encode$1,
Json_decode.string

@@ -1712,10 +1353,10 @@ ];

fail,
map$5,
map2$4,
map3$3,
map$2,
map2$1,
map3,
biMap,
flatMap$4,
flatMap$1,
fold,
fromResult$2,
fromOption$2,
fromResult,
fromOption,
fork,

@@ -1733,4 +1374,4 @@ fromLazyPromise

exports.tap = tap;
exports.Remote = Remote;
exports.Result = Result;
exports.Remote = Remote$1;
exports.Result = Result$1;
exports.List = List$1;

@@ -1740,5 +1381,5 @@ exports.Dict = Dict;

exports.Task = Task;
exports.Option = Option;
exports.Option = Option$1;
exports.decodeJSON = decodeJSON;
exports.parseJSON = parseJSON;
/* Js_dict Not a pure module */
{
"name": "bs-sentia-std",
"version": "12.0.0",
"version": "12.0.1",
"scripts": {

@@ -5,0 +5,0 @@ "clean": "bsb -clean-world",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc