[Lldb-commits] [PATCH] D68737: SBFile::GetFile: convert SBFile back into python native files.

Lawrence D'Anna via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Oct 9 15:04:37 PDT 2019


lawrence_danna created this revision.
lawrence_danna added reviewers: JDevlieghere, jasonmolenda, labath.
Herald added a project: LLDB.

This makes SBFile::GetFile public and adds a SWIG typemap to convert
the result back into a python native file.

If the underlying File itself came from a python file, it is returned
identically.   Otherwise a new python file object is created using
the file descriptor.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D68737

Files:
  lldb/include/lldb/API/SBFile.h
  lldb/include/lldb/Host/File.h
  lldb/packages/Python/lldbsuite/test/python_api/file_handle/TestFileHandle.py
  lldb/scripts/Python/python-typemaps.swig
  lldb/scripts/interface/SBFile.i
  lldb/source/API/SBFile.cpp
  lldb/source/Host/common/File.cpp
  lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp
  lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D68737.224182.patch
Type: text/x-patch
Size: 9237 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20191009/2fa5601e/attachment.bin>


More information about the lldb-commits mailing list