Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
evalAsync( _func, env, (err, _env, _, func) => {
if (func instanceof Function) {
let cbfn = (arg, _cb) => {
nextTick (func, null, env, (err, _env, _, val) => {_cb(err, val);}, arg.val, arg.index);
}
if (_map.equal(xarray[0]))
mapLimit (arr, 32, cbfn, (err, newarr) => {
if (seq.__itype__==='sequence') cb( err, env, null, new Sequence(newarr));
else cb( err, env, null, newarr);
});
else
filterLimit (arr, 32, cbfn, (err, newarr) => {
let retarr = [];
for (let it of newarr) retarr.push(it.val);
if (seq.__itype__==='sequence') cb( err, env, null, new Sequence(retarr));
else cb( err, env, null, retarr);
});
}
else cb( Cell.stringify(_func)+' is not a Function');
});
}