Commit eb40e5d1 authored by Stefan Behnel's avatar Stefan Behnel

Let TempResultFromStatNode know when its result cannot be None.

parent 477c152e
......@@ -354,6 +354,9 @@ class TempResultFromStatNode(ExprNodes.ExprNode):
self.body = self.body.analyse_expressions(env)
return self
def may_be_none(self):
return self.result_ref.may_be_none()
def generate_result_code(self, code):
self.result_ref.result_code = self.result()
self.body.generate_execution_code(code)
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