hdl.dsl: warn on suspicious statements like `m.If(~True):`.
authorwhitequark <whitequark@whitequark.org>
Sat, 3 Aug 2019 14:00:29 +0000 (14:00 +0000)
committerwhitequark <whitequark@whitequark.org>
Sat, 3 Aug 2019 14:00:29 +0000 (14:00 +0000)
commitace2b5ff0a0bc27bb36ba89f9a0f5ebc4202cb39
tree92a58049a62de4e11c13bf9749fe8b2105a13783
parentab5426ce748ac2ddcc0202ca757383cb829b15e4
hdl.dsl: warn on suspicious statements like `m.If(~True):`.

This pattern usually produces an extremely hard to notice bug that
will usually break a design when it is triggered, but will also be
hidden unless the pathological value of a boolean switch is used.

Fixes #159.
nmigen/hdl/dsl.py
nmigen/test/test_hdl_dsl.py