[Lldb-commits] [lldb] d1e9893 - [LLDB] Run MSVC STL vector tests with PDB (#172726)
via lldb-commits
lldb-commits at lists.llvm.org
Thu Dec 18 04:18:58 PST 2025
Author: nerix
Date: 2025-12-18T13:18:53+01:00
New Revision: d1e98939c890d8ff7e292ab31a3d206ff6429a13
URL: https://github.com/llvm/llvm-project/commit/d1e98939c890d8ff7e292ab31a3d206ff6429a13
DIFF: https://github.com/llvm/llvm-project/commit/d1e98939c890d8ff7e292ab31a3d206ff6429a13.diff
LOG: [LLDB] Run MSVC STL vector tests with PDB (#172726)
Added:
Modified:
lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/vector/TestDataFormatterStdVector.py
Removed:
################################################################################
diff --git a/lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/vector/TestDataFormatterStdVector.py b/lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/vector/TestDataFormatterStdVector.py
index d4da60f86a315..af857d51b3d24 100644
--- a/lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/vector/TestDataFormatterStdVector.py
+++ b/lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/vector/TestDataFormatterStdVector.py
@@ -9,6 +9,8 @@
class StdVectorDataFormatterTestCase(TestBase):
+ TEST_WITH_PDB_DEBUG_INFO = True
+
def check_numbers(self, var_name, show_ptr=False):
patterns = []
substrs = [
@@ -107,18 +109,23 @@ def cleanup():
)
# check access to synthetic children
+ int_vect = (
+ "std::vector<int, std::allocator<int>>"
+ if self.getDebugInfo() == "pdb"
+ else "int_vect"
+ )
self.runCmd(
- 'type summary add --summary-string "item 0 is ${var[0]}" std::int_vect int_vect'
+ f'type summary add --summary-string "item 0 is ${{var[0]}}" std::int_vect "{int_vect}"'
)
self.expect("frame variable numbers", substrs=["item 0 is 1"])
self.runCmd(
- 'type summary add --summary-string "item 0 is ${svar[0]}" std::int_vect int_vect'
+ f'type summary add --summary-string "item 0 is ${{svar[0]}}" "std::int_vect" "{int_vect}"'
)
self.expect("frame variable numbers", substrs=["item 0 is 1"])
# move on with synths
self.runCmd("type summary delete std::int_vect")
- self.runCmd("type summary delete int_vect")
+ self.runCmd(f'type summary delete "{int_vect}"')
# add some more data
lldbutil.continue_to_breakpoint(process, bkpt)
@@ -143,8 +150,13 @@ def cleanup():
self.expect("expression strings", substrs=["goofy", "is", "smart"])
# test summaries based on synthetic children
+ string_vect = (
+ "std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char>>>>"
+ if self.getDebugInfo() == "pdb"
+ else "string_vect"
+ )
self.runCmd(
- 'type summary add std::string_vect string_vect --summary-string "vector has ${svar%#} items" -e'
+ f'type summary add std::string_vect "{string_vect}" --summary-string "vector has ${{svar%#}} items" -e'
)
self.expect(
"frame variable strings",
More information about the lldb-commits
mailing list