UNPKG

crocks

Version:

A collection of well known Algebraic Datatypes for your utter enjoyment.

17 lines (12 loc) 394 B
/** @license ISC License (c) copyright 2017 original and current authors */ /** @author Ian Hofmann-Hicks (evil) */ var curryN = require('../core/curryN') var isFunction = require('../core/isFunction') // binary : (* -> c) -> a -> b -> c function binary(fn) { if(!isFunction(fn)) { throw new TypeError('binary: Function required') } return curryN(2, fn) } module.exports = binary