diff options
author | Patrick Lehmann <Patrick.Lehmann@plc2.de> | 2021-06-21 14:34:03 +0200 |
---|---|---|
committer | Patrick Lehmann <Patrick.Lehmann@plc2.de> | 2021-06-22 12:26:59 +0200 |
commit | 5303bb777dedfa03bbc3d042bb14c5d9bbae6b52 (patch) | |
tree | efc8cdd5c4114be2bb5cb69b35b34f6b481e5b81 /pyGHDL/dom/_Translate.py | |
parent | e41f119ea07c83842599fdd4ff1dd8e235eb791e (diff) | |
download | ghdl-5303bb777dedfa03bbc3d042bb14c5d9bbae6b52.tar.gz ghdl-5303bb777dedfa03bbc3d042bb14c5d9bbae6b52.tar.bz2 ghdl-5303bb777dedfa03bbc3d042bb14c5d9bbae6b52.zip |
Renamed 'NodeToName' to 'GetNameOfNode'.
Diffstat (limited to 'pyGHDL/dom/_Translate.py')
-rw-r--r-- | pyGHDL/dom/_Translate.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/pyGHDL/dom/_Translate.py b/pyGHDL/dom/_Translate.py index 2445d0574..119f5816e 100644 --- a/pyGHDL/dom/_Translate.py +++ b/pyGHDL/dom/_Translate.py @@ -38,7 +38,7 @@ from pyVHDLModel.VHDLModel import Constraint, Direction, Expression, SubTypeOrSy from pyGHDL.libghdl import utils from pyGHDL.libghdl.utils import flist_iter from pyGHDL.libghdl.vhdl import nodes -from pyGHDL.dom._Utils import NodeToName, GetIirKindOfNode +from pyGHDL.dom._Utils import GetNameOfNode, GetIirKindOfNode from pyGHDL.dom.Common import DOMException from pyGHDL.dom.Range import Range, RangeExpression from pyGHDL.dom.Symbol import ( @@ -73,12 +73,12 @@ def GetSubtypeIndicationFromNode(node, entity: str, name: str) -> SubTypeOrSymbo subTypeKind = GetIirKindOfNode(subTypeIndication) if subTypeKind == nodes.Iir_Kind.Simple_Name: - subTypeName = NodeToName(subTypeIndication) + subTypeName = GetNameOfNode(subTypeIndication) subType = SimpleSubTypeSymbol(subTypeName) elif subTypeKind == nodes.Iir_Kind.Array_Subtype_Definition: typeMark = nodes.Get_Subtype_Type_Mark(subTypeIndication) - typeMarkName = NodeToName(typeMark) + typeMarkName = GetNameOfNode(typeMark) constraints = GetArrayConstraintsFromSubtypeIndication(subTypeIndication) subType = ConstrainedSubTypeSymbol(typeMarkName, constraints) @@ -247,19 +247,19 @@ def GetDeclaredItemsFromChainedNodes(nodeChain, entity: str, name: str): result.append(Signal.parse(item)) elif kind == nodes.Iir_Kind.Anonymous_Type_Declaration: - typeName = NodeToName(item) + typeName = GetNameOfNode(item) print("found type '{name}'".format(name=typeName)) elif kind == nodes.Iir_Kind.Subtype_Declaration: - subTypeName = NodeToName(item) + subTypeName = GetNameOfNode(item) print("found subtype '{name}'".format(name=subTypeName)) elif kind == nodes.Iir_Kind.Function_Declaration: - functionName = NodeToName(item) + functionName = GetNameOfNode(item) print("found function '{name}'".format(name=functionName)) elif kind == nodes.Iir_Kind.Function_Body: # functionName = NodeToName(item) print("found function body '{name}'".format(name="????")) elif kind == nodes.Iir_Kind.Object_Alias_Declaration: - aliasName = NodeToName(item) + aliasName = GetNameOfNode(item) print("found alias '{name}'".format(name=aliasName)) else: raise DOMException( |