aboutsummaryrefslogtreecommitdiffstats
path: root/pyGHDL/dom/Sequential.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyGHDL/dom/Sequential.py')
-rw-r--r--pyGHDL/dom/Sequential.py18
1 files changed, 3 insertions, 15 deletions
diff --git a/pyGHDL/dom/Sequential.py b/pyGHDL/dom/Sequential.py
index 35f7b0d4f..3e9ebaf48 100644
--- a/pyGHDL/dom/Sequential.py
+++ b/pyGHDL/dom/Sequential.py
@@ -291,11 +291,7 @@ class CaseStatement(VHDLModel_CaseStatement, DOMMixin):
rng = GetNameFromNode(choiceRange)
else:
pos = Position.parse(alternative)
- raise DOMException(
- "Unknown choice range kind '{kind}' in case statement at line {line}.".format(
- kind=choiceRangeKind.name, line=pos.Line
- )
- )
+ raise DOMException(f"Unknown choice range kind '{choiceRangeKind.name}' in case statement at line {pos.Line}.")
choice = RangedChoice(alternative, rng)
if sameAlternative:
@@ -312,11 +308,7 @@ class CaseStatement(VHDLModel_CaseStatement, DOMMixin):
continue
else:
pos = Position.parse(alternative)
- raise DOMException(
- "Unknown choice kind '{kind}' in case statement at line {line}.".format(
- kind=choiceKind.name, line=pos.Line
- )
- )
+ raise DOMException(f"Unknown choice kind '{choiceKind.name}' in case statement at line {pos.Line}.")
if choices is not None:
cases.append(Case.parse(cNode, choices, label))
@@ -370,11 +362,7 @@ class ForLoopStatement(VHDLModel_ForLoopStatement, DOMMixin):
rng = GetNameFromNode(discreteRange)
else:
pos = Position.parse(loopNode)
- raise DOMException(
- "Unknown discete range kind '{kind}' in for...loop statement at line {line}.".format(
- kind=rangeKind.name, line=pos.Line
- )
- )
+ raise DOMException(f"Unknown discete range kind '{rangeKind.name}' in for...loop statement at line {pos.Line}.")
statementChain = nodes.Get_Sequential_Statement_Chain(loopNode)
statements = GetSequentialStatementsFromChainedNodes(statementChain, "for", label)