1 //===----------------------------------------------------------------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is dual licensed under the MIT and the University of Illinois Open
6 // Source Licenses. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 // This test uses new symbols that were not defined in the libc++ shipped on
11 // darwin11 and darwin12:
12 // XFAIL: with_system_cxx_lib=x86_64-apple-macosx10.7
13 // XFAIL: with_system_cxx_lib=x86_64-apple-macosx10.8
17 // typedef int category;
20 #include <type_traits>
24 void test(const _Tp &) {}
29 static_assert((std::is_same<std::locale::category, int>::value), "");
30 assert(std::locale::none == 0);
31 assert(std::locale::collate);
32 assert(std::locale::ctype);
33 assert(std::locale::monetary);
34 assert(std::locale::numeric);
35 assert(std::locale::time);
36 assert(std::locale::messages);
37 assert((std::locale::collate
39 & std::locale::monetary
40 & std::locale::numeric
42 & std::locale::messages) == 0);
43 assert((std::locale::collate
45 | std::locale::monetary
46 | std::locale::numeric
48 | std::locale::messages)
51 test(std::locale::none);
52 test(std::locale::collate);
53 test(std::locale::ctype);
54 test(std::locale::monetary);
55 test(std::locale::numeric);
56 test(std::locale::time);
57 test(std::locale::messages);
58 test(std::locale::all);