diff options
| author | Michele Simionato <michele.simionato@gmail.com> | 2018-01-14 07:38:09 +0100 |
|---|---|---|
| committer | Michele Simionato <michele.simionato@gmail.com> | 2018-01-14 07:38:09 +0100 |
| commit | 6e4cb6763624e199cba37053f4a530630204250f (patch) | |
| tree | dfc8a60256808880e4c9013d79c14491ff5a67a2 | |
| parent | 19d0c29e7eda192da4ecb0210fb67d0c84a39415 (diff) | |
| download | python-decorator-git-6e4cb6763624e199cba37053f4a530630204250f.tar.gz | |
Fixed Python 2.6
| -rw-r--r-- | src/decorator.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/decorator.py b/src/decorator.py index 15530f0..858a921 100644 --- a/src/decorator.py +++ b/src/decorator.py @@ -40,7 +40,7 @@ import operator import itertools import collections -__version__ = '4.1.2' +__version__ = '4.2.0' if sys.version >= '3': from inspect import getfullargspec @@ -241,7 +241,7 @@ def decorate(func, caller, extras=()): evaldict[ex] = extra es += ex + ', ' fun = FunctionMaker.create( - func, "return _call_(_func_, {}%(shortsignature)s)".format(es), + func, "return _call_(_func_, %s%%(shortsignature)s)" % es, evaldict, __wrapped__=func) if hasattr(func, '__qualname__'): fun.__qualname__ = func.__qualname__ |
