diff --git a/amaranth/lib/io.py b/amaranth/lib/io.py index b0fb305..c703213 100644 --- a/amaranth/lib/io.py +++ b/amaranth/lib/io.py @@ -12,8 +12,8 @@ def pin_layout(width, dir, xdr=0): See :class:`Pin` for details. """ - if not isinstance(width, int) or width < 1: - raise TypeError("Width must be a positive integer, not {!r}" + if not isinstance(width, int) or width < 0: + raise TypeError("Width must be a non-negative integer, not {!r}" .format(width)) if dir not in ("i", "o", "oe", "io"): raise TypeError("Direction must be one of \"i\", \"o\", \"io\", or \"oe\", not {!r}"""