From: Dag Sverre Seljebotn Date: Thu, 18 Sep 2008 09:43:41 +0000 (+0200) Subject: Better error for casts (#48) X-Git-Tag: 0.9.9.2.beta~95^2~4 X-Git-Url: http://git.tremily.us/gitweb.cgi?a=commitdiff_plain;h=be443f0bc607c7bb21c07747a27bc1218df56da9;p=cython.git Better error for casts (#48) --- diff --git a/Cython/Compiler/Parsing.py b/Cython/Compiler/Parsing.py index 396c4d6e..415c29b9 100644 --- a/Cython/Compiler/Parsing.py +++ b/Cython/Compiler/Parsing.py @@ -229,6 +229,8 @@ def p_typecast(s): pos = s.position() s.next() base_type = p_c_base_type(s) + if base_type.name is None: + s.error("Unknown type") declarator = p_c_declarator(s, empty = 1) if s.sy == '?': s.next()