Author: Dave Lee Date: 2022-11-21T12:45:27-08:00 New Revision: b3f15ccf54cf8094507137d145b38313aa785d61
URL: https://github.com/llvm/llvm-project/commit/b3f15ccf54cf8094507137d145b38313aa785d61 DIFF: https://github.com/llvm/llvm-project/commit/b3f15ccf54cf8094507137d145b38313aa785d61.diff LOG: Reland "[lldb] Fix SBFileSpec.fullpath" Update `fullpath` asserts in TestMiniDump.py. This reverts commit 682fcc95f4149f00e9da961817fe2f5832e4b301. Added: Modified: lldb/bindings/interface/SBFileSpec.i lldb/test/API/functionalities/postmortem/minidump/TestMiniDump.py Removed: ################################################################################ diff --git a/lldb/bindings/interface/SBFileSpec.i b/lldb/bindings/interface/SBFileSpec.i index b549321487ec2..e6f9bb81e2402 100644 --- a/lldb/bindings/interface/SBFileSpec.i +++ b/lldb/bindings/interface/SBFileSpec.i @@ -84,18 +84,7 @@ public: #ifdef SWIGPYTHON %pythoncode %{ - def __get_fullpath__(self): - spec_dir = self.GetDirectory() - spec_file = self.GetFilename() - if spec_dir and spec_file: - return '%s/%s' % (spec_dir, spec_file) - elif spec_dir: - return spec_dir - elif spec_file: - return spec_file - return None - - fullpath = property(__get_fullpath__, None, doc='''A read only property that returns the fullpath as a python string.''') + fullpath = property(str, None, doc='''A read only property that returns the fullpath as a python string.''') basename = property(GetFilename, None, doc='''A read only property that returns the path basename as a python string.''') dirname = property(GetDirectory, None, doc='''A read only property that returns the path directory name as a python string.''') exists = property(Exists, None, doc='''A read only property that returns a boolean value that indicates if the file exists.''') diff --git a/lldb/test/API/functionalities/postmortem/minidump/TestMiniDump.py b/lldb/test/API/functionalities/postmortem/minidump/TestMiniDump.py index e36f1af89e9ca..777548c39253d 100644 --- a/lldb/test/API/functionalities/postmortem/minidump/TestMiniDump.py +++ b/lldb/test/API/functionalities/postmortem/minidump/TestMiniDump.py @@ -44,27 +44,27 @@ def test_modules_in_mini_dump(self): self.assertTrue(self.process, PROCESS_IS_VALID) expected_modules = [ { - 'filename' : r"C:\Users\amccarth\Documents\Visual Studio 2013\Projects\fizzbuzz\Debug/fizzbuzz.exe", + 'filename' : r"C:\Users\amccarth\Documents\Visual Studio 2013\Projects\fizzbuzz\Debug\fizzbuzz.exe", 'uuid' : '0F45B791-9A96-46F9-BF8F-2D6076EA421A-00000011', }, { - 'filename' : r"C:\Windows\SysWOW64/ntdll.dll", + 'filename' : r"C:\Windows\SysWOW64\ntdll.dll", 'uuid' : 'BBB0846A-402C-4052-A16B-67650BBFE6B0-00000002', }, { - 'filename' : r"C:\Windows\SysWOW64/kernel32.dll", + 'filename' : r"C:\Windows\SysWOW64\kernel32.dll", 'uuid' : 'E5CB7E1B-005E-4113-AB98-98D6913B52D8-00000002', }, { - 'filename' : r"C:\Windows\SysWOW64/KERNELBASE.dll", + 'filename' : r"C:\Windows\SysWOW64\KERNELBASE.dll", 'uuid' : '0BF95241-CB0D-4BD4-AC5D-186A6452E522-00000001', }, { - 'filename' : r"C:\Windows\System32/MSVCP120D.dll", + 'filename' : r"C:\Windows\System32\MSVCP120D.dll", 'uuid' : '3C05516E-57E7-40EB-8D3F-9722C5BD80DD-00000001', }, { - 'filename' : r"C:\Windows\System32/MSVCR120D.dll", + 'filename' : r"C:\Windows\System32\MSVCR120D.dll", 'uuid' : '6382FB86-46C4-4046-AE42-8D97B3F91FF2-00000001', }, ] _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits