xref: /minix3/external/bsd/llvm/dist/clang/test/Headers/cxx11.cpp (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1*0a6a1f1dSLionel Sambuc // RUN: rm -rf %t
2f4a2713aSLionel Sambuc // RUN: %clang_cc1 -ffreestanding -fsyntax-only -std=c++11 %s
3*0a6a1f1dSLionel Sambuc // RUN: %clang_cc1 -ffreestanding -fsyntax-only -std=c++11 -fmodules -fmodules-cache-path=%t %s
4*0a6a1f1dSLionel Sambuc 
5*0a6a1f1dSLionel Sambuc // This test fails on systems with older OS X 10.9 SDK headers, see PR18322.
6f4a2713aSLionel Sambuc 
7f4a2713aSLionel Sambuc #include <stdalign.h>
8f4a2713aSLionel Sambuc 
9f4a2713aSLionel Sambuc #if defined alignas
10f4a2713aSLionel Sambuc #error alignas should not be defined in C++
11f4a2713aSLionel Sambuc #endif
12f4a2713aSLionel Sambuc 
13f4a2713aSLionel Sambuc #if defined alignof
14f4a2713aSLionel Sambuc #error alignof should not be defined in C++
15f4a2713aSLionel Sambuc #endif
16f4a2713aSLionel Sambuc 
17f4a2713aSLionel Sambuc static_assert(__alignas_is_defined, "");
18f4a2713aSLionel Sambuc static_assert(__alignof_is_defined, "");
19f4a2713aSLionel Sambuc 
20f4a2713aSLionel Sambuc 
21f4a2713aSLionel Sambuc #include <stdint.h>
22f4a2713aSLionel Sambuc 
23f4a2713aSLionel Sambuc #ifndef SIZE_MAX
24f4a2713aSLionel Sambuc #error SIZE_MAX should be defined in C++
25f4a2713aSLionel Sambuc #endif
26