Author: Michael Buch Date: 2022-08-17T15:39:21+01:00 New Revision: 33833c861172b48f317743cf3813af3139302052
URL: https://github.com/llvm/llvm-project/commit/33833c861172b48f317743cf3813af3139302052 DIFF: https://github.com/llvm/llvm-project/commit/33833c861172b48f317743cf3813af3139302052.diff LOG: [lldb][Tests] Skip static-only tests in TestConstStaticIntegralMember.py for dsym variant This test fails for Clang versions < 14.0 for `dsym` variants. `dsymutil` strips debug info for classes with only static members. Thus move the failing assertions into the XFAIL test case. Differential Revision: https://reviews.llvm.org/D132004 Added: Modified: lldb/test/API/lang/cpp/const_static_integral_member/TestConstStaticIntegralMember.py Removed: ################################################################################ diff --git a/lldb/test/API/lang/cpp/const_static_integral_member/TestConstStaticIntegralMember.py b/lldb/test/API/lang/cpp/const_static_integral_member/TestConstStaticIntegralMember.py index 594e67bd5156..4f51d22a8685 100644 --- a/lldb/test/API/lang/cpp/const_static_integral_member/TestConstStaticIntegralMember.py +++ b/lldb/test/API/lang/cpp/const_static_integral_member/TestConstStaticIntegralMember.py @@ -67,12 +67,6 @@ def test(self): self.expect_expr("A::scoped_ll_enum_val_neg", result_value="case0") self.expect_expr("A::scoped_ll_enum_val", result_value="case2") - # Test an aliased enum with fixed underlying type. - self.expect_expr("ClassWithEnumAlias::enum_alias", - result_value="scoped_enum_case2") - self.expect_expr("ClassWithEnumAlias::enum_alias_alias", - result_value="scoped_enum_case1") - # Test taking address. if lldbplatformutil.getPlatform() == "windows": # On Windows data members without the out-of-class definitions still have @@ -98,7 +92,20 @@ def test_class_with_only_const_static(self): self.expect_expr("ClassWithOnlyConstStatic::member", result_value="3") + # With older versions of Clang, LLDB fails to evaluate classes with only + # constexpr members when dsymutil is enabled + @expectedFailureAll(debug_info=["dsym"], compiler=["clang"], compiler_version=["<", "14.0"]) + def test_class_with_only_constexpr_static(self): + self.build() + lldbutil.run_to_source_breakpoint(self, "// break here", lldb.SBFileSpec("main.cpp")) + # Test `constexpr static`. self.expect_expr("ClassWithConstexprs::member", result_value="2") self.expect_expr("ClassWithConstexprs::enum_val", result_value="enum_case2") self.expect_expr("ClassWithConstexprs::scoped_enum_val", result_value="scoped_enum_case2") + + # Test an aliased enum with fixed underlying type. + self.expect_expr("ClassWithEnumAlias::enum_alias", + result_value="scoped_enum_case2") + self.expect_expr("ClassWithEnumAlias::enum_alias_alias", + result_value="scoped_enum_case1") _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits