aboutsummaryrefslogtreecommitdiffstats
path: root/pyGHDL/dom/_Utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyGHDL/dom/_Utils.py')
-rw-r--r--pyGHDL/dom/_Utils.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/pyGHDL/dom/_Utils.py b/pyGHDL/dom/_Utils.py
index 10053db6e..3b647013b 100644
--- a/pyGHDL/dom/_Utils.py
+++ b/pyGHDL/dom/_Utils.py
@@ -64,6 +64,8 @@ def CheckForErrors() -> None:
errors.append(f"{fileName}:{rec.line}:{rec.offset}: {message}")
+ errorout_memory.Clear_Errors()
+
raise DOMException("Error raised in libghdl.") from LibGHDLException("libghdl: Internal error.", errors)