-# This function and its data should move into daklib/extensions.py
-# or something.
-replaced_funcs = {}
-replace_funcs = {}
-def replace_dak_function(module,name):
- def x(f):
- def myfunc(*a,**kw):
- global replaced_funcs
- f(replaced_funcs[name], *a, **kw)
- myfunc.__name__ = f.__name__
- myfunc.__doc__ = f.__doc__
- myfunc.__dict__.update(f.__dict__)
-
- replace_funcs["%s:%s" % (module,name)] = myfunc
- return f
- return x