Hi, the following very short Cython code crashes the Cython compiler (v0.15.1):
---8<--- cdef extern from "foo.h": cdef cppclass foo: pass foo() ---8<--- The stack trace is attached. Best regards Simon
Traceback (most recent call last): File "/home/anders/tmp/Cython-0.15.1/cython.py", line 17, in <module> main(command_line = 1) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Main.py", line 662, in main result = compile(sources, options) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Main.py", line 637, in compile return compile_multiple(source, options) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Main.py", line 609, in compile_multiple result = run_pipeline(source, options) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Main.py", line 473, in run_pipeline err, enddata = Pipeline.run_pipeline(pipeline, source) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Pipeline.py", line 278, in run_pipeline data = phase(data) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Visitor.py", line 272, in __call__ return super(CythonTransform, self).__call__(node) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Visitor.py", line 255, in __call__ return self._visit(root) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Visitor.py", line 163, in _visit return handler_method(obj) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/ParseTreeTransforms.py", line 1614, in visit_ModuleNode node.body.analyse_expressions(node.scope) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Nodes.py", line 337, in analyse_expressions stat.analyse_expressions(env) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/Nodes.py", line 3630, in analyse_expressions self.expr.analyse_expressions(env) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/ExprNodes.py", line 326, in analyse_expressions self.analyse_types(env) File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/ExprNodes.py", line 3039, in analyse_types if self.analyse_as_type_constructor(env): File "/home/anders/tmp/Cython-0.15.1/Cython/Compiler/ExprNodes.py", line 2948, in analyse_as_type_constructor self.function = RawCNameExprNode(self.function.pos, constructor.type) AttributeError: 'NoneType' object has no attribute 'type'
_______________________________________________ cython-devel mailing list cython-devel@python.org http://mail.python.org/mailman/listinfo/cython-devel