From: Stefan Behnel Date: Tue, 13 Jan 2009 19:52:40 +0000 (+0100) Subject: simplification X-Git-Tag: 0.11-beta~25 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=04f588b2bdf0379c30dcde76c44bc559e8b1a8fb;p=cython.git simplification --- diff --git a/Cython/Compiler/AutoDocTransforms.py b/Cython/Compiler/AutoDocTransforms.py index 4c26c2ba..dae5926b 100644 --- a/Cython/Compiler/AutoDocTransforms.py +++ b/Cython/Compiler/AutoDocTransforms.py @@ -161,7 +161,7 @@ class EmbedSignature(CythonTransform): if signature: if node.entry.doc is not None: old_doc = node.entry.doc - elif hasattr(node, 'py_func') and node.py_func is not None: + elif getattr(node, 'py_func', None) is not None: old_doc = node.py_func.entry.doc else: old_doc = None