hdl: make all public Value classes other than Record final.
authorwhitequark <whitequark@whitequark.org>
Sun, 12 May 2019 05:36:35 +0000 (05:36 +0000)
committerwhitequark <whitequark@whitequark.org>
Sun, 12 May 2019 05:40:17 +0000 (05:40 +0000)
commit744e33f42df53b2bba75a808226221cc99b35de0
treeae014b1cb3264b72f40560a0e14ccc70e55b8ace
parent958cb18b886ae40d0a28140b40c187d90a692475
hdl: make all public Value classes other than Record final.

In some cases, nMigen uses type() instead of isinstance() to dispatch
on types. Make sure all such uses of type() are robust; in addition,
make it clear that nMigen AST classes are not meant to be subclassed.
(Record is an exception.)

Fixes #65.
nmigen/hdl/ast.py
nmigen/hdl/rec.py
nmigen/tools.py