import { Arity2 , Curry2 } from '../types' ; export function curry2 < A , B , C > ( fn ) ; export function curry2 ( fn ) ; export function curry2 < A , B , C > ( fn ) { function curried ( a , b ) { switch ( arguments . length ) { case 1 : return ( b ) => fn ( a , b ) ; default : return fn ( a , b ) ; } } return curried as Curry2 < A , B , C > ; }