Commit bdb6df8f authored by Stefan Behnel's avatar Stefan Behnel

C type casts are 'simple'

parent 1c157dc1
......@@ -5388,6 +5388,10 @@ class TypecastNode(ExprNode):
elif self.type.is_complex and self.operand.type.is_complex:
self.operand = self.operand.coerce_to_simple(env)
def is_simple(self):
# either temp or a C cast => no side effects
return True
def nogil_check(self, env):
if self.type and self.type.is_pyobject and self.is_temp:
self.gil_error()
......
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