modify-python-lldb.py: Insert initialization code with swig instead

This is the last functional change to the generated python module being
done by modify-python-lldb.py. The remaining code just deals with
reformatting of comments.

llvm-svn: 357755
This commit is contained in:
Pavel Labath 2019-04-05 09:56:55 +00:00
parent ebdc698dbc
commit 78a514bf9d
2 changed files with 10 additions and 7 deletions

View file

@ -166,10 +166,3 @@ new_content.finish()
with open(output_name, 'w') as f_out:
f_out.write(new_content.getvalue())
f_out.write('''debugger_unique_id = 0
SBDebugger.Initialize()
debugger = None
target = SBTarget()
process = SBProcess()
thread = SBThread()
frame = SBFrame()''')

View file

@ -260,3 +260,13 @@ def lldb_iter(obj, getsize, getelem):
%include "./Python/python-extensions.swig"
%include "./Python/python-wrapper.swig"
%pythoncode%{
debugger_unique_id = 0
SBDebugger.Initialize()
debugger = None
target = SBTarget()
process = SBProcess()
thread = SBThread()
frame = SBFrame()
%}