Skip to content

Commit

Permalink
fix(HBitsConst): rm deprecated __int__, __bool__
Browse files Browse the repository at this point in the history
  • Loading branch information
Nic30 committed Nov 23, 2024
1 parent 2ecce39 commit 1f0e64a
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions hwt/hdl/types/bitsConst.py
Original file line number Diff line number Diff line change
Expand Up @@ -282,18 +282,6 @@ def getMsb(self) -> Self:
def __len__(self) -> int:
return self._dtype.bit_length()

def __int__(self) -> int:
if self._is_full_valid():
return int(self.val)
else:
raise ValueError(f"Constant is not fully defined", self)

def __bool__(self) -> bool:
if self._is_full_valid():
return bool(self.val)
else:
raise ValueError(f"Constant is not fully defined", self)

def prettyRepr(self) -> str:
t = self._dtype
bs = bit_string(self.val, t.bit_length(), self.vld_mask)
Expand Down

0 comments on commit 1f0e64a

Please # to comment.