
It turns out that while Python does not import _private identifiers when using * imports, it does nevertheless import all submodules. Avoid polluting the namespace in the prelude by explicitly listing all exported identifiers.
22 lines
526 B
Python
22 lines
526 B
Python
import pkg_resources
|
|
try:
|
|
__version__ = pkg_resources.get_distribution(__name__).version
|
|
except pkg_resources.DistributionNotFound:
|
|
pass
|
|
|
|
|
|
from .hdl import *
|
|
|
|
|
|
__all__ = [
|
|
"Shape", "unsigned", "signed",
|
|
"Value", "Const", "C", "Mux", "Cat", "Repl", "Array", "Signal", "ClockSignal", "ResetSignal",
|
|
"Module",
|
|
"ClockDomain",
|
|
"Elaboratable", "Fragment", "Instance",
|
|
"Memory",
|
|
"Record",
|
|
"DomainRenamer", "ResetInserter", "EnableInserter",
|
|
"CEInserter", # TODO(nmigen-0.2): remove this
|
|
]
|