summaryrefslogtreecommitdiffstats
path: root/libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.pass.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.pass.cpp')
-rw-r--r--libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.pass.cpp20
1 files changed, 11 insertions, 9 deletions
diff --git a/libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.pass.cpp b/libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.pass.cpp
index ae849ca5455..43f23f5ccc8 100644
--- a/libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.pass.cpp
+++ b/libcxx/test/std/utilities/meta/meta.trans/meta.trans.other/aligned_union.pass.cpp
@@ -13,12 +13,14 @@
#include <type_traits>
+#include "test_macros.h"
+
int main()
{
#ifndef _LIBCPP_HAS_NO_VARIADICS
{
typedef std::aligned_union<10, char >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<10, char>, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 1, "");
@@ -26,7 +28,7 @@ int main()
}
{
typedef std::aligned_union<10, short >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<10, short>, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 2, "");
@@ -34,7 +36,7 @@ int main()
}
{
typedef std::aligned_union<10, int >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<10, int>, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 4, "");
@@ -42,7 +44,7 @@ int main()
}
{
typedef std::aligned_union<10, double >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<10, double>, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 8, "");
@@ -50,7 +52,7 @@ int main()
}
{
typedef std::aligned_union<10, short, char >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<10, short, char>, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 2, "");
@@ -58,7 +60,7 @@ int main()
}
{
typedef std::aligned_union<10, char, short >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<10, char, short>, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 2, "");
@@ -66,7 +68,7 @@ int main()
}
{
typedef std::aligned_union<2, int, char, short >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<2, int, char, short>, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 4, "");
@@ -74,7 +76,7 @@ int main()
}
{
typedef std::aligned_union<2, char, int, short >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<2, char, int, short >, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 4, "");
@@ -82,7 +84,7 @@ int main()
}
{
typedef std::aligned_union<2, char, short, int >::type T1;
-#if _LIBCPP_STD_VER > 11
+#if TEST_STD_VER > 11
static_assert(std::is_same<std::aligned_union_t<2, char, short, int >, T1>::value, "" );
#endif
static_assert(std::alignment_of<T1>::value == 4, "");
OpenPOWER on IntegriCloud