Created
July 2, 2013 16:48
-
-
Save jkempff/5910993 to your computer and use it in GitHub Desktop.
Schönfinkelize
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function schonfinkelize (fn) { | |
var slice = Array.prototype.slice, | |
defaults = slice.call(arguments,1); | |
return function () { | |
var new_args = slice.call(arguments), | |
args = defaults.concat(new_args); | |
return fn.apply(null,args); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment