Commit bdde3d8a authored by Robert Bradshaw's avatar Robert Bradshaw

Remove function pointer casting restriction

parent c92c9742
......@@ -2600,10 +2600,6 @@ class TypecastNode(ExprNode):
def analyse_types(self, env):
base_type = self.base_type.analyse(env)
_, self.type = self.declarator.analyse(base_type, env)
if self.type.is_cfunction:
error(self.pos,
"Cannot cast to a function type")
self.type = PyrexTypes.error_type
self.operand.analyse_types(env)
to_py = self.type.is_pyobject
from_py = self.operand.type.is_pyobject
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment