summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarshall Clow <mclow.lists@gmail.com>2017-10-31 00:05:17 +0000
committerMarshall Clow <mclow.lists@gmail.com>2017-10-31 00:05:17 +0000
commit30631ea6aabcfe9ab406f0642e6a4426f64dc45e (patch)
treef97c37679d000c14d0f9f0346d42dd0afc527e4e
parent5552f503d52086efca9f33cf74885feb3a486fb0 (diff)
downloadbcm5719-llvm-30631ea6aabcfe9ab406f0642e6a4426f64dc45e.tar.gz
bcm5719-llvm-30631ea6aabcfe9ab406f0642e6a4426f64dc45e.zip
Add a fail test for aligned_union of an incomplete type. See LWG#2979. NFC
llvm-svn: 316969
-rw-r--r--libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.fail.cpp23
1 files changed, 23 insertions, 0 deletions
diff --git a/libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.fail.cpp b/libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.fail.cpp
new file mode 100644
index 00000000000..efee5064cf5
--- /dev/null
+++ b/libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.fail.cpp
@@ -0,0 +1,23 @@
+//===----------------------------------------------------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is dual licensed under the MIT and the University of Illinois Open
+// Source Licenses. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+
+// UNSUPPORTED: c++98, c++03
+
+// type_traits
+
+// aligned_union<size_t Len, class ...Types>
+
+#include <type_traits>
+
+class A; // Incomplete
+
+int main()
+{
+ typedef std::aligned_union<10, A>::type T1;
+}
OpenPOWER on IntegriCloud