diff options
author | Bruce Mitchener <bruce.mitchener@gmail.com> | 2014-01-12 16:13:42 +0700 |
---|---|---|
committer | Bruce Mitchener <bruce.mitchener@gmail.com> | 2014-01-13 17:59:15 +0700 |
commit | 5d078cbbd7d4319ed6a852e14bf3e45f58a99511 (patch) | |
tree | 65844da2a4220c28f701cf16c7578fa935671a4f | |
parent | 44cb63a6ecea58dc21d20843f5af0a006f8b36cd (diff) |
Update libcxx to current version.
23 files changed, 97 insertions, 71 deletions
diff --git a/system/include/libcxx/__config b/system/include/libcxx/__config index a45b02de..45207392 100644 --- a/system/include/libcxx/__config +++ b/system/include/libcxx/__config @@ -174,7 +174,7 @@ #endif #ifndef _LIBCPP_TYPE_VIS -# if __has_attribute(type_visibility) +# if __has_attribute(__type_visibility__) # define _LIBCPP_TYPE_VIS __attribute__ ((__type_visibility__("default"))) # else # define _LIBCPP_TYPE_VIS __attribute__ ((__visibility__("default"))) @@ -389,9 +389,7 @@ namespace std { #endif #if _GNUC_VER < 404 -#define _LIBCPP_HAS_NO_ADVANCED_SFINAE #define _LIBCPP_HAS_NO_DECLTYPE -#define _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS #define _LIBCPP_HAS_NO_DELETED_FUNCTIONS #define _LIBCPP_HAS_NO_UNICODE_CHARS #define _LIBCPP_HAS_NO_VARIADICS @@ -402,6 +400,11 @@ namespace std { #define _LIBCPP_HAS_NO_NULLPTR #endif +#if _GNUC_VER < 407 +#define _LIBCPP_HAS_NO_ADVANCED_SFINAE +#define _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#endif + #endif // __GXX_EXPERIMENTAL_CXX0X__ #define _LIBCPP_BEGIN_NAMESPACE_STD namespace std { namespace _LIBCPP_NAMESPACE { @@ -454,7 +457,6 @@ namespace std { #define _LIBCPP_HAS_NO_GENERALIZED_INITIALIZERS #define _LIBCPP_HAS_NO_NULLPTR #define _LIBCPP_HAS_NO_UNICODE_CHARS -#define _LIBCPP_HAS_NO_STRONG_ENUMS #define _LIBCPP_HAS_IS_BASE_OF #if defined(_AIX) @@ -514,7 +516,7 @@ template <unsigned> struct __static_assert_check {}; #define __has_feature(__x) 0 #endif -#if __has_feature(cxx_explicit_conversions) +#if __has_feature(cxx_explicit_conversions) || defined(__IBMCPP__) # define _LIBCPP_EXPLICIT explicit #else # define _LIBCPP_EXPLICIT @@ -567,6 +569,16 @@ template <unsigned> struct __static_assert_check {}; #define _LIBCPP_WCTYPE_IS_MASK #endif +#if defined(__APPLE__) +#ifndef _LIBCPP_TRIVIAL_PAIR_COPY_CTOR +# define _LIBCPP_TRIVIAL_PAIR_COPY_CTOR 0 +#endif +#endif + +#ifndef _LIBCPP_TRIVIAL_PAIR_COPY_CTOR +# define _LIBCPP_TRIVIAL_PAIR_COPY_CTOR 1 +#endif + #ifndef _LIBCPP_STD_VER # if __cplusplus <= 201103L # define _LIBCPP_STD_VER 11 diff --git a/system/include/libcxx/__undef_min_max b/system/include/libcxx/__undef_min_max index 2b6bc90a..5df9412c 100644 --- a/system/include/libcxx/__undef_min_max +++ b/system/include/libcxx/__undef_min_max @@ -10,7 +10,8 @@ #ifdef min #if defined(_MSC_VER) && ! defined(__clang__) -_LIBCPP_WARNING("macro min is incompatible with C++. #undefing min") +_LIBCPP_WARNING("macro min is incompatible with C++. Try #define NOMINMAX " + "before any Windows header. #undefing min") #else #warning: macro min is incompatible with C++. #undefing min #endif @@ -19,7 +20,8 @@ _LIBCPP_WARNING("macro min is incompatible with C++. #undefing min") #ifdef max #if defined(_MSC_VER) && ! defined(__clang__) -_LIBCPP_WARNING("macro max is incompatible with C++. #undefing max") +_LIBCPP_WARNING("macro max is incompatible with C++. Try #define NOMINMAX " + "before any Windows header. #undefing max") #else #warning: macro max is incompatible with C++. #undefing max #endif diff --git a/system/include/libcxx/dynarray b/system/include/libcxx/experimental/dynarray index b0d04f91..7c5c9b3f 100644 --- a/system/include/libcxx/dynarray +++ b/system/include/libcxx/experimental/dynarray @@ -17,7 +17,7 @@ /* dynarray synopsis -namespace std { +namespace std { namespace experimental { template< typename T > class dynarray @@ -93,7 +93,7 @@ public: void fill(const T& v); }; -} // std +}} // std::experimental */ @@ -112,7 +112,7 @@ public: #pragma GCC system_header #endif -_LIBCPP_BEGIN_NAMESPACE_STD +namespace std { namespace experimental { inline namespace __array_extensions_v1 { template <class _Tp> struct _LIBCPP_TYPE_VIS_ONLY dynarray @@ -302,9 +302,12 @@ dynarray<_Tp>::at(size_type __n) const return data()[__n]; } -template <class _Tp, class _Alloc> -struct _LIBCPP_TYPE_VIS_ONLY uses_allocator<dynarray<_Tp>, _Alloc> : true_type {}; +}}} + +_LIBCPP_BEGIN_NAMESPACE_STD +template <class _Tp, class _Alloc> +struct _LIBCPP_TYPE_VIS_ONLY uses_allocator<std::experimental::dynarray<_Tp>, _Alloc> : true_type {}; _LIBCPP_END_NAMESPACE_STD #endif // if _LIBCPP_STD_VER > 11 diff --git a/system/include/libcxx/optional b/system/include/libcxx/experimental/optional index a8e6a991..3848da87 100644 --- a/system/include/libcxx/optional +++ b/system/include/libcxx/experimental/optional @@ -18,8 +18,7 @@ #include <initializer_list> -namespace std -{ +namespace std { namespace experimental { // optional for object types template <class T> @@ -110,7 +109,7 @@ template <class T> constexpr optional<typename decay<T>::type> make_optional(T&& template <class T> struct hash; template <class T> struct hash<optional<T>>; -} // std +}} // std::experimental */ @@ -118,8 +117,7 @@ template <class T> struct hash<optional<T>>; #include <functional> #include <stdexcept> -namespace std // purposefully not using versioning namespace -{ +namespace std { namespace experimental { class _LIBCPP_EXCEPTION_ABI bad_optional_access : public logic_error @@ -142,7 +140,7 @@ public: virtual ~bad_optional_access() _NOEXCEPT; }; -} // std +}} // std::experimental #if _LIBCPP_STD_VER > 11 @@ -163,7 +161,7 @@ public: #pragma GCC system_header #endif -_LIBCPP_BEGIN_NAMESPACE_STD +namespace std { namespace experimental { inline namespace __library_fundamentals_v1 { struct in_place_t {}; constexpr in_place_t in_place{}; @@ -677,10 +675,14 @@ make_optional(_Tp&& __v) return optional<typename decay<_Tp>::type>(_VSTD::forward<_Tp>(__v)); } +}}} // namespace std::experimental::__library_fundamentals_v1 + +_LIBCPP_BEGIN_NAMESPACE_STD + template <class _Tp> -struct _LIBCPP_TYPE_VIS_ONLY hash<optional<_Tp> > +struct _LIBCPP_TYPE_VIS_ONLY hash<std::experimental::optional<_Tp> > { - typedef optional<_Tp> argument_type; + typedef std::experimental::optional<_Tp> argument_type; typedef size_t result_type; _LIBCPP_INLINE_VISIBILITY diff --git a/system/include/libcxx/ext/__hash b/system/include/libcxx/ext/__hash index 04975bfd..c0523cce 100644 --- a/system/include/libcxx/ext/__hash +++ b/system/include/libcxx/ext/__hash @@ -19,7 +19,7 @@ namespace __gnu_cxx { using namespace std; -template <typename T> struct _LIBCPP_TYPE_VIS_ONLY hash : public std::hash<T> +template <typename _Tp> struct _LIBCPP_TYPE_VIS_ONLY hash : public std::hash<_Tp> { }; template <> struct _LIBCPP_TYPE_VIS_ONLY hash<const char*> diff --git a/system/include/libcxx/iomanip b/system/include/libcxx/iomanip index cdb0d5f0..e334c7de 100644 --- a/system/include/libcxx/iomanip +++ b/system/include/libcxx/iomanip @@ -14,6 +14,8 @@ /* iomanip synopsis +namespace std { + // types T1, T2, ... are unspecified implementation types T1 resetiosflags(ios_base::fmtflags mask); T2 setiosflags (ios_base::fmtflags mask); @@ -604,7 +606,7 @@ basic_ostream<_CharT, _Traits>& operator<<( basic_ostream<_CharT, _Traits>& __os, const __quoted_proxy<_CharT, _Traits, _Allocator> & __proxy) { - return __quoted_output (__os, __proxy.string.cbegin (), __proxy.string.cend (), __proxy.__delim, __proxy.__escape); + return __quoted_output (__os, __proxy.__string.cbegin (), __proxy.__string.cend (), __proxy.__delim, __proxy.__escape); } // extractor for non-const basic_string& proxies diff --git a/system/include/libcxx/memory b/system/include/libcxx/memory index bf44837f..b382f70b 100644 --- a/system/include/libcxx/memory +++ b/system/include/libcxx/memory @@ -1954,7 +1954,7 @@ public: _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(_T1_param __t1, _T2_param __t2) : __first_(_VSTD::forward<_T1_param>(__t1)), __second_(_VSTD::forward<_T2_param>(__t2)) {} -#ifdef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#if defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(const __libcpp_compressed_pair_imp& __p) @@ -1973,8 +1973,6 @@ public: return *this; } -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(__libcpp_compressed_pair_imp&& __p) _NOEXCEPT_(is_nothrow_move_constructible<_T1>::value && @@ -1992,9 +1990,7 @@ public: return *this; } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#endif // _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#endif // defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) #ifndef _LIBCPP_HAS_NO_VARIADICS @@ -2051,7 +2047,7 @@ public: _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(_T1_param __t1, _T2_param __t2) : _T1(_VSTD::forward<_T1_param>(__t1)), __second_(_VSTD::forward<_T2_param>(__t2)) {} -#ifdef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#if defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(const __libcpp_compressed_pair_imp& __p) @@ -2069,8 +2065,6 @@ public: return *this; } -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(__libcpp_compressed_pair_imp&& __p) _NOEXCEPT_(is_nothrow_move_constructible<_T1>::value && @@ -2087,9 +2081,7 @@ public: return *this; } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#endif // _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#endif // defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) #ifndef _LIBCPP_HAS_NO_VARIADICS @@ -2147,7 +2139,7 @@ public: is_nothrow_move_constructible<_T2>::value) : _T2(_VSTD::forward<_T2_param>(__t2)), __first_(_VSTD::forward<_T1_param>(__t1)) {} -#ifdef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#if defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(const __libcpp_compressed_pair_imp& __p) @@ -2165,8 +2157,6 @@ public: return *this; } -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(__libcpp_compressed_pair_imp&& __p) _NOEXCEPT_(is_nothrow_move_constructible<_T1>::value && @@ -2183,9 +2173,7 @@ public: return *this; } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#endif // _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#endif // defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) #ifndef _LIBCPP_HAS_NO_VARIADICS @@ -2241,7 +2229,7 @@ public: _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(_T1_param __t1, _T2_param __t2) : _T1(_VSTD::forward<_T1_param>(__t1)), _T2(_VSTD::forward<_T2_param>(__t2)) {} -#ifdef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#if defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(const __libcpp_compressed_pair_imp& __p) @@ -2259,8 +2247,6 @@ public: return *this; } -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES - _LIBCPP_INLINE_VISIBILITY __libcpp_compressed_pair_imp(__libcpp_compressed_pair_imp&& __p) _NOEXCEPT_(is_nothrow_move_constructible<_T1>::value && @@ -2277,9 +2263,7 @@ public: return *this; } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#endif // _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#endif // defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) #ifndef _LIBCPP_HAS_NO_VARIADICS @@ -2332,7 +2316,7 @@ public: _LIBCPP_INLINE_VISIBILITY __compressed_pair(_T1_param __t1, _T2_param __t2) : base(_VSTD::forward<_T1_param>(__t1), _VSTD::forward<_T2_param>(__t2)) {} -#ifdef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#if defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) _LIBCPP_INLINE_VISIBILITY __compressed_pair(const __compressed_pair& __p) @@ -2349,7 +2333,6 @@ public: return *this; } -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES _LIBCPP_INLINE_VISIBILITY __compressed_pair(__compressed_pair&& __p) _NOEXCEPT_(is_nothrow_move_constructible<_T1>::value && @@ -2365,9 +2348,7 @@ public: return *this; } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES - -#endif // _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#endif // defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) #ifndef _LIBCPP_HAS_NO_VARIADICS diff --git a/system/include/libcxx/new b/system/include/libcxx/new index 31bb5982..ea4a4a01 100644 --- a/system/include/libcxx/new +++ b/system/include/libcxx/new @@ -94,6 +94,7 @@ public: }; #if defined(_LIBCPP_BUILDING_NEW) || (_LIBCPP_STD_VER > 11) + class _LIBCPP_EXCEPTION_ABI bad_array_length : public bad_alloc { @@ -102,7 +103,10 @@ public: virtual ~bad_array_length() _NOEXCEPT; virtual const char* what() const _NOEXCEPT; }; -#endif + +#define _LIBCPP_BAD_ARRAY_LENGTH_DEFINED + +#endif // defined(_LIBCPP_BUILDING_NEW) || (_LIBCPP_STD_VER > 11) _LIBCPP_FUNC_VIS void __throw_bad_alloc(); // not in C++ spec diff --git a/system/include/libcxx/readme.txt b/system/include/libcxx/readme.txt index ae8090fd..ccac2fcd 100644 --- a/system/include/libcxx/readme.txt +++ b/system/include/libcxx/readme.txt @@ -1 +1 @@ -These files are from libc++, svn revision 194185, 2013-11-07. +These files are from libc++, svn revision 195693, 2013-11-26. diff --git a/system/include/libcxx/support/ibm/support.h b/system/include/libcxx/support/ibm/support.h index 3effbaed..0abfa7f9 100644 --- a/system/include/libcxx/support/ibm/support.h +++ b/system/include/libcxx/support/ibm/support.h @@ -15,7 +15,7 @@ extern "builtin" int __popcnt4(unsigned int); extern "builtin" int __popcnt8(unsigned long long); extern "builtin" unsigned int __cnttz4(unsigned int); extern "builtin" unsigned int __cnttz8(unsigned long long); -extern "builtin" unsigned int __cntlz4(unsigned long long); +extern "builtin" unsigned int __cntlz4(unsigned int); extern "builtin" unsigned int __cntlz8(unsigned long long); // Builtin functions for counting population diff --git a/system/include/libcxx/support/win32/locale_win32.h b/system/include/libcxx/support/win32/locale_win32.h index e768af50..f728d234 100644 --- a/system/include/libcxx/support/win32/locale_win32.h +++ b/system/include/libcxx/support/win32/locale_win32.h @@ -103,9 +103,9 @@ isupper_l(int c, _locale_t loc) #define sscanf_l( __s, __l, __f, ...) _sscanf_l( __s, __f, __l, __VA_ARGS__ ) #define vsscanf_l( __s, __l, __f, ...) _sscanf_l( __s, __f, __l, __VA_ARGS__ ) #define sprintf_l( __s, __l, __f, ... ) _sprintf_l( __s, __f, __l, __VA_ARGS__ ) -#define snprintf_l( __s, __n, __l, __f, ... ) _snprintf_l( __s, __n, __f, __l, __VA_ARGS__ ) #define vsprintf_l( __s, __l, __f, ... ) _vsprintf_l( __s, __f, __l, __VA_ARGS__ ) #define vsnprintf_l( __s, __n, __l, __f, ... ) _vsnprintf_l( __s, __n, __f, __l, __VA_ARGS__ ) +int snprintf_l(char *ret, size_t n, locale_t loc, const char *format, ...); int asprintf_l( char **ret, locale_t loc, const char *format, ... ); int vasprintf_l( char **ret, locale_t loc, const char *format, va_list ap ); diff --git a/system/include/libcxx/support/win32/support.h b/system/include/libcxx/support/win32/support.h index b953ab77..ed1986e6 100644 --- a/system/include/libcxx/support/win32/support.h +++ b/system/include/libcxx/support/win32/support.h @@ -23,7 +23,6 @@ #ifndef NOMINMAX #define NOMINMAX #endif -#include <Windows.h> extern "C" { diff --git a/system/include/libcxx/type_traits b/system/include/libcxx/type_traits index b6430fbb..0ad7b7f2 100644 --- a/system/include/libcxx/type_traits +++ b/system/include/libcxx/type_traits @@ -1409,7 +1409,7 @@ template <class ..._Tp> using common_type_t = typename common_type<_Tp...>::type // is_assignable -template<typename, typename T> struct __select_2nd { typedef T type; }; +template<typename, typename _Tp> struct __select_2nd { typedef _Tp type; }; template <class _Tp, class _Arg> typename __select_2nd<decltype((_VSTD::declval<_Tp>() = _VSTD::declval<_Arg>())), true_type>::type @@ -2437,7 +2437,7 @@ template <class _Tp> struct _LIBCPP_TYPE_VIS_ONLY is_trivially_default_construct // is_trivially_copy_constructible template <class _Tp> struct _LIBCPP_TYPE_VIS_ONLY is_trivially_copy_constructible - : public is_trivially_constructible<_Tp, const typename add_lvalue_reference<_Tp>::type> + : public is_trivially_constructible<_Tp, typename add_lvalue_reference<const _Tp>::type> {}; // is_trivially_move_constructible diff --git a/system/include/libcxx/utility b/system/include/libcxx/utility index 5fc2cf20..2c1f62cc 100644 --- a/system/include/libcxx/utility +++ b/system/include/libcxx/utility @@ -272,10 +272,10 @@ struct _LIBCPP_TYPE_VIS_ONLY pair ) : first(__p.first), second(__p.second) {} -#ifndef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS +#if !defined(_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS) && _LIBCPP_TRIVIAL_PAIR_COPY_CTOR _LIBCPP_INLINE_VISIBILITY pair(const pair& __p) = default; -#else +#elif !defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) || !_LIBCPP_TRIVIAL_PAIR_COPY_CTOR _LIBCPP_INLINE_VISIBILITY pair(const pair& __p) _NOEXCEPT_(is_nothrow_copy_constructible<first_type>::value && diff --git a/system/lib/libc.symbols b/system/lib/libc.symbols index 561f01c1..931e9e5f 100644 --- a/system/lib/libc.symbols +++ b/system/lib/libc.symbols @@ -1,9 +1,15 @@ + T _ZNKSt16bad_array_length4whatEv T _ZNKSt20bad_array_new_length4whatEv T _ZNKSt9bad_alloc4whatEv + T _ZNSt16bad_array_lengthC1Ev + T _ZNSt16bad_array_lengthC2Ev + T _ZNSt16bad_array_lengthD0Ev + T _ZNSt16bad_array_lengthD1Ev + T _ZNSt16bad_array_lengthD2Ev T _ZNSt20bad_array_new_lengthC1Ev T _ZNSt20bad_array_new_lengthC2Ev T _ZNSt20bad_array_new_lengthD0Ev - ? _ZNSt20bad_array_new_lengthD1Ev + T _ZNSt20bad_array_new_lengthD1Ev T _ZNSt20bad_array_new_lengthD2Ev T _ZNSt9bad_allocC1Ev T _ZNSt9bad_allocC2Ev @@ -14,10 +20,15 @@ T _ZSt15set_new_handlerPFvvE T _ZSt17__throw_bad_allocv D _ZSt7nothrow + D _ZTISt16bad_array_length D _ZTISt20bad_array_new_length D _ZTISt9bad_alloc + C _ZTISt9exception + D _ZTSSt16bad_array_length D _ZTSSt20bad_array_new_length D _ZTSSt9bad_alloc + C _ZTSSt9exception + D _ZTVSt16bad_array_length D _ZTVSt20bad_array_new_length D _ZTVSt9bad_alloc W _ZdaPv diff --git a/system/lib/libcxx/exception.cpp b/system/lib/libcxx/exception.cpp index 83f6fd19..3ce6f2e1 100644 --- a/system/lib/libcxx/exception.cpp +++ b/system/lib/libcxx/exception.cpp @@ -24,7 +24,7 @@ #ifndef _LIBCPPABI_VERSION using namespace __cxxabiapple; // On Darwin, there are two STL shared libraries and a lower level ABI - // shared libray. The globals holding the current terminate handler and + // shared library. The globals holding the current terminate handler and // current unexpected handler are in the ABI library. #define __terminate_handler __cxxabiapple::__cxa_terminate_handler #define __unexpected_handler __cxxabiapple::__cxa_unexpected_handler diff --git a/system/lib/libcxx/locale.cpp b/system/lib/libcxx/locale.cpp index a326323a..8e7fdb43 100644 --- a/system/lib/libcxx/locale.cpp +++ b/system/lib/libcxx/locale.cpp @@ -1036,7 +1036,7 @@ ctype<char>::classic_table() _NOEXCEPT #elif defined(__EMSCRIPTEN__) return *__ctype_b_loc(); #elif defined(_AIX) - return (const unsigned long *)__lc_ctype_ptr->obj->mask; + return (const unsigned int *)__lc_ctype_ptr->obj->mask; #else // Platform not supported: abort so the person doing the port knows what to // fix diff --git a/system/lib/libcxx/new.cpp b/system/lib/libcxx/new.cpp index fa0331a8..f4998cfb 100644 --- a/system/lib/libcxx/new.cpp +++ b/system/lib/libcxx/new.cpp @@ -22,7 +22,7 @@ #ifndef _LIBCPPABI_VERSION // On Darwin, there are two STL shared libraries and a lower level ABI - // shared libray. The global holding the current new handler is + // shared library. The global holding the current new handler is // in the ABI library and named __cxa_new_handler. #define __new_handler __cxxabiapple::__cxa_new_handler #endif diff --git a/system/lib/libcxx/optional.cpp b/system/lib/libcxx/optional.cpp index fde071c9..b614d811 100644 --- a/system/lib/libcxx/optional.cpp +++ b/system/lib/libcxx/optional.cpp @@ -7,10 +7,10 @@ // //===----------------------------------------------------------------------===// -#include "optional" +#include "experimental/optional" namespace std // purposefully not using versioning namespace -{ +{ namespace experimental { #ifdef _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS @@ -22,4 +22,4 @@ bad_optional_access::~bad_optional_access() _NOEXCEPT = default; #endif -} // std +}} // std::experimental diff --git a/system/lib/libcxx/random.cpp b/system/lib/libcxx/random.cpp index 47cdee40..bd24f2e5 100644 --- a/system/lib/libcxx/random.cpp +++ b/system/lib/libcxx/random.cpp @@ -19,8 +19,10 @@ #ifdef __sun__ #define rename solaris_headers_are_broken #endif +#if !defined(_WIN32) #include <fcntl.h> #include <unistd.h> +#endif // defined(_WIN32) #include <errno.h> _LIBCPP_BEGIN_NAMESPACE_STD diff --git a/system/lib/libcxx/readme.txt b/system/lib/libcxx/readme.txt index ae8090fd..ccac2fcd 100644 --- a/system/lib/libcxx/readme.txt +++ b/system/lib/libcxx/readme.txt @@ -1 +1 @@ -These files are from libc++, svn revision 194185, 2013-11-07. +These files are from libc++, svn revision 195693, 2013-11-26. diff --git a/system/lib/libcxx/support/win32/locale_win32.cpp b/system/lib/libcxx/support/win32/locale_win32.cpp index 1729d84a..5a437434 100644 --- a/system/lib/libcxx/support/win32/locale_win32.cpp +++ b/system/lib/libcxx/support/win32/locale_win32.cpp @@ -80,6 +80,16 @@ int wctob_l( wint_t c, locale_t loc ) return wctob( c ); } +int snprintf_l(char *ret, size_t n, locale_t loc, const char *format, ...) +{ + __locale_raii __current( uselocale(loc), uselocale ); + va_list ap; + va_start( ap, format ); + int result = vsnprintf( ret, n, format, ap ); + va_end(ap); + return result; +} + int asprintf_l( char **ret, locale_t loc, const char *format, ... ) { va_list ap; diff --git a/system/lib/libcxx/symbols b/system/lib/libcxx/symbols index 51368bce..2c026b0f 100644 --- a/system/lib/libcxx/symbols +++ b/system/lib/libcxx/symbols @@ -2408,7 +2408,6 @@ D _ZTISt15underflow_error D _ZTISt16invalid_argument D _ZTISt16nested_exception - C _ZTISt9exception C _ZTSNSt3__110__stdinbufIcEE C _ZTSNSt3__110__stdinbufIwEE C _ZTSNSt3__110__time_getE @@ -2542,7 +2541,6 @@ D _ZTSSt15underflow_error D _ZTSSt16invalid_argument D _ZTSSt16nested_exception - C _ZTSSt9exception D _ZTTNSt3__110istrstreamE D _ZTTNSt3__110ostrstreamE W _ZTTNSt3__113basic_istreamIcNS_11char_traitsIcEEEE |