From: whitequark Date: Wed, 12 Dec 2018 10:08:56 +0000 (+0000) Subject: fhdl.ast.Signal: assign an internal name if tracer fails. X-Git-Tag: working~341 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1d46ffb591f0ca43a76b8ff0fafb61bf67a7490b;p=nmigen.git fhdl.ast.Signal: assign an internal name if tracer fails. --- diff --git a/nmigen/fhdl/ast.py b/nmigen/fhdl/ast.py index 198b5c4..b78021f 100644 --- a/nmigen/fhdl/ast.py +++ b/nmigen/fhdl/ast.py @@ -505,7 +505,10 @@ class Signal(Value, DUID): super().__init__() if name is None: - name = tracer.get_var_name() + try: + name = tracer.get_var_name() + except tracer.NameNotFound: + name = "$signal" self.name = name if isinstance(bits_sign, int):