summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichele Simionato <michele.simionato@gmail.com>2015-12-09 09:10:42 +0100
committerMichele Simionato <michele.simionato@gmail.com>2015-12-09 09:10:42 +0100
commit1ed48fd60939e752c5a7ffb2b1b17744d73239ee (patch)
tree42131b0724d0549601edf54f6aad16ca727d9949 /src
parentf22e94ae1bcf816328c2ee9b5e41a32276e32b30 (diff)
downloadpython-decorator-git-1ed48fd60939e752c5a7ffb2b1b17744d73239ee.tar.gz
Some cleanup
Diffstat (limited to 'src')
-rw-r--r--src/decorator.py3
1 files changed, 0 insertions, 3 deletions
diff --git a/src/decorator.py b/src/decorator.py
index a8c22e7..4e2bb7a 100644
--- a/src/decorator.py
+++ b/src/decorator.py
@@ -242,7 +242,6 @@ def decorator(caller, _func=None):
# else return a decorator function
if inspect.isclass(caller):
name = caller.__name__.lower()
- callerfunc = get_init(caller)
doc = 'decorator(%s) converts functions/generators into ' \
'factories of %s objects' % (caller.__name__, caller.__name__)
elif inspect.isfunction(caller):
@@ -250,11 +249,9 @@ def decorator(caller, _func=None):
name = '_lambda_'
else:
name = caller.__name__
- callerfunc = caller
doc = caller.__doc__
else: # assume caller is an object with a __call__ method
name = caller.__class__.__name__.lower()
- callerfunc = caller.__call__.__func__
doc = caller.__call__.__doc__
evaldict = dict(_call_=caller, _decorate_=decorate)
return FunctionMaker.create(