[lldb] Skip TestPointerToMemberTypeDependingOnParentSize on Windows and GCC

The test added in D100977 is failing to compile on these platforms. This seems
to be caused by GCC, MSVC and Clang@Windows rejecting the code because
`ToLayout` isn't complete when pointer_to_member_member is declared (even though
that seems to be valid code).

This also reverts the test changes in the lazy-loading test from D100977 as
that failed for the same reason.
This commit is contained in:
Raphael Isemann 2021-04-26 18:52:07 +02:00
parent 494e77138c
commit a0c735e29a
3 changed files with 6 additions and 6 deletions

View File

@ -41,7 +41,6 @@ class TestCase(TestBase):
class_we_enter_decl = [class_decl_kind, "ClassWeEnter"]
class_member_decl = [struct_decl_kind, "ClassMember"]
class_static_member_decl = [struct_decl_kind, "StaticClassMember"]
class_pointer_to_member_decl = [struct_decl_kind, "PointerToMember"]
unused_class_member_decl = [struct_decl_kind, "UnusedClassMember"]
unused_class_member_ptr_decl = [struct_decl_kind, "UnusedClassMemberPtr"]
@ -59,7 +58,6 @@ class TestCase(TestBase):
self.assert_decl_not_loaded(self.class_in_namespace_decl)
self.assert_decl_not_loaded(self.class_member_decl)
self.assert_decl_not_loaded(self.class_static_member_decl)
self.assert_decl_not_loaded(self.class_pointer_to_member_decl)
self.assert_decl_not_loaded(self.unused_class_member_decl)
def get_ast_dump(self):
@ -234,8 +232,6 @@ class TestCase(TestBase):
self.assert_decl_loaded(self.class_member_decl)
# We didn't load the type of the unused static member.
self.assert_decl_not_completed(self.class_static_member_decl)
# We didn't load the type of the unused pointer-to-member member.
self.assert_decl_not_completed(self.class_pointer_to_member_decl)
# This should not have loaded anything else.
self.assert_decl_not_loaded(self.other_struct_decl)

View File

@ -26,7 +26,6 @@ struct ClassMember { int i; };
struct StaticClassMember { int i; };
struct UnusedClassMember { int i; };
struct UnusedClassMemberPtr { int i; };
struct PointerToMember { int i; };
namespace NS {
class ClassInNamespace {
@ -37,7 +36,6 @@ public:
int dummy; // Prevent bug where LLDB always completes first member.
ClassMember member;
static StaticClassMember static_member;
int (PointerToMember::*ptr_to_member);
UnusedClassMember unused_member;
UnusedClassMemberPtr *unused_member_ptr;
int enteredFunction() {

View File

@ -7,6 +7,12 @@ class TestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)
# GCC rejects the test code because `ToLayout` is not complete when
# pointer_to_member_member is declared.
@skipIf(compiler="gcc")
# On Windows both MSVC and Clang are rejecting the test code because
# `ToLayout` is not complete when pointer_to_member_member is declared.
@skipIfWindows
@no_debug_info_test
def test(self):
"""