You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[lldb][test] Fix libstdc++ std::variant formatter tests for valueless variants (#147283)
A default-constructed variant has a valid index (being the first element
of the variant). The only case where the index is variant_npos is when
the variant is "valueless", which [according to
cppreference](https://en.cppreference.com/w/cpp/utility/variant/valueless_by_exception.html)
only happens when an exception is thrown during assignment to the
variant.
I adjusted the test to test that scenario, and the formatter seems to
work.
Unblocks #147253
Copy file name to clipboardExpand all lines: lldb/test/API/functionalities/data-formatter/data-formatter-stl/libstdcpp/variant/TestDataFormatterLibStdcxxVariant.py
+3-8Lines changed: 3 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,6 @@
2
2
Test lldb data formatter for LibStdC++ std::variant.
0 commit comments