From: Dag Sverre Seljebotn Date: Sat, 20 Feb 2010 12:36:10 +0000 (+0100) Subject: Fix #508 X-Git-Tag: 0.13.beta0~334^2~1 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=da14f38be849274da7009ea35e72fd38c0acf16d;p=cython.git Fix #508 --- diff --git a/Cython/Compiler/AnalysedTreeTransforms.py b/Cython/Compiler/AnalysedTreeTransforms.py index 300aebbc..4ce100f7 100644 --- a/Cython/Compiler/AnalysedTreeTransforms.py +++ b/Cython/Compiler/AnalysedTreeTransforms.py @@ -13,6 +13,8 @@ class AutoTestDictTransform(ScopeTrackingTransform): blacklist = ['__cinit__', '__dealloc__', '__richcmp__', '__nonzero__'] def visit_ModuleNode(self, node): + if node.is_pxd: + return node self.scope_type = 'module' self.scope_node = node if self.current_directives['autotestdict']: diff --git a/tests/run/autotestdict.pxd b/tests/run/autotestdict.pxd new file mode 100644 index 00000000..2c4ada8b --- /dev/null +++ b/tests/run/autotestdict.pxd @@ -0,0 +1 @@ +# I just exist