#NEWLINE# def add( * args ) : #NEWLINE# #INDENT# def decorator( function ) : #NEWLINE# #INDENT# registry [ name ] = function #NEWLINE# return function #NEWLINE# #UNINDENT# if ( ( len ( args ) == 1 ) and six . callable ( args [ 0 ] ) ) : #NEWLINE# #INDENT# function = args [ 0 ] #NEWLINE# name = function . __name__ #NEWLINE# return decorator ( function ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( len ( args ) == 2 ) : #NEWLINE# #INDENT# registry [ args [ 0 ] ] = args [ 1 ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# name = args [ 0 ] #NEWLINE# return decorator