From 8d0ea13047fb54611425f8f7f84cc529bf08c3b8 Mon Sep 17 00:00:00 2001 From: Hans Wennborg Date: Tue, 6 Feb 2018 13:22:33 +0000 Subject: Merging r324153: ------------------------------------------------------------------------ r324153 | ericwf | 2018-02-02 23:39:59 +0100 (Fri, 02 Feb 2018) | 6 lines Fix has_unique_object_representation after Clang commit r324134. Clang previously reported an empty union as having a unique object representation. This was incorrect and was fixed in a recent Clang commit. This patch fixes the libc++ tests. ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/libcxx/branches/release_60@324345 91177308-0d34-0410-b5e6-96231b3b80d8 --- .../meta.unary.prop/has_unique_object_representations.pass.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/std/utilities/meta/meta.unary/meta.unary.prop/has_unique_object_representations.pass.cpp b/test/std/utilities/meta/meta.unary/meta.unary.prop/has_unique_object_representations.pass.cpp index e4a3d203c..52100c304 100644 --- a/test/std/utilities/meta/meta.unary/meta.unary.prop/has_unique_object_representations.pass.cpp +++ b/test/std/utilities/meta/meta.unary/meta.unary.prop/has_unique_object_representations.pass.cpp @@ -55,7 +55,8 @@ class NotEmpty virtual ~NotEmpty(); }; -union Union {}; +union EmptyUnion {}; +struct NonEmptyUnion {int x; unsigned y;}; struct bit_zero { @@ -84,6 +85,7 @@ int main() { test_has_not_has_unique_object_representations(); test_has_not_has_unique_object_representations(); + test_has_not_has_unique_object_representations(); test_has_not_has_unique_object_representations(); test_has_not_has_unique_object_representations(); test_has_not_has_unique_object_representations(); @@ -97,7 +99,7 @@ int main() test_has_unique_object_representations(); - test_has_unique_object_representations(); + test_has_unique_object_representations(); test_has_unique_object_representations(); test_has_unique_object_representations(); -- cgit v1.2.3