if modsplitpt == -1: bad_usage()
modulename = fqn[:modsplitpt]
symbolname = fqn[modsplitpt+1:]
- module = __import__(modulename, fromlist=[symbolname], level=0)
+ module = __import__(modulename, globals(), locals(), [symbolname])
return getattr(module, symbolname)
stagename, factoryname = param.split(":")
class TransformSet(dict):
def __init__(self):
- self.update([(name, []) for name in PHASES])
+ for name in PHASES:
+ self[name] = []
def run(self, name, node, **options):
assert name in self
for transform in self[name]: