Commit 8b558d1a authored by Mark Florisson's avatar Mark Florisson

Fixed writing debug information with the --cplus flag

parent 08643650
...@@ -185,7 +185,7 @@ class Context(object): ...@@ -185,7 +185,7 @@ class Context(object):
from ParseTreeTransforms import DebugTransform from ParseTreeTransforms import DebugTransform
self.debug_outputwriter = DebugWriter.CythonDebugWriter( self.debug_outputwriter = DebugWriter.CythonDebugWriter(
options.output_dir) options.output_dir)
debug_transform = [DebugTransform(self, options)] debug_transform = [DebugTransform(self, options, result)]
else: else:
debug_transform = [] debug_transform = []
......
...@@ -1474,13 +1474,14 @@ class DebugTransform(CythonTransform): ...@@ -1474,13 +1474,14 @@ class DebugTransform(CythonTransform):
to enable debugging. to enable debugging.
""" """
def __init__(self, context, options): def __init__(self, context, options, result):
super(DebugTransform, self).__init__(context) super(DebugTransform, self).__init__(context)
self.visited = set() self.visited = set()
# our treebuilder and debug output writer # our treebuilder and debug output writer
# (see Cython.Debugger.debug_output.CythonDebugWriter) # (see Cython.Debugger.debug_output.CythonDebugWriter)
self.tb = self.context.debug_outputwriter self.tb = self.context.debug_outputwriter
self.c_output_file = options.output_file #self.c_output_file = options.output_file
self.c_output_file = result.c_file
# tells visit_NameNode whether it should register step-into functions # tells visit_NameNode whether it should register step-into functions
self.register_stepinto = False self.register_stepinto = False
......
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