mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
fhdl: support negation operator
This commit is contained in:
parent
bf021efa2b
commit
84eb964adc
1 changed files with 3 additions and 0 deletions
|
@ -19,6 +19,9 @@ class BV:
|
|||
return r
|
||||
|
||||
class Value:
|
||||
def __invert__(self):
|
||||
return Operator("~", [self])
|
||||
|
||||
def __add__(self, other):
|
||||
return Operator("+", [self, other])
|
||||
def __radd__(self, other):
|
||||
|
|
Loading…
Reference in a new issue