From: Luke Kenneth Casson Leighton Date: Tue, 5 Oct 2021 17:19:51 +0000 (+0100) Subject: comment clarification, add missing default value "stride=1" to Value.__Part__ X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6e7329d5cc593e05dfcb1f770a9cd878226a44ce;p=nmigen.git comment clarification, add missing default value "stride=1" to Value.__Part__ --- diff --git a/nmigen/hdl/ast.py b/nmigen/hdl/ast.py index ef4a5df..3721482 100644 --- a/nmigen/hdl/ast.py +++ b/nmigen/hdl/ast.py @@ -155,10 +155,12 @@ class Value(metaclass=ABCMeta): # These are redirection of "Type (1) - AST " nmigen language constructs # If over-ridden to provide advanced behaviour, the implementation # *MUST NOT* use "Type (2) - dsl.Module" nmigen language constructs - # (m.If, m.Else, m.Switch, m.FSM): it creates complications in dsl.Module. + # (m.If, m.Else, m.Switch, m.FSM): it creates complications + # (recursive dependencies) in dsl.Module. - def __Part__(self, offset, width, stride, *, src_loc_at=0): - return _InternalPart(self, offset, width, stride, src_loc_at=src_loc_at) + def __Part__(self, offset, width, stride=1, *, src_loc_at=0): + return _InternalPart(self, offset, width, stride, + src_loc_at=src_loc_at) def __Repl__(self, count, *, src_loc_at=0): return _InternalRepl(self, count, src_loc_at=src_loc_at) def __Cat__(self, *args, src_loc_at=0):