Currying decorator in python

前端 未结 9 1807
故里飘歌
故里飘歌 2020-12-03 03:11

I am trying to write a currying decorator in python, and I think I\'ve got the general idea down, but still got some cases that aren\'t working right...

def          


        
9条回答
  •  臣服心动
    2020-12-03 03:53

    The source code for curry in the toolz library is available at the following link.

    https://github.com/pytoolz/toolz/blob/master/toolz/functoolz.py

    It handles args, kwargs, builtin functions, and error handling. It even wraps the docstrings back onto the curried object.

提交回复
热议问题