compat.fhdl.bitcontainer: fix value_bits_sign().

This function was broken in commit 659b0e81; some downstream code
expects bits_sign to be e.g. indexable.
This commit is contained in:
whitequark 2020-07-21 02:53:29 +00:00
parent 5ccc2122ce
commit 0899ff366b

View file

@ -18,4 +18,4 @@ def bits_for(n, require_sign_bit=False):
@deprecated("instead of `value_bits_sign(v)`, use `v.shape()`") @deprecated("instead of `value_bits_sign(v)`, use `v.shape()`")
def value_bits_sign(v): def value_bits_sign(v):
return ast.Value.cast(v).shape() return tuple(ast.Value.cast(v).shape())