Windows support by Ruben Van Boxem.

llvm-svn: 142235
This commit is contained in:
Howard Hinnant 2011-10-17 20:05:10 +00:00
parent aa563df759
commit 073458b1ab
93 changed files with 286 additions and 40 deletions

View File

@ -14,7 +14,9 @@
#include <__config>
#include <algorithm>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -11,7 +11,9 @@
#ifndef _LIBCPP_CONFIG
#define _LIBCPP_CONFIG
#if !_MSC_VER // explicit macro necessary because it is only defined below in this file
#pragma GCC system_header
#endif
#define _LIBCPP_VERSION 1001
@ -69,17 +71,45 @@
# endif
#endif // !defined(_LIBCPP_LITTLE_ENDIAN) || !defined(_LIBCPP_BIG_ENDIAN)
#ifndef _LIBCPP_VISIBILITY_TAG
#define _LIBCPP_VISIBILITY_TAG 1
#if _WIN32
// only really useful for a DLL
#ifdef _LIBCPP_DLL // this should be a compiler builtin define ideally...
# ifdef cxx_EXPORTS
# define _LIBCPP_HIDDEN
# define _LIBCPP_VISIBLE __declspec(dllexport)
# else
# define _LIBCPP_HIDDEN
# define _LIBCPP_VISIBLE __declspec(dllimport)
# endif
#else
# define _LIBCPP_HIDDEN
# define _LIBCPP_VISIBLE
#endif
#if _LIBCPP_VISIBILITY_TAG
#ifndef _LIBCPP_INLINE_VISIBILITY
#define _LIBCPP_INLINE_VISIBILITY __forceinline
#endif
#ifndef _LIBCPP_EXCEPTION_ABI
#define _LIBCPP_EXCEPTION_ABI _LIBCPP_VISIBLE
#endif
#ifndef _LIBCPP_ALWAYS_INLINE
# if _MSC_VER
# define _LIBCPP_ALWAYS_INLINE __forceinline
# endif
#endif
#endif // _WIN32
#ifndef _LIBCPP_HIDDEN
#define _LIBCPP_HIDDEN __attribute__ ((__visibility__("hidden")))
#endif
#ifndef _LIBCPP_VISIBLE
#define _LIBCPP_VISIBLE __attribute__ ((__visibility__("default")))
#else // _LIBCPP_VISIBILITY_TAG
#define _LIBCPP_HIDDEN
#define _LIBCPP_VISIBLE
#endif // _LIBCPP_VISIBILITY_TAG
#endif
#ifndef _LIBCPP_INLINE_VISIBILITY
#define _LIBCPP_INLINE_VISIBILITY __attribute__ ((__visibility__("hidden"), __always_inline__))
@ -89,12 +119,22 @@
#define _LIBCPP_EXCEPTION_ABI __attribute__ ((__visibility__("default")))
#endif
#ifndef _LIBCPP_CANTTHROW
#define _LIBCPP_CANTTHROW __attribute__ ((__nothrow__))
#endif
#ifndef _LIBCPP_ALWAYS_INLINE
#define _LIBCPP_ALWAYS_INLINE __attribute__ ((__visibility__("hidden"), __always_inline__))
#endif
#if defined(__clang__)
#if __has_feature(cxx_alignas)
# define _ALIGNAS(x) alignas(x)
#else
# define _ALIGNAS(x) __attribute__((__aligned__(x)))
#endif
#if !__has_feature(cxx_alias_templates)
#define _LIBCPP_HAS_NO_TEMPLATE_ALIASES
#endif
@ -181,16 +221,6 @@ typedef __char32_t char32_t;
#define _LIBCPP_HAS_OBJC_ARC_WEAK
#endif
// Inline namespaces are available in Clang regardless of C++ dialect.
#define _LIBCPP_BEGIN_NAMESPACE_STD namespace std {inline namespace _LIBCPP_NAMESPACE {
#define _LIBCPP_END_NAMESPACE_STD } }
#define _VSTD std::_LIBCPP_NAMESPACE
namespace std {
inline namespace _LIBCPP_NAMESPACE {
}
}
#if !(__has_feature(cxx_constexpr))
#define _LIBCPP_HAS_NO_CONSTEXPR
#endif
@ -207,10 +237,20 @@ namespace std {
# define _LIBCXX_UNDERLYING_TYPE(T) __underlying_type(T)
#endif
// end defined(__clang__)
// Inline namespaces are available in Clang regardless of C++ dialect.
#define _LIBCPP_BEGIN_NAMESPACE_STD namespace std {inline namespace _LIBCPP_NAMESPACE {
#define _LIBCPP_END_NAMESPACE_STD } }
#define _VSTD std::_LIBCPP_NAMESPACE
namespace std {
inline namespace _LIBCPP_NAMESPACE {
}
}
#elif defined(__GNUC__)
#define _ALIGNAS(x) __attribute__((__aligned__(x)))
#define _ATTRIBUTE(x) __attribute__((x))
#if !__EXCEPTIONS
@ -275,7 +315,28 @@ namespace _LIBCPP_NAMESPACE {
using namespace _LIBCPP_NAMESPACE __attribute__((__strong__));
}
#endif // defined(__GNUC__)
#elif defined(_MSC_VER)
#define _LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER
#define _LIBCPP_HAS_NO_CONSTEXPR
#define _LIBCPP_HAS_NO_UNICODE_CHARS
#define _LIBCPP_HAS_NO_DELETED_FUNCTIONS
#define __alignof__ __alignof
#define _ATTRIBUTE __declspec
#define _ALIGNAS(x) __declspec(align(x))
#define _LIBCPP_HAS_NO_VARIADICS
#define _NOEXCEPT throw()
#define _NOEXCEPT_(x)
#define _LIBCPP_BEGIN_NAMESPACE_STD namespace std {
#define _LIBCPP_END_NAMESPACE_STD }
#define _VSTD std
namespace std {
}
#endif // __clang__ || __GNUC___ || _MSC_VER
#ifdef _LIBCPP_HAS_NO_UNICODE_CHARS
typedef unsigned short char16_t;

View File

@ -13,7 +13,9 @@
// manual variadic expansion for <functional>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
template <class _Tp>
class __mem_fn

View File

@ -16,7 +16,9 @@
#include <typeinfo>
#include <exception>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -18,7 +18,9 @@
#include <algorithm>
#include <cmath>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -25,7 +25,9 @@
# include <xlocale.h>
#endif // _WIN32 || __GLIBC__ || __APPLE__ || __FreeBSD_
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -16,7 +16,9 @@
#include <system_error>
#include <pthread.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#ifdef _LIBCPP_SHARED_LOCK

View File

@ -6,7 +6,9 @@
#include <type_traits>
#include <algorithm>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -15,7 +15,9 @@
#include <type_traits>
#include <new>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -17,7 +17,9 @@
#include <__locale>
#include <cstdio>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -17,7 +17,9 @@
#include <stdexcept>
#include <algorithm>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -15,7 +15,9 @@
#include <cstddef>
#include <type_traits>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#ifdef _LIBCPP_HAS_NO_VARIADICS

View File

@ -13,7 +13,9 @@
#include <__config>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -595,7 +595,9 @@ template <class BidirectionalIterator, class Compare>
#include <iterator>
#include <cstdlib>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -111,7 +111,9 @@ template <int I, class T, size_t N> T&& get(array<T, N>&&) noexcept;
#include <cassert>
#endif
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -526,7 +526,9 @@ void atomic_signal_fence(memory_order m);
#include <cstdint>
#include <type_traits>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -113,7 +113,9 @@ template <size_t N> struct hash<std::bitset<N>>;
*/
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#include <__config>
#include <__bit_reference>

View File

@ -20,4 +20,6 @@ Macros:
#include <__config>
#include <assert.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif

View File

@ -20,7 +20,9 @@
#include <complex>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
// hh 080623 Created

View File

@ -38,7 +38,9 @@ int toupper(int c);
#include <__config>
#include <ctype.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -26,7 +26,9 @@ Macros:
#include <__config>
#include <errno.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#if !defined(EOWNERDEAD) || !defined(ENOTRECOVERABLE)

View File

@ -56,7 +56,9 @@ int feupdateenv(const fenv_t* envp);
#include <__config>
#include <fenv.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -63,7 +63,9 @@ Macros:
#include <__config>
#include <float.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#ifndef FLT_EVAL_METHOD
#define FLT_EVAL_METHOD __FLT_EVAL_METHOD__

View File

@ -255,7 +255,9 @@ typedef steady_clock high_resolution_clock;
#include <ratio>
#include <limits>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -239,7 +239,9 @@ uintmax_t wcstoumax(const wchar_t* restrict nptr, wchar_t** restrict endptr, int
#include <cstdint>
#include <inttypes.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -18,6 +18,8 @@
#include <__config>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#endif // _LIBCPP_CISO646

View File

@ -41,6 +41,8 @@ Macros:
#include <__config>
#include <limits.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#endif // _LIBCPP_CLIMITS

View File

@ -38,7 +38,9 @@ lconv* localeconv();
#include <__config>
#include <locale.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -301,7 +301,9 @@ long double truncl(long double x);
#include <math.h>
#include <type_traits>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
// signbit

View File

@ -55,7 +55,9 @@ class codecvt_utf8_utf16
#include <__config>
#include <__locale>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -249,7 +249,9 @@ template<class T, class charT, class traits>
#include <cassert>
#endif
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -28,6 +28,8 @@
#endif // __cplusplus
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#endif // _LIBCPP_COMPLEX_H

View File

@ -111,7 +111,9 @@ public:
#include <__mutex_base>
#include <memory>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -34,7 +34,9 @@ void longjmp(jmp_buf env, int val);
#include <__config>
#include <setjmp.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#ifndef setjmp
#define setjmp(env) setjmp(env)

View File

@ -43,7 +43,9 @@ int raise(int sig);
#include <__config>
#include <signal.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -35,7 +35,9 @@ Types:
#include <__config>
#include <stdarg.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -22,7 +22,9 @@ Macros:
#include <__config>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#undef __bool_true_false_are_defined
#define __bool_true_false_are_defined 1

View File

@ -43,7 +43,9 @@ Types:
#include <stddef.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -144,7 +144,9 @@ Types:
#include <__config>
#include <stdint.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -99,7 +99,9 @@ void perror(const char* s);
#include <__config>
#include <stdio.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -82,7 +82,9 @@ size_t wcstombs(char* restrict s, const wchar_t* restrict pwcs, size_t n);
#include <__config>
#include <stdlib.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -60,7 +60,9 @@ size_t strlen(const char* s);
#include <__config>
#include <string.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -22,6 +22,8 @@
#include <ccomplex>
#include <cmath>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#endif // _LIBCPP_CTGMATH

View File

@ -47,7 +47,9 @@ size_t strftime(char* restrict s, size_t maxsize, const char* restrict format,
#include <__config>
#include <time.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -110,7 +110,9 @@ size_t wcsrtombs(char* restrict dst, const wchar_t** restrict src, size_t len,
#include <support/win32/support.h> // pull in *swprintf defines
#endif // _WIN32
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -54,7 +54,9 @@ wctrans_t wctrans(const char* property);
#include <cctype>
#include <wctype.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -150,7 +150,9 @@ template <class T, class Allocator>
*/
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#include <__config>
#include <__split_buffer>

View File

@ -80,7 +80,9 @@ template <class E> void rethrow_if_nested(const E& e);
#include <cstddef>
#include <type_traits>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
namespace std // purposefully not using versioning namespace
{

View File

@ -174,7 +174,9 @@ template <class T, class Allocator>
#include <iterator>
#include <algorithm>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -171,7 +171,9 @@ typedef basic_fstream<wchar_t> wfstream;
#include <__locale>
#include <cstdio>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -467,7 +467,9 @@ POLICY: For non-variadic implementations, the number of arguments is limited
#include <__functional_base>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -370,7 +370,9 @@ template <class R, class Alloc> struct uses_allocator<packaged_task<R>, Alloc>;
#include <mutex>
#include <thread>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -46,7 +46,9 @@ template<class E> const E* end(initializer_list<E> il) noexcept;
#include <__config>
#include <cstddef>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
namespace std // purposefully not versioned
{

View File

@ -33,7 +33,9 @@ template <class charT> T10 put_time(const struct tm* tmb, const charT* fmt);
#include <__config>
#include <istream>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -216,7 +216,9 @@ storage-class-specifier const error_category& iostream_category;
#include <__locale>
#include <system_error>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -89,7 +89,9 @@ typedef fpos<char_traits<wchar_t>::state_type> wstreampos;
#include <__config>
#include <wchar.h> // for mbstate_t
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -40,7 +40,9 @@ extern wostream wclog;
#include <istream>
#include <ostream>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -155,7 +155,9 @@ template <class charT, class traits, class T>
#include <__config>
#include <ostream>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -321,7 +321,9 @@ template <class T, size_t N> T* end(T (&array)[N]);
#include <cassert>
#endif
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -102,7 +102,9 @@ template<> class numeric_limits<cv long double>;
*/
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#include <__config>
#include <type_traits>

View File

@ -176,7 +176,9 @@ template <class T, class Alloc>
#include <iterator>
#include <algorithm>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -192,7 +192,9 @@ template <class charT> class messages_byname;
#include <nl_types.h>
#endif // !_WIN32
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -375,7 +375,9 @@ swap(multimap<Key, T, Compare, Allocator>& x,
#include <functional>
#include <initializer_list>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -600,7 +600,9 @@ void* align(size_t alignment, size_t size, void*& ptr, size_t& space);
#include <cassert>
#endif
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -179,7 +179,9 @@ template<class Callable, class ...Args>
#include <tuple>
#endif
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -56,7 +56,9 @@ void operator delete[](void* ptr, void*) noexcept;
#include <exception>
#include <cstddef>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
namespace std // purposefully not using versioning namespace
{

View File

@ -60,7 +60,9 @@ template <class ForwardIterator, class T>
#include <__config>
#include <iterator>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -133,7 +133,9 @@ template <class charT, class traits, class T>
#include <iterator>
#include <bitset>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -171,7 +171,9 @@ template <class T, class Container, class Compare>
#include <functional>
#include <algorithm>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -1646,7 +1646,9 @@ class piecewise_linear_distribution
#include <ostream>
#include <cmath>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -70,7 +70,9 @@ typedef ratio<1000000000000000000000000, 1> yotta; // not supported
#include <climits>
#include <type_traits>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -732,7 +732,9 @@ typedef regex_token_iterator<wstring::const_iterator> wsregex_token_iterator;
#include <vector>
#include <deque>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -106,7 +106,9 @@ template <class OuterA1, class OuterA2, class... InnerAllocs>
#include <__config>
#include <memory>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -338,7 +338,9 @@ swap(multiset<Key, Compare, Allocator>& x, multiset<Key, Compare, Allocator>& y)
#include <__tree>
#include <functional>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -175,7 +175,9 @@ typedef basic_stringstream<wchar_t> wstringstream;
#include <istream>
#include <string>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -85,7 +85,9 @@ template <class T, class Container>
#include <__config>
#include <deque>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -46,7 +46,9 @@ public:
#include <exception>
#include <iosfwd> // for string forward decl
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
namespace std // purposefully not using versioning namespace
{

View File

@ -112,7 +112,9 @@ protected:
#include <iosfwd>
#include <ios>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -446,7 +446,9 @@ template <> struct hash<wstring>;
#include <cassert>
#endif
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -131,7 +131,9 @@ private:
#include <ostream>
#include <istream>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -223,7 +223,9 @@ template <> struct hash<std::error_code>;
#include <stdexcept>
#include <__functional_base>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -22,6 +22,8 @@
#include <complex.h>
#include <math.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#endif // _LIBCPP_TGMATH_H

View File

@ -100,7 +100,9 @@ void sleep_for(const chrono::duration<Rep, Period>& rel_time);
#endif
#include <pthread.h>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
#define __STDCPP_THREADS__ __cplusplus

View File

@ -119,7 +119,9 @@ template <class... Types>
#include <memory>
#include <type_traits>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -142,7 +142,9 @@ namespace std
#include <__config>
#include <cstddef>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD
@ -891,12 +893,12 @@ struct _LIBCPP_VISIBLE aligned_storage
#define _CREATE_ALIGNED_STORAGE_SPECIALIZATION(n) \
template <size_t _Len>\
struct __attribute__ ((__visibility__("default"))) aligned_storage<_Len, n>\
struct _LIBCPP_VISIBLE aligned_storage<_Len, n>\
{\
struct type\
struct _ALIGNAS(n) type\
{\
unsigned char _[_Len];\
} __attribute__((__aligned__(n)));\
};\
}
_CREATE_ALIGNED_STORAGE_SPECIALIZATION(0x1);
@ -913,7 +915,10 @@ _CREATE_ALIGNED_STORAGE_SPECIALIZATION(0x400);
_CREATE_ALIGNED_STORAGE_SPECIALIZATION(0x800);
_CREATE_ALIGNED_STORAGE_SPECIALIZATION(0x1000);
_CREATE_ALIGNED_STORAGE_SPECIALIZATION(0x2000);
// MSDN says that MSVC does not support alignment beyond 8192 (=0x2000)
#if !defined(_MSC_VER)
_CREATE_ALIGNED_STORAGE_SPECIALIZATION(0x4000);
#endif // !_MSC_VER
#undef _CREATE_ALIGNED_STORAGE_SPECIALIZATION
@ -933,7 +938,7 @@ private:
typedef typename __promote<_A2>::type __type2;
typedef typename __promote<_A3>::type __type3;
public:
typedef __typeof__(__type1() + __type2() + __type3()) type;
typedef decltype(__type1() + __type2() + __type3()) type;
};
template <class _A1, class _A2>
@ -943,7 +948,7 @@ private:
typedef typename __promote<_A1>::type __type1;
typedef typename __promote<_A2>::type __type2;
public:
typedef __typeof__(__type1() + __type2()) type;
typedef decltype(__type1() + __type2()) type;
};
template <class _A1>

View File

@ -49,7 +49,9 @@ struct hash<type_index>
#include <typeinfo>
#include <__functional_base>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -61,7 +61,9 @@ public:
#include <exception>
#include <cstddef>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
namespace std // purposefully not using versioning namespace
{

View File

@ -319,7 +319,9 @@ template <class Key, class T, class Hash, class Pred, class Alloc>
#include <functional>
#include <stdexcept>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -305,7 +305,9 @@ template <class Value, class Hash, class Pred, class Alloc>
#include <__hash_table>
#include <functional>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -125,7 +125,9 @@ template<size_t I, class T1, class T2>
#include <__tuple>
#include <type_traits>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -346,7 +346,9 @@ template <class T> unspecified2 end(const valarray<T>& v);
#include <algorithm>
#include <functional>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -270,7 +270,9 @@ void swap(vector<T,Allocator>& x, vector<T,Allocator>& y)
#include <__split_buffer>
#include <__functional_base>
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD

View File

@ -157,7 +157,8 @@ input.output/
copy.pass.cpp: Windows locale names don't follow UNIX convention.
default.pass.cpp: idem.
streambuf.members/
locales.pass.cpp: Windows locale names don't follow UNIX convention.
streambuf.locales/
locales.pass.cpp: Windows locale names don't follow UNIX convention.
streambuf.protected/
streambuf.assign/
assign.pass.cpp: Windows locale names don't follow UNIX convention.
@ -223,21 +224,20 @@ localization/
wchar_t_unshift.pass.cpp: idem.
locale.codecvt.byname/
ctor_wchar_t.pass.cpp: Windows locale names don't follow UNIX convention.
locale.ctype/
locale.ctype.byname/
is_1.pass.cpp: Windows locale names don't follow UNIX convention.
is_many.pass.cpp: idem.
narrow_1.pass.cpp: idem.
narrow_many.pass.cpp: idem.
scan_is.pass.cpp: idem.
scan_not.pass.cpp: idem.
tolower_1.pass.cpp: idem.
tolower_many.pass.cpp: idem.
toupper_1.pass.cpp: idem.
toupper_many.pass.cpp: idem.
types.pass.cpp: idem.
widen_1.pass.cpp: idem.
widen_many.pass.cpp: idem.
locale.ctype.byname/
is_1.pass.cpp: Windows locale names don't follow UNIX convention.
is_many.pass.cpp: idem.
narrow_1.pass.cpp: idem.
narrow_many.pass.cpp: idem.
scan_is.pass.cpp: idem.
scan_not.pass.cpp: idem.
tolower_1.pass.cpp: idem.
tolower_many.pass.cpp: idem.
toupper_1.pass.cpp: idem.
toupper_many.pass.cpp: idem.
types.pass.cpp: idem.
widen_1.pass.cpp: idem.
widen_many.pass.cpp: idem.
category.monetary/
locale.money.get/
locale.money.get.members/