fhdl/verilog: fix signed constant conversion
This commit is contained in:
parent
0a23cadd38
commit
90184b22d2
|
@ -21,7 +21,7 @@ def _printexpr(ns, node):
|
|||
if node.n >= 0:
|
||||
return str(node.bv) + str(node.n)
|
||||
else:
|
||||
return "-" + str(node.bv) + str(-self.n)
|
||||
return "-" + str(node.bv) + str(-node.n)
|
||||
elif isinstance(node, Signal):
|
||||
return ns.get_name(node)
|
||||
elif isinstance(node, _Operator):
|
||||
|
|
Loading…
Reference in New Issue