From: Luke Kenneth Casson Leighton Date: Fri, 17 Jan 2020 14:18:34 +0000 (+0000) Subject: min/max in Signal deprecated in nmigen X-Git-Tag: ls180-24jan2020~352 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0705c100aa16bc1ef6eca8f6acd38037120427ad;p=ieee754fpu.git min/max in Signal deprecated in nmigen --- diff --git a/src/ieee754/div_rem_sqrt_rsqrt/core.py b/src/ieee754/div_rem_sqrt_rsqrt/core.py index cef62a34..fea59dce 100644 --- a/src/ieee754/div_rem_sqrt_rsqrt/core.py +++ b/src/ieee754/div_rem_sqrt_rsqrt/core.py @@ -70,8 +70,7 @@ class DivPipeCoreOperation(enum.Enum): @classmethod def create_signal(cls, *, src_loc_at=0, **kwargs): """ Create a signal that can contain a ``DivPipeCoreOperation``. """ - return Signal(min=min(map(int, cls)), - max=max(map(int, cls)) + 2, + return Signal(range(min(map(int, cls)), max(map(int, cls)) + 2), src_loc_at=(src_loc_at + 1), decoder=lambda v: str(cls(v)), **kwargs)