import TypeSlots
import Symtab
import Options
-from StringEncoding import EncodedString
+from Code import UtilityCode
+from StringEncoding import EncodedString
+from Errors import error
from ParseTreeTransforms import SkipDeclarations
- #def unwrap_node(node):
- # while isinstance(node, ExprNodes.PersistentNode):
- # node = node.arg
- # return node
-
- # Temporary hack while PersistentNode is out of order
+try:
+ reduce
+except NameError:
+ from functools import reduce
+
def unwrap_node(node):
+ while isinstance(node, UtilNodes.ResultRefNode):
+ node = node.expression
return node
def is_common_value(a, b):