diff options
author | Patrick Lehmann <Patrick.Lehmann@plc2.de> | 2021-06-22 19:20:16 +0200 |
---|---|---|
committer | Patrick Lehmann <Patrick.Lehmann@plc2.de> | 2021-06-22 19:24:01 +0200 |
commit | ea328fa671fc42569a688c8dfb308d87f42771c3 (patch) | |
tree | 7c7e53389378fd84414bc3d91d178f636d6498e6 /pyGHDL/cli | |
parent | 469a8d28a1efae99ea1dc1e3f3c84c4889ba2421 (diff) | |
download | ghdl-ea328fa671fc42569a688c8dfb308d87f42771c3.tar.gz ghdl-ea328fa671fc42569a688c8dfb308d87f42771c3.tar.bz2 ghdl-ea328fa671fc42569a688c8dfb308d87f42771c3.zip |
Prepared for DeferredConstant.
Diffstat (limited to 'pyGHDL/cli')
-rwxr-xr-x | pyGHDL/cli/DOM.py | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/pyGHDL/cli/DOM.py b/pyGHDL/cli/DOM.py index 2feb6aecd..641383686 100755 --- a/pyGHDL/cli/DOM.py +++ b/pyGHDL/cli/DOM.py @@ -9,8 +9,8 @@ from pydecor import export from pyGHDL import GHDLBaseException from pyGHDL.libghdl import LibGHDLException -from pyGHDL.dom import NonStandard from pyGHDL.dom.Common import DOMException +from pyGHDL.dom.NonStandard import Design, Document, Library from pyGHDL.dom.formatting.prettyprint import PrettyPrint, PrettyPrintException __all__ = [] @@ -19,14 +19,16 @@ __api__ = __all__ @export class Application: - _design: NonStandard.Design + _design: Design def __init__(self): - self._design = NonStandard.Design() + self._design = Design() def addFile(self, filename: Path, library: str): - document = NonStandard.Document(filename) - self._design.Documents.append(document) + lib = self._design.GetLibrary(library) + + document = Document(filename) + self._design.AddDocument(document, lib) def prettyPrint(self): PP = PrettyPrint() |