minix/external/bsd/libc++/dist/libcxx/test/re/re.regex/types.pass.cpp
Lionel Sambuc 4684ddb6aa LLVM Minix changes
- import libcxx
 - reduce targets to the one when compiled as a tools

Change-Id: Iabb8427f80ff8e89463559a28bcb8b4f2bdbc496
2014-07-28 17:05:59 +02:00

35 lines
1.4 KiB
C++

//===----------------------------------------------------------------------===//
//
// 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.
//
//===----------------------------------------------------------------------===//
// <regex>
// template <class charT, class traits = regex_traits<charT>>
// class basic_regex
// {
// public:
// // types:
// typedef charT value_type;
// typedef regex_constants::syntax_option_type flag_type;
// typedef typename traits::locale_type locale_type;
#include <regex>
#include <type_traits>
int main()
{
static_assert((std::is_same<std::basic_regex<char>::value_type, char>::value), "");
static_assert((std::is_same<std::basic_regex<char>::flag_type,
std::regex_constants::syntax_option_type>::value), "");
static_assert((std::is_same<std::basic_regex<char>::locale_type, std::locale>::value), "");
static_assert((std::is_same<std::basic_regex<wchar_t>::value_type, wchar_t>::value), "");
static_assert((std::is_same<std::basic_regex<wchar_t>::flag_type,
std::regex_constants::syntax_option_type>::value), "");
static_assert((std::is_same<std::basic_regex<wchar_t>::locale_type, std::locale>::value), "");
}