Commit f78e64cb authored by Dag Sverre Seljebotn's avatar Dag Sverre Seljebotn

Debug flag to not intercept pipeline exceptions

parent 35a90d1c
...@@ -8,3 +8,6 @@ debug_temp_code_comments = 0 ...@@ -8,3 +8,6 @@ debug_temp_code_comments = 0
# Write a call trace of the code generation phase into the C code # Write a call trace of the code generation phase into the C code
debug_trace_code_generation = 0 debug_trace_code_generation = 0
# Do not replace exceptions with user-friendly error messages
debug_no_exception_intercept = 0
...@@ -7,6 +7,7 @@ import Nodes ...@@ -7,6 +7,7 @@ import Nodes
import ExprNodes import ExprNodes
import Naming import Naming
import Errors import Errors
import DebugFlags
from StringEncoding import EncodedString from StringEncoding import EncodedString
class BasicVisitor(object): class BasicVisitor(object):
...@@ -151,6 +152,8 @@ class TreeVisitor(BasicVisitor): ...@@ -151,6 +152,8 @@ class TreeVisitor(BasicVisitor):
raise raise
except Exception, e: except Exception, e:
import sys import sys
if DebugFlags.debug_no_exception_intercept:
raise
trace = [''] trace = ['']
for parent, attribute, index in self.access_path: for parent, attribute, index in self.access_path:
node = getattr(parent, attribute) node = getattr(parent, attribute)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment