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=macosx10.7
13 // XFAIL: with_system_cxx_lib=macosx10.8
17 // template <class _CharT, bool _International = false>
19 // : public locale::facet,
23 // typedef _CharT char_type;
24 // typedef basic_string<char_type> string_type;
25 // static const bool intl = International;
28 #include <type_traits>
31 void test(const _Tp &) {}
35 static_assert((std::is_base_of<std::locale::facet, std::moneypunct<char> >::value), "");
36 static_assert((std::is_base_of<std::locale::facet, std::moneypunct<wchar_t> >::value), "");
37 static_assert((std::is_base_of<std::money_base, std::moneypunct<char> >::value), "");
38 static_assert((std::is_base_of<std::money_base, std::moneypunct<wchar_t> >::value), "");
39 static_assert((std::is_same<std::moneypunct<char>::char_type, char>::value), "");
40 static_assert((std::is_same<std::moneypunct<wchar_t>::char_type, wchar_t>::value), "");
41 static_assert((std::is_same<std::moneypunct<char>::string_type, std::string>::value), "");
42 static_assert((std::is_same<std::moneypunct<wchar_t>::string_type, std::wstring>::value), "");
44 test(std::moneypunct<char, false>::intl);
45 test(std::moneypunct<char, true>::intl);
46 test(std::moneypunct<wchar_t, false>::intl);
47 test(std::moneypunct<wchar_t, true>::intl);