This is required for applying constraints to clocks in anonymous
subfragments in build.plat.
class _Namer:
def __init__(self):
super().__init__()
+ self._anon = 0
self._index = 0
self._names = set()
+ def anonymous(self):
+ name = "U$${}".format(self._anon)
+ assert name not in self._names
+ self._anon += 1
+ return name
+
def _make_name(self, name, local):
if name is None:
self._index += 1
if not subfragment.ports:
continue
+ if sub_name is None:
+ sub_name = module.anonymous()
+
sub_params = OrderedDict()
if hasattr(subfragment, "parameters"):
for param_name, param_value in subfragment.parameters.items():