summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/python_api/sbdata/TestSBData.py
diff options
context:
space:
mode:
authorJonas Devlieghere <jonas@devlieghere.com>2018-05-30 13:03:16 +0000
committerJonas Devlieghere <jonas@devlieghere.com>2018-05-30 13:03:16 +0000
commitdf8e291ef94744780f813e244860326b5e628b18 (patch)
tree912a326e8bb6566c58015eef0977f6a19d182333 /lldb/packages/Python/lldbsuite/test/python_api/sbdata/TestSBData.py
parentd8d5628834c7cda4a506a3c33105c8725b9b1762 (diff)
downloadbcm5719-llvm-df8e291ef94744780f813e244860326b5e628b18.tar.gz
bcm5719-llvm-df8e291ef94744780f813e244860326b5e628b18.zip
[FileSpec] Re-implmenet removeLastPathComponent
When reading DBGSourcePathRemapping from a dSYM, we remove the last two path components to make the source lookup more general. However, when dealing with a relative path that has less than 2 components, we ended up with an invalid (empty) FileSpec. This patch changes the behavior of removeLastPathComponent to remove the last path component, if possible. It does this by checking whether a parent path exists, and if so using that as the new path. We rely entirely on LLVM's path implementation to do the heavy lifting. We now also return a boolean which indicates whether the operator was successful or not. Differential revision: https://reviews.llvm.org/D47495 rdar://37791687 llvm-svn: 333540
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/python_api/sbdata/TestSBData.py')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud