#NEWLINE# def partial( func , * args , **keywords ) : #NEWLINE# #INDENT# def newfunc( * fargs , **fkeywords ) : #NEWLINE# #INDENT# newkeywords = keywords . copy ( ) #NEWLINE# newkeywords . update ( fkeywords ) #NEWLINE# return func ( * ( args + fargs ) , ** newkeywords ) #NEWLINE# #UNINDENT# newfunc . func = args #NEWLINE# newfunc . args = args #NEWLINE# newfunc . keywords = keywords #NEWLINE# return newfunc