Date: Tue, 30 Aug 2016 18:27:31 +0000 (UTC) From: Dimitry Andric <dim@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r305076 - in projects/clang390-import: contrib/libc++ contrib/libc++/include contrib/libc++/include/experimental contrib/libc++/include/ext contrib/libc++/src contrib/libc++/src/experim... Message-ID: <201608301827.u7UIRV2V097991@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: dim Date: Tue Aug 30 18:27:31 2016 New Revision: 305076 URL: https://svnweb.freebsd.org/changeset/base/305076 Log: Update libc++ to release_39 branch r279689. Added: projects/clang390-import/contrib/libc++/include/__bsd_locale_defaults.h - copied unchanged from r305029, vendor/libc++/dist/include/__bsd_locale_defaults.h projects/clang390-import/contrib/libc++/include/__bsd_locale_fallbacks.h - copied unchanged from r305029, vendor/libc++/dist/include/__bsd_locale_fallbacks.h projects/clang390-import/contrib/libc++/include/__threading_support - copied unchanged from r305029, vendor/libc++/dist/include/__threading_support projects/clang390-import/contrib/libc++/include/experimental/__memory - copied unchanged from r305029, vendor/libc++/dist/include/experimental/__memory projects/clang390-import/contrib/libc++/include/experimental/deque - copied unchanged from r305029, vendor/libc++/dist/include/experimental/deque projects/clang390-import/contrib/libc++/include/experimental/filesystem - copied unchanged from r305029, vendor/libc++/dist/include/experimental/filesystem projects/clang390-import/contrib/libc++/include/experimental/forward_list - copied unchanged from r305029, vendor/libc++/dist/include/experimental/forward_list projects/clang390-import/contrib/libc++/include/experimental/iterator - copied unchanged from r305029, vendor/libc++/dist/include/experimental/iterator projects/clang390-import/contrib/libc++/include/experimental/list - copied unchanged from r305029, vendor/libc++/dist/include/experimental/list projects/clang390-import/contrib/libc++/include/experimental/map - copied unchanged from r305029, vendor/libc++/dist/include/experimental/map projects/clang390-import/contrib/libc++/include/experimental/memory_resource - copied unchanged from r305029, vendor/libc++/dist/include/experimental/memory_resource projects/clang390-import/contrib/libc++/include/experimental/propagate_const - copied unchanged from r305029, vendor/libc++/dist/include/experimental/propagate_const projects/clang390-import/contrib/libc++/include/experimental/regex - copied unchanged from r305029, vendor/libc++/dist/include/experimental/regex projects/clang390-import/contrib/libc++/include/experimental/set - copied unchanged from r305029, vendor/libc++/dist/include/experimental/set projects/clang390-import/contrib/libc++/include/experimental/string - copied unchanged from r305029, vendor/libc++/dist/include/experimental/string projects/clang390-import/contrib/libc++/include/experimental/unordered_map - copied unchanged from r305029, vendor/libc++/dist/include/experimental/unordered_map projects/clang390-import/contrib/libc++/include/experimental/unordered_set - copied unchanged from r305029, vendor/libc++/dist/include/experimental/unordered_set projects/clang390-import/contrib/libc++/include/experimental/vector - copied unchanged from r305029, vendor/libc++/dist/include/experimental/vector projects/clang390-import/contrib/libc++/include/stdbool.h - copied unchanged from r305029, vendor/libc++/dist/include/stdbool.h projects/clang390-import/contrib/libc++/include/string.h - copied unchanged from r305029, vendor/libc++/dist/include/string.h projects/clang390-import/contrib/libc++/src/experimental/ - copied from r305029, vendor/libc++/dist/src/experimental/ Modified: projects/clang390-import/contrib/libc++/CREDITS.TXT projects/clang390-import/contrib/libc++/LICENSE.TXT projects/clang390-import/contrib/libc++/include/__config projects/clang390-import/contrib/libc++/include/__functional_base projects/clang390-import/contrib/libc++/include/__hash_table projects/clang390-import/contrib/libc++/include/__mutex_base projects/clang390-import/contrib/libc++/include/__tree projects/clang390-import/contrib/libc++/include/__tuple projects/clang390-import/contrib/libc++/include/__undef___deallocate projects/clang390-import/contrib/libc++/include/__undef_min_max projects/clang390-import/contrib/libc++/include/algorithm projects/clang390-import/contrib/libc++/include/array projects/clang390-import/contrib/libc++/include/atomic projects/clang390-import/contrib/libc++/include/bitset projects/clang390-import/contrib/libc++/include/cctype projects/clang390-import/contrib/libc++/include/cmath projects/clang390-import/contrib/libc++/include/complex projects/clang390-import/contrib/libc++/include/cstring projects/clang390-import/contrib/libc++/include/cwchar projects/clang390-import/contrib/libc++/include/deque projects/clang390-import/contrib/libc++/include/exception projects/clang390-import/contrib/libc++/include/experimental/__config projects/clang390-import/contrib/libc++/include/experimental/algorithm projects/clang390-import/contrib/libc++/include/experimental/any projects/clang390-import/contrib/libc++/include/experimental/dynarray projects/clang390-import/contrib/libc++/include/experimental/functional projects/clang390-import/contrib/libc++/include/experimental/optional projects/clang390-import/contrib/libc++/include/experimental/string_view projects/clang390-import/contrib/libc++/include/experimental/tuple projects/clang390-import/contrib/libc++/include/ext/hash_map projects/clang390-import/contrib/libc++/include/ext/hash_set projects/clang390-import/contrib/libc++/include/forward_list projects/clang390-import/contrib/libc++/include/fstream projects/clang390-import/contrib/libc++/include/functional projects/clang390-import/contrib/libc++/include/future projects/clang390-import/contrib/libc++/include/iomanip projects/clang390-import/contrib/libc++/include/ios projects/clang390-import/contrib/libc++/include/iosfwd projects/clang390-import/contrib/libc++/include/istream projects/clang390-import/contrib/libc++/include/iterator projects/clang390-import/contrib/libc++/include/list projects/clang390-import/contrib/libc++/include/locale projects/clang390-import/contrib/libc++/include/map projects/clang390-import/contrib/libc++/include/memory projects/clang390-import/contrib/libc++/include/mutex projects/clang390-import/contrib/libc++/include/queue projects/clang390-import/contrib/libc++/include/shared_mutex projects/clang390-import/contrib/libc++/include/stack projects/clang390-import/contrib/libc++/include/stdexcept projects/clang390-import/contrib/libc++/include/streambuf projects/clang390-import/contrib/libc++/include/string projects/clang390-import/contrib/libc++/include/thread projects/clang390-import/contrib/libc++/include/tuple projects/clang390-import/contrib/libc++/include/type_traits projects/clang390-import/contrib/libc++/include/unordered_map projects/clang390-import/contrib/libc++/include/unordered_set projects/clang390-import/contrib/libc++/include/utility projects/clang390-import/contrib/libc++/include/vector projects/clang390-import/contrib/libc++/include/wchar.h projects/clang390-import/contrib/libc++/src/algorithm.cpp projects/clang390-import/contrib/libc++/src/bind.cpp projects/clang390-import/contrib/libc++/src/condition_variable.cpp projects/clang390-import/contrib/libc++/src/locale.cpp projects/clang390-import/contrib/libc++/src/memory.cpp projects/clang390-import/contrib/libc++/src/mutex.cpp projects/clang390-import/contrib/libc++/src/regex.cpp projects/clang390-import/contrib/libc++/src/strstream.cpp projects/clang390-import/contrib/libc++/src/system_error.cpp projects/clang390-import/contrib/libc++/src/thread.cpp projects/clang390-import/lib/libc++/Makefile Directory Properties: projects/clang390-import/contrib/libc++/ (props changed) Modified: projects/clang390-import/contrib/libc++/CREDITS.TXT ============================================================================== --- projects/clang390-import/contrib/libc++/CREDITS.TXT Tue Aug 30 18:01:26 2016 (r305075) +++ projects/clang390-import/contrib/libc++/CREDITS.TXT Tue Aug 30 18:27:31 2016 (r305076) @@ -37,6 +37,10 @@ E: mclow.lists@gmail.com E: marshall@idio.com D: C++14 support, patches and bug fixes. +N: Jonathan B Coe +E: jbcoe@me.com +D: Implementation of propagate_const. + N: Eric Fiselier E: eric@efcs.ca D: LFTS support, patches and bug fixes. Modified: projects/clang390-import/contrib/libc++/LICENSE.TXT ============================================================================== --- projects/clang390-import/contrib/libc++/LICENSE.TXT Tue Aug 30 18:01:26 2016 (r305075) +++ projects/clang390-import/contrib/libc++/LICENSE.TXT Tue Aug 30 18:27:31 2016 (r305076) @@ -14,7 +14,7 @@ Full text of the relevant licenses is in University of Illinois/NCSA Open Source License -Copyright (c) 2009-2015 by the contributors listed in CREDITS.TXT +Copyright (c) 2009-2016 by the contributors listed in CREDITS.TXT All rights reserved. Copied: projects/clang390-import/contrib/libc++/include/__bsd_locale_defaults.h (from r305029, vendor/libc++/dist/include/__bsd_locale_defaults.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ projects/clang390-import/contrib/libc++/include/__bsd_locale_defaults.h Tue Aug 30 18:27:31 2016 (r305076, copy of r305029, vendor/libc++/dist/include/__bsd_locale_defaults.h) @@ -0,0 +1,33 @@ +// -*- C++ -*- +//===---------------------- __bsd_locale_defaults.h -----------------------===// +// +// 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. +// +//===----------------------------------------------------------------------===// +// The BSDs have lots of *_l functions. We don't want to define those symbols +// on other platforms though, for fear of conflicts with user code. So here, +// we will define the mapping from an internal macro to the real BSD symbol. +//===----------------------------------------------------------------------===// + +#ifndef _LIBCPP_BSD_LOCALE_DEFAULTS_H +#define _LIBCPP_BSD_LOCALE_DEFAULTS_H + +#define __libcpp_mb_cur_max_l(loc) MB_CUR_MAX_L(loc) +#define __libcpp_btowc_l(ch, loc) btowc_l(ch, loc) +#define __libcpp_wctob_l(wch, loc) wctob_l(wch, loc) +#define __libcpp_wcsnrtombs_l(dst, src, nwc, len, ps, loc) wcsnrtombs_l(dst, src, nwc, len, ps, loc) +#define __libcpp_wcrtomb_l(src, wc, ps, loc) wcrtomb_l(src, wc, ps, loc) +#define __libcpp_mbsnrtowcs_l(dst, src, nms, len, ps, loc) mbsnrtowcs_l(dst, src, nms, len, ps, loc) +#define __libcpp_mbrtowc_l(pwc, s, n, ps, l) mbrtowc_l(pwc, s, n, ps, l) +#define __libcpp_mbtowc_l(pwc, pmb, max, l) mbtowc_l(pwc, pmb, max, l) +#define __libcpp_mbrlen_l(s, n, ps, l) mbrlen_l(s, n, ps, l) +#define __libcpp_localeconv_l(l) localeconv_l(l) +#define __libcpp_mbsrtowcs_l(dest, src, len, ps, l) mbsrtowcs_l(dest, src, len, ps, l) +#define __libcpp_snprintf_l(...) snprintf_l(__VA_ARGS__) +#define __libcpp_asprintf_l(...) asprintf_l(__VA_ARGS__) +#define __libcpp_sscanf_l(...) sscanf_l(__VA_ARGS__) + +#endif // _LIBCPP_BSD_LOCALE_DEFAULTS_H Copied: projects/clang390-import/contrib/libc++/include/__bsd_locale_fallbacks.h (from r305029, vendor/libc++/dist/include/__bsd_locale_fallbacks.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ projects/clang390-import/contrib/libc++/include/__bsd_locale_fallbacks.h Tue Aug 30 18:27:31 2016 (r305076, copy of r305029, vendor/libc++/dist/include/__bsd_locale_fallbacks.h) @@ -0,0 +1,138 @@ +// -*- C++ -*- +//===---------------------- __bsd_locale_fallbacks.h ----------------------===// +// +// 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. +// +//===----------------------------------------------------------------------===// +// The BSDs have lots of *_l functions. This file provides reimplementations +// of those functions for non-BSD platforms. +//===----------------------------------------------------------------------===// + +#ifndef _LIBCPP_BSD_LOCALE_FALLBACKS_DEFAULTS_H +#define _LIBCPP_BSD_LOCALE_FALLBACKS_DEFAULTS_H + +#include <stdlib.h> +#include <memory> + +_LIBCPP_BEGIN_NAMESPACE_STD + +typedef _VSTD::remove_pointer<locale_t>::type __use_locale_struct; +typedef _VSTD::unique_ptr<__use_locale_struct, decltype(&uselocale)> __locale_raii; + +inline _LIBCPP_ALWAYS_INLINE +decltype(MB_CUR_MAX) __libcpp_mb_cur_max_l(locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return MB_CUR_MAX; +} + +inline _LIBCPP_ALWAYS_INLINE +wint_t __libcpp_btowc_l(int __c, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return btowc(__c); +} + +inline _LIBCPP_ALWAYS_INLINE +int __libcpp_wctob_l(wint_t __c, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return wctob(__c); +} + +inline _LIBCPP_ALWAYS_INLINE +size_t __libcpp_wcsnrtombs_l(char *__dest, const wchar_t **__src, size_t __nwc, + size_t __len, mbstate_t *__ps, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return wcsnrtombs(__dest, __src, __nwc, __len, __ps); +} + +inline _LIBCPP_ALWAYS_INLINE +size_t __libcpp_wcrtomb_l(char *__s, wchar_t __wc, mbstate_t *__ps, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return wcrtomb(__s, __wc, __ps); +} + +inline _LIBCPP_ALWAYS_INLINE +size_t __libcpp_mbsnrtowcs_l(wchar_t * __dest, const char **__src, size_t __nms, + size_t __len, mbstate_t *__ps, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return mbsnrtowcs(__dest, __src, __nms, __len, __ps); +} + +inline _LIBCPP_ALWAYS_INLINE +size_t __libcpp_mbrtowc_l(wchar_t *__pwc, const char *__s, size_t __n, + mbstate_t *__ps, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return mbrtowc(__pwc, __s, __n, __ps); +} + +inline _LIBCPP_ALWAYS_INLINE +int __libcpp_mbtowc_l(wchar_t *__pwc, const char *__pmb, size_t __max, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return mbtowc(__pwc, __pmb, __max); +} + +inline _LIBCPP_ALWAYS_INLINE +size_t __libcpp_mbrlen_l(const char *__s, size_t __n, mbstate_t *__ps, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return mbrlen(__s, __n, __ps); +} + +inline _LIBCPP_ALWAYS_INLINE +lconv *__libcpp_localeconv_l(locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return localeconv(); +} + +inline _LIBCPP_ALWAYS_INLINE +size_t __libcpp_mbsrtowcs_l(wchar_t *__dest, const char **__src, size_t __len, + mbstate_t *__ps, locale_t __l) +{ + __locale_raii __current( uselocale(__l), uselocale ); + return mbsrtowcs(__dest, __src, __len, __ps); +} + +inline +int __libcpp_snprintf_l(char *__s, size_t __n, locale_t __l, const char *__format, ...) { + va_list __va; + va_start(__va, __format); + __locale_raii __current( uselocale(__l), uselocale ); + int __res = vsnprintf(__s, __n, __format, __va); + va_end(__va); + return __res; +} + +inline +int __libcpp_asprintf_l(char **__s, locale_t __l, const char *__format, ...) { + va_list __va; + va_start(__va, __format); + __locale_raii __current( uselocale(__l), uselocale ); + int __res = vasprintf(__s, __format, __va); + va_end(__va); + return __res; +} + +inline +int __libcpp_sscanf_l(const char *__s, locale_t __l, const char *__format, ...) { + va_list __va; + va_start(__va, __format); + __locale_raii __current( uselocale(__l), uselocale ); + int __res = vsscanf(__s, __format, __va); + va_end(__va); + return __res; +} + +_LIBCPP_END_NAMESPACE_STD + +#endif // _LIBCPP_BSD_LOCALE_FALLBACKS_DEFAULTS_H Modified: projects/clang390-import/contrib/libc++/include/__config ============================================================================== --- projects/clang390-import/contrib/libc++/include/__config Tue Aug 30 18:01:26 2016 (r305075) +++ projects/clang390-import/contrib/libc++/include/__config Tue Aug 30 18:27:31 2016 (r305076) @@ -27,7 +27,7 @@ #define _GNUC_VER 0 #endif -#define _LIBCPP_VERSION 3800 +#define _LIBCPP_VERSION 3900 #ifndef _LIBCPP_ABI_VERSION #define _LIBCPP_ABI_VERSION 1 @@ -41,6 +41,22 @@ #define _LIBCPP_ABI_INCOMPLETE_TYPES_IN_DEQUE // Fix undefined behavior in how std::list stores it's linked nodes. #define _LIBCPP_ABI_LIST_REMOVE_NODE_POINTER_UB +// Fix undefined behavior in how __tree stores its end and parent nodes. +#define _LIBCPP_ABI_TREE_REMOVE_NODE_POINTER_UB +#define _LIBCPP_ABI_FORWARD_LIST_REMOVE_NODE_POINTER_UB +#define _LIBCPP_ABI_FIX_UNORDERED_CONTAINER_SIZE_TYPE +#define _LIBCPP_ABI_VARIADIC_LOCK_GUARD +#elif _LIBCPP_ABI_VERSION == 1 +// Feature macros for disabling pre ABI v1 features. All of these options +// are deprecated. +#if defined(__FreeBSD__) +#define _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR +#endif +#endif + +#ifdef _LIBCPP_TRIVIAL_PAIR_COPY_CTOR +#error "_LIBCPP_TRIVIAL_PAIR_COPY_CTOR" is no longer supported. \ + use _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR instead #endif #define _LIBCPP_CONCAT1(_LIBCPP_X,_LIBCPP_Y) _LIBCPP_X##_LIBCPP_Y @@ -178,6 +194,12 @@ # endif #endif // !defined(_LIBCPP_LITTLE_ENDIAN) || !defined(_LIBCPP_BIG_ENDIAN) +#if __has_attribute(__no_sanitize__) +#define _LIBCPP_NO_CFI __attribute__((__no_sanitize__("cfi"))) +#else +#define _LIBCPP_NO_CFI +#endif + #ifdef _WIN32 // only really useful for a DLL @@ -236,6 +258,12 @@ # endif #endif +#ifndef _LIBCPP_PREFERRED_OVERLOAD +# if __has_attribute(__enable_if__) +# define _LIBCPP_PREFERRED_OVERLOAD __attribute__ ((__enable_if__(true, ""))) +# endif +#endif + #ifndef _LIBCPP_TYPE_VIS_ONLY # define _LIBCPP_TYPE_VIS_ONLY _LIBCPP_TYPE_VIS #endif @@ -283,7 +311,7 @@ typedef __char16_t char16_t; typedef __char32_t char32_t; #endif -#if !(__has_feature(cxx_exceptions)) +#if !(__has_feature(cxx_exceptions)) && !defined(_LIBCPP_NO_EXCEPTIONS) #define _LIBCPP_NO_EXCEPTIONS #endif @@ -305,8 +333,6 @@ typedef __char32_t char32_t; # define _LIBCPP_NORETURN __attribute__ ((noreturn)) #endif -#define _LIBCPP_UNUSED __attribute__((__unused__)) - #if !(__has_feature(cxx_default_function_template_args)) #define _LIBCPP_HAS_NO_DEFAULT_FUNCTION_TEMPLATE_ARGS #endif @@ -434,8 +460,8 @@ namespace std { #endif // Allow for build-time disabling of unsigned integer sanitization -#ifndef _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK -#define _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK __attribute((no_sanitize("unsigned-integer-overflow"))) +#if !defined(_LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK) && __has_attribute(no_sanitize) +#define _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK __attribute__((__no_sanitize__("unsigned-integer-overflow"))) #endif #elif defined(__GNUC__) @@ -445,8 +471,6 @@ namespace std { #define _LIBCPP_NORETURN __attribute__((noreturn)) -#define _LIBCPP_UNUSED __attribute__((__unused__)) - #if _GNUC_VER >= 407 #define _LIBCPP_UNDERLYING_TYPE(T) __underlying_type(T) #define _LIBCPP_IS_LITERAL(T) __is_literal_type(T) @@ -461,8 +485,6 @@ namespace std { #define _LIBCPP_NO_EXCEPTIONS #endif -#define _LIBCPP_HAS_NO_TEMPLATE_ALIASES - // constexpr was added to GCC in 4.6. #if _GNUC_VER < 406 #define _LIBCPP_HAS_NO_CONSTEXPR @@ -494,6 +516,7 @@ namespace std { #define _LIBCPP_HAS_NO_VARIADICS #define _LIBCPP_HAS_NO_RVALUE_REFERENCES #define _LIBCPP_HAS_NO_STRONG_ENUMS +#define _LIBCPP_HAS_NO_TEMPLATE_ALIASES #define _LIBCPP_HAS_NO_NOEXCEPT #else // __GXX_EXPERIMENTAL_CXX0X__ @@ -517,6 +540,7 @@ namespace std { #if _GNUC_VER < 406 #define _LIBCPP_HAS_NO_NOEXCEPT #define _LIBCPP_HAS_NO_NULLPTR +#define _LIBCPP_HAS_NO_TEMPLATE_ALIASES #endif #if _GNUC_VER < 407 @@ -552,7 +576,6 @@ using namespace _LIBCPP_NAMESPACE __attr #define _LIBCPP_HAS_NO_NOEXCEPT #define __alignof__ __alignof #define _LIBCPP_NORETURN __declspec(noreturn) -#define _LIBCPP_UNUSED #define _ALIGNAS(x) __declspec(align(x)) #define _LIBCPP_HAS_NO_VARIADICS @@ -574,7 +597,6 @@ namespace std { #define _ALIGNAS_TYPE(x) __attribute__((__aligned__(__alignof(x)))) #define _ATTRIBUTE(x) __attribute__((x)) #define _LIBCPP_NORETURN __attribute__((noreturn)) -#define _LIBCPP_UNUSED #define _LIBCPP_HAS_NO_DEFAULT_FUNCTION_TEMPLATE_ARGS #define _LIBCPP_HAS_NO_TEMPLATE_ALIASES @@ -655,6 +677,12 @@ template <unsigned> struct __static_asse #define _LIBCPP_DEFAULT = default; #endif +#ifdef _LIBCPP_HAS_NO_DELETED_FUNCTIONS +#define _LIBCPP_EQUAL_DELETE +#else +#define _LIBCPP_EQUAL_DELETE = delete +#endif + #ifdef __GNUC__ #define _NOALIAS __attribute__((__malloc__)) #else @@ -712,10 +740,12 @@ template <unsigned> struct __static_asse #define _LIBCPP_LOCALE__L_EXTENSIONS 1 #endif -#if !defined(_WIN32) && !defined(__ANDROID__) && !defined(_NEWLIB_VERSION) && \ - !defined(__CloudABI__) +#if defined(__unix__) || (defined(__APPLE__) && defined(__MACH__)) +// Most unix variants have catopen. These are the specific ones that don't. +#if !defined(_WIN32) && !defined(__ANDROID__) && !defined(_NEWLIB_VERSION) #define _LIBCPP_HAS_CATOPEN 1 #endif +#endif #ifdef __FreeBSD__ #define _DECLARE_C99_LDBL_MATH 1 @@ -729,24 +759,13 @@ template <unsigned> struct __static_asse #define _LIBCPP_WCTYPE_IS_MASK #endif -#ifndef _LIBCPP_TRIVIAL_PAIR_COPY_CTOR -# if defined(__FreeBSD__) -// Making the std::pair copy constructor trivial breaks ABI compatibility with -// earlier versions of libc++ shipped by FreeBSD, so turn it off by default. -// See also http://svnweb.freebsd.org/changeset/base/261801 -# define _LIBCPP_TRIVIAL_PAIR_COPY_CTOR 0 -# else -# define _LIBCPP_TRIVIAL_PAIR_COPY_CTOR 1 -# endif -#endif - #ifndef _LIBCPP_STD_VER # if __cplusplus <= 201103L # define _LIBCPP_STD_VER 11 # elif __cplusplus <= 201402L # define _LIBCPP_STD_VER 14 # else -# define _LIBCPP_STD_VER 15 // current year, or date of c++17 ratification +# define _LIBCPP_STD_VER 16 // current year, or date of c++17 ratification # endif #endif // _LIBCPP_STD_VER @@ -770,6 +789,12 @@ template <unsigned> struct __static_asse #define _LIBCPP_CONSTEXPR_AFTER_CXX11 #endif +#if _LIBCPP_STD_VER > 14 && !defined(_LIBCPP_HAS_NO_CXX14_CONSTEXPR) +#define _LIBCPP_CONSTEXPR_AFTER_CXX14 constexpr +#else +#define _LIBCPP_CONSTEXPR_AFTER_CXX14 +#endif + #ifdef _LIBCPP_HAS_NO_RVALUE_REFERENCES # define _LIBCPP_EXPLICIT_MOVE(x) _VSTD::move(x) #else @@ -797,6 +822,25 @@ extern "C" void __sanitizer_annotate_con # define _LIBCPP_WEAK __attribute__((__weak__)) #endif +// Thread API +#if !defined(_LIBCPP_HAS_NO_THREADS) && !defined(_LIBCPP_HAS_THREAD_API_PTHREAD) +# if defined(__FreeBSD__) || \ + defined(__NetBSD__) || \ + defined(__linux__) || \ + defined(__APPLE__) || \ + defined(__CloudABI__) || \ + defined(__sun__) +# define _LIBCPP_HAS_THREAD_API_PTHREAD +# else +# error "No thread API" +# endif // _LIBCPP_HAS_THREAD_API +#endif // _LIBCPP_HAS_NO_THREADS + +#if defined(_LIBCPP_HAS_NO_THREADS) && defined(_LIBCPP_HAS_THREAD_API_PTHREAD) +# error _LIBCPP_HAS_THREAD_API_PTHREAD may only be defined when \ + _LIBCPP_HAS_NO_THREADS is not defined. +#endif + #if defined(_LIBCPP_HAS_NO_MONOTONIC_CLOCK) && !defined(_LIBCPP_HAS_NO_THREADS) # error _LIBCPP_HAS_NO_MONOTONIC_CLOCK may only be defined when \ _LIBCPP_HAS_NO_THREADS is defined. @@ -840,7 +884,20 @@ extern "C" void __sanitizer_annotate_con #ifndef _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK #define _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK -#endif +#endif + +#if __cplusplus < 201103L +#define _LIBCPP_CXX03_LANG +#else +#if defined(_LIBCPP_HAS_NO_VARIADIC_TEMPLATES) || defined(_LIBCPP_HAS_NO_RVALUE_REFERENCES) +#error Libc++ requires a feature complete C++11 compiler in C++11 or greater. +#endif +#endif + +#if (defined(_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS) && defined(__clang__) \ + && __has_attribute(acquire_capability)) +#define _LIBCPP_HAS_THREAD_SAFETY_ANNOTATIONS +#endif #endif // __cplusplus Modified: projects/clang390-import/contrib/libc++/include/__functional_base ============================================================================== --- projects/clang390-import/contrib/libc++/include/__functional_base Tue Aug 30 18:01:26 2016 (r305075) +++ projects/clang390-import/contrib/libc++/include/__functional_base Tue Aug 30 18:27:31 2016 (r305076) @@ -38,8 +38,6 @@ struct _LIBCPP_TYPE_VIS_ONLY binary_func typedef _Result result_type; }; -template <class _Tp> struct _LIBCPP_TYPE_VIS_ONLY hash; - template <class _Tp> struct __has_result_type { @@ -306,75 +304,19 @@ struct __weak_result_type<_Rp (_Cp::*)(_ #endif // _LIBCPP_HAS_NO_VARIADICS -// __invoke - -#ifndef _LIBCPP_HAS_NO_VARIADICS - -// bullets 1 and 2 - -template <class _Fp, class _A0, class ..._Args, - class> -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _A0&& __a0, _Args&& ...__args) - -> decltype((_VSTD::forward<_A0>(__a0).*__f)(_VSTD::forward<_Args>(__args)...)) -{ - return (_VSTD::forward<_A0>(__a0).*__f)(_VSTD::forward<_Args>(__args)...); -} - -template <class _Fp, class _A0, class ..._Args, - class> -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _A0&& __a0, _Args&& ...__args) - -> decltype(((*_VSTD::forward<_A0>(__a0)).*__f)(_VSTD::forward<_Args>(__args)...)) -{ - return ((*_VSTD::forward<_A0>(__a0)).*__f)(_VSTD::forward<_Args>(__args)...); -} - -// bullets 3 and 4 +#ifndef _LIBCPP_CXX03_LANG -template <class _Fp, class _A0, - class> -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _A0&& __a0) - -> decltype(_VSTD::forward<_A0>(__a0).*__f) -{ - return _VSTD::forward<_A0>(__a0).*__f; -} - -template <class _Fp, class _A0, - class> -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _A0&& __a0) - -> decltype((*_VSTD::forward<_A0>(__a0)).*__f) -{ - return (*_VSTD::forward<_A0>(__a0)).*__f; -} - -// bullet 5 - -template <class _Fp, class ..._Args> -inline _LIBCPP_INLINE_VISIBILITY -auto -__invoke(_Fp&& __f, _Args&& ...__args) - -> decltype(_VSTD::forward<_Fp>(__f)(_VSTD::forward<_Args>(__args)...)) -{ - return _VSTD::forward<_Fp>(__f)(_VSTD::forward<_Args>(__args)...); -} template <class _Tp, class ..._Args> struct __invoke_return { typedef decltype(__invoke(_VSTD::declval<_Tp>(), _VSTD::declval<_Args>()...)) type; }; -#else // _LIBCPP_HAS_NO_VARIADICS +#else // defined(_LIBCPP_CXX03_LANG) #include <__functional_base_03> -#endif // _LIBCPP_HAS_NO_VARIADICS +#endif // !defined(_LIBCPP_CXX03_LANG) template <class _Ret> @@ -577,10 +519,6 @@ public: #endif // _LIBCPP_HAS_NO_VARIADICS }; -template <class _Tp> struct __is_reference_wrapper_impl : public false_type {}; -template <class _Tp> struct __is_reference_wrapper_impl<reference_wrapper<_Tp> > : public true_type {}; -template <class _Tp> struct __is_reference_wrapper - : public __is_reference_wrapper_impl<typename remove_cv<_Tp>::type> {}; template <class _Tp> inline _LIBCPP_INLINE_VISIBILITY Modified: projects/clang390-import/contrib/libc++/include/__hash_table ============================================================================== --- projects/clang390-import/contrib/libc++/include/__hash_table Tue Aug 30 18:01:26 2016 (r305075) +++ projects/clang390-import/contrib/libc++/include/__hash_table Tue Aug 30 18:27:31 2016 (r305076) @@ -17,6 +17,7 @@ #include <iterator> #include <algorithm> #include <cmath> +#include <utility> #include <__undef_min_max> #include <__undef___deallocate> @@ -29,6 +30,29 @@ _LIBCPP_BEGIN_NAMESPACE_STD + +#ifndef _LIBCPP_CXX03_LANG +template <class _Key, class _Tp> +union __hash_value_type; +#else +template <class _Key, class _Tp> +struct __hash_value_type; +#endif + +#ifndef _LIBCPP_CXX03_LANG +template <class _Tp> +struct __is_hash_value_type_imp : false_type {}; + +template <class _Key, class _Value> +struct __is_hash_value_type_imp<__hash_value_type<_Key, _Value>> : true_type {}; + +template <class ..._Args> +struct __is_hash_value_type : false_type {}; + +template <class _One> +struct __is_hash_value_type<_One> : __is_hash_value_type_imp<typename __uncvref<_One>::type> {}; +#endif + _LIBCPP_FUNC_VIS size_t __next_prime(size_t __n); @@ -49,10 +73,10 @@ struct __hash_node typename __rebind_pointer<_VoidPtr, __hash_node<_Tp, _VoidPtr> >::type > { - typedef _Tp value_type; + typedef _Tp __node_value_type; size_t __hash_; - value_type __value_; + __node_value_type __value_; }; inline _LIBCPP_INLINE_VISIBILITY @@ -66,7 +90,8 @@ inline _LIBCPP_INLINE_VISIBILITY size_t __constrain_hash(size_t __h, size_t __bc) { - return !(__bc & (__bc - 1)) ? __h & (__bc - 1) : __h % __bc; + return !(__bc & (__bc - 1)) ? __h & (__bc - 1) : + (__h < __bc ? __h : __h % __bc); } inline _LIBCPP_INLINE_VISIBILITY @@ -76,24 +101,173 @@ __next_hash_pow2(size_t __n) return size_t(1) << (std::numeric_limits<size_t>::digits - __clz(__n-1)); } + template <class _Tp, class _Hash, class _Equal, class _Alloc> class __hash_table; + +template <class _NodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_iterator; template <class _ConstNodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_const_iterator; +template <class _NodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_local_iterator; +template <class _ConstNodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_const_local_iterator; template <class _HashIterator> class _LIBCPP_TYPE_VIS_ONLY __hash_map_iterator; template <class _HashIterator> class _LIBCPP_TYPE_VIS_ONLY __hash_map_const_iterator; +template <class _Tp> +struct __hash_key_value_types { + static_assert(!is_reference<_Tp>::value && !is_const<_Tp>::value, ""); + typedef _Tp key_type; + typedef _Tp __node_value_type; + typedef _Tp __container_value_type; + static const bool __is_map = false; + + _LIBCPP_INLINE_VISIBILITY + static key_type const& __get_key(_Tp const& __v) { + return __v; + } + _LIBCPP_INLINE_VISIBILITY + static __container_value_type const& __get_value(__node_value_type const& __v) { + return __v; + } + _LIBCPP_INLINE_VISIBILITY + static __container_value_type* __get_ptr(__node_value_type& __n) { + return _VSTD::addressof(__n); + } +#ifndef _LIBCPP_CXX03_LANG + _LIBCPP_INLINE_VISIBILITY + static __container_value_type&& __move(__node_value_type& __v) { + return _VSTD::move(__v); + } +#endif +}; + +template <class _Key, class _Tp> +struct __hash_key_value_types<__hash_value_type<_Key, _Tp> > { + typedef _Key key_type; + typedef _Tp mapped_type; + typedef __hash_value_type<_Key, _Tp> __node_value_type; + typedef pair<const _Key, _Tp> __container_value_type; + typedef pair<_Key, _Tp> __nc_value_type; + typedef __container_value_type __map_value_type; + static const bool __is_map = true; + + _LIBCPP_INLINE_VISIBILITY + static key_type const& __get_key(__container_value_type const& __v) { + return __v.first; + } + + template <class _Up> + _LIBCPP_INLINE_VISIBILITY + static typename enable_if<__is_same_uncvref<_Up, __node_value_type>::value, + __container_value_type const&>::type + __get_value(_Up& __t) { + return __t.__cc; + } + + template <class _Up> + _LIBCPP_INLINE_VISIBILITY + static typename enable_if<__is_same_uncvref<_Up, __container_value_type>::value, + __container_value_type const&>::type + __get_value(_Up& __t) { + return __t; + } + + _LIBCPP_INLINE_VISIBILITY + static __container_value_type* __get_ptr(__node_value_type& __n) { + return _VSTD::addressof(__n.__cc); + } +#ifndef _LIBCPP_CXX03_LANG + _LIBCPP_INLINE_VISIBILITY + static __nc_value_type&& __move(__node_value_type& __v) { + return _VSTD::move(__v.__nc); + } +#endif + +}; + +template <class _Tp, class _AllocPtr, class _KVTypes = __hash_key_value_types<_Tp>, + bool = _KVTypes::__is_map> +struct __hash_map_pointer_types {}; + +template <class _Tp, class _AllocPtr, class _KVTypes> +struct __hash_map_pointer_types<_Tp, _AllocPtr, _KVTypes, true> { + typedef typename _KVTypes::__map_value_type _Mv; + typedef typename __rebind_pointer<_AllocPtr, _Mv>::type + __map_value_type_pointer; + typedef typename __rebind_pointer<_AllocPtr, const _Mv>::type + __const_map_value_type_pointer; +}; + +template <class _NodePtr, class _NodeT = typename pointer_traits<_NodePtr>::element_type> +struct __hash_node_types; + +template <class _NodePtr, class _Tp, class _VoidPtr> +struct __hash_node_types<_NodePtr, __hash_node<_Tp, _VoidPtr> > + : public __hash_key_value_types<_Tp>, __hash_map_pointer_types<_Tp, _VoidPtr> + +{ + typedef __hash_key_value_types<_Tp> __base; + +public: + typedef ptrdiff_t difference_type; + typedef size_t size_type; + + typedef typename __rebind_pointer<_NodePtr, void>::type __void_pointer; + + typedef typename pointer_traits<_NodePtr>::element_type __node_type; + typedef _NodePtr __node_pointer; + + typedef __hash_node_base<__node_pointer> __node_base_type; + typedef typename __rebind_pointer<_NodePtr, __node_base_type>::type + __node_base_pointer; + + typedef _Tp __node_value_type; + typedef typename __rebind_pointer<_VoidPtr, __node_value_type>::type + __node_value_type_pointer; + typedef typename __rebind_pointer<_VoidPtr, const __node_value_type>::type + __const_node_value_type_pointer; +private: + static_assert(!is_const<__node_type>::value, + "_NodePtr should never be a pointer to const"); + static_assert((is_same<typename pointer_traits<_VoidPtr>::element_type, void>::value), + "_VoidPtr does not point to unqualified void type"); + static_assert((is_same<typename __rebind_pointer<_VoidPtr, __node_type>::type, + _NodePtr>::value), "_VoidPtr does not rebind to _NodePtr."); +}; + + + +template <class _HashIterator> +struct __hash_node_types_from_iterator; +template <class _NodePtr> +struct __hash_node_types_from_iterator<__hash_iterator<_NodePtr> > : __hash_node_types<_NodePtr> {}; +template <class _NodePtr> +struct __hash_node_types_from_iterator<__hash_const_iterator<_NodePtr> > : __hash_node_types<_NodePtr> {}; +template <class _NodePtr> +struct __hash_node_types_from_iterator<__hash_local_iterator<_NodePtr> > : __hash_node_types<_NodePtr> {}; +template <class _NodePtr> +struct __hash_node_types_from_iterator<__hash_const_local_iterator<_NodePtr> > : __hash_node_types<_NodePtr> {}; + + +template <class _NodeValueTp, class _VoidPtr> +struct __make_hash_node_types { + typedef __hash_node<_NodeValueTp, _VoidPtr> _NodeTp; + typedef typename __rebind_pointer<_VoidPtr, _NodeTp>::type _NodePtr; + typedef __hash_node_types<_NodePtr> type; +}; + template <class _NodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_iterator { - typedef _NodePtr __node_pointer; + typedef __hash_node_types<_NodePtr> _NodeTypes; + typedef _NodePtr __node_pointer; __node_pointer __node_; public: - typedef forward_iterator_tag iterator_category; - typedef typename pointer_traits<__node_pointer>::element_type::value_type value_type; - typedef typename pointer_traits<__node_pointer>::difference_type difference_type; - typedef value_type& reference; - typedef typename __rebind_pointer<__node_pointer, value_type>::type pointer; + typedef forward_iterator_tag iterator_category; + typedef typename _NodeTypes::__node_value_type value_type; + typedef typename _NodeTypes::difference_type difference_type; + typedef value_type& reference; + typedef typename _NodeTypes::__node_value_type_pointer pointer; _LIBCPP_INLINE_VISIBILITY __hash_iterator() _NOEXCEPT #if _LIBCPP_STD_VER > 11 @@ -202,25 +376,24 @@ private: template <class, class, class, class, class> friend class _LIBCPP_TYPE_VIS_ONLY unordered_multimap; }; -template <class _ConstNodePtr> +template <class _NodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_const_iterator { - typedef _ConstNodePtr __node_pointer; - - __node_pointer __node_; + static_assert(!is_const<typename pointer_traits<_NodePtr>::element_type>::value, ""); + typedef __hash_node_types<_NodePtr> _NodeTypes; + typedef _NodePtr __node_pointer; - typedef typename remove_const< - typename pointer_traits<__node_pointer>::element_type - >::type __node; + __node_pointer __node_; public: - typedef forward_iterator_tag iterator_category; - typedef typename __node::value_type value_type; - typedef typename pointer_traits<__node_pointer>::difference_type difference_type; - typedef const value_type& reference; - typedef typename __rebind_pointer<__node_pointer, const value_type>::type pointer; - typedef typename __rebind_pointer<__node_pointer, __node>::type __non_const_node_pointer; - typedef __hash_iterator<__non_const_node_pointer> __non_const_iterator; + typedef __hash_iterator<_NodePtr> __non_const_iterator; + + typedef forward_iterator_tag iterator_category; + typedef typename _NodeTypes::__node_value_type value_type; + typedef typename _NodeTypes::difference_type difference_type; + typedef const value_type& reference; + typedef typename _NodeTypes::__const_node_value_type_pointer pointer; + _LIBCPP_INLINE_VISIBILITY __hash_const_iterator() _NOEXCEPT #if _LIBCPP_STD_VER > 11 @@ -336,24 +509,22 @@ private: template <class, class, class, class, class> friend class _LIBCPP_TYPE_VIS_ONLY unordered_multimap; }; -template <class _ConstNodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_const_local_iterator; - template <class _NodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_local_iterator { - typedef _NodePtr __node_pointer; + typedef __hash_node_types<_NodePtr> _NodeTypes; + typedef _NodePtr __node_pointer; __node_pointer __node_; size_t __bucket_; size_t __bucket_count_; - typedef pointer_traits<__node_pointer> __pointer_traits; public: typedef forward_iterator_tag iterator_category; - typedef typename __pointer_traits::element_type::value_type value_type; - typedef typename __pointer_traits::difference_type difference_type; + typedef typename _NodeTypes::__node_value_type value_type; + typedef typename _NodeTypes::difference_type difference_type; typedef value_type& reference; - typedef typename __rebind_pointer<__node_pointer, value_type>::type pointer; + typedef typename _NodeTypes::__node_value_type_pointer pointer; _LIBCPP_INLINE_VISIBILITY __hash_local_iterator() _NOEXCEPT { @@ -476,7 +647,8 @@ private: template <class _ConstNodePtr> class _LIBCPP_TYPE_VIS_ONLY __hash_const_local_iterator { - typedef _ConstNodePtr __node_pointer; + typedef __hash_node_types<_ConstNodePtr> _NodeTypes; + typedef _ConstNodePtr __node_pointer; __node_pointer __node_; size_t __bucket_; @@ -487,18 +659,15 @@ class _LIBCPP_TYPE_VIS_ONLY __hash_const typedef typename remove_const<__node>::type __non_const_node; typedef typename __rebind_pointer<__node_pointer, __non_const_node>::type __non_const_node_pointer; - +public: typedef __hash_local_iterator<__non_const_node_pointer> __non_const_iterator; -public: - typedef forward_iterator_tag iterator_category; - typedef typename remove_const< - typename __pointer_traits::element_type::value_type - >::type value_type; - typedef typename __pointer_traits::difference_type difference_type; - typedef const value_type& reference; - typedef typename __rebind_pointer<__node_pointer, const value_type>::type - pointer; + + typedef forward_iterator_tag iterator_category; + typedef typename _NodeTypes::__node_value_type value_type; + typedef typename _NodeTypes::difference_type difference_type; + typedef const value_type& reference; + typedef typename _NodeTypes::__const_node_value_type_pointer pointer; _LIBCPP_INLINE_VISIBILITY __hash_const_local_iterator() _NOEXCEPT @@ -686,10 +855,11 @@ class __hash_node_destructor { typedef _Alloc allocator_type; typedef allocator_traits<allocator_type> __alloc_traits; - typedef typename __alloc_traits::value_type::value_type value_type; + public: typedef typename __alloc_traits::pointer pointer; private: + typedef __hash_node_types<pointer> _NodeTypes; allocator_type& __na_; @@ -709,7 +879,7 @@ public: void operator()(pointer __p) _NOEXCEPT { if (__value_constructed) - __alloc_traits::destroy(__na_, _VSTD::addressof(__p->__value_)); + __alloc_traits::destroy(__na_, _NodeTypes::__get_ptr(__p->__value_)); if (__p) __alloc_traits::deallocate(__na_, __p, 1); } @@ -728,23 +898,47 @@ public: private: typedef allocator_traits<allocator_type> __alloc_traits; + typedef typename + __make_hash_node_types<value_type, typename __alloc_traits::void_pointer>::type + _NodeTypes; public: + + typedef typename _NodeTypes::__node_value_type __node_value_type; + typedef typename _NodeTypes::__container_value_type __container_value_type; + typedef typename _NodeTypes::key_type key_type; typedef value_type& reference; typedef const value_type& const_reference; typedef typename __alloc_traits::pointer pointer; typedef typename __alloc_traits::const_pointer const_pointer; +#ifndef _LIBCPP_ABI_FIX_UNORDERED_CONTAINER_SIZE_TYPE typedef typename __alloc_traits::size_type size_type; - typedef typename __alloc_traits::difference_type difference_type; +#else + typedef typename _NodeTypes::size_type size_type; +#endif + typedef typename _NodeTypes::difference_type difference_type; public: // Create __node - typedef __hash_node<value_type, typename __alloc_traits::void_pointer> __node; + + typedef typename _NodeTypes::__node_type __node; typedef typename __rebind_alloc_helper<__alloc_traits, __node>::type __node_allocator; typedef allocator_traits<__node_allocator> __node_traits; - typedef typename __node_traits::pointer __node_pointer; - typedef typename __node_traits::pointer __node_const_pointer; - typedef __hash_node_base<__node_pointer> __first_node; - typedef typename __rebind_pointer<__node_pointer, __first_node>::type - __node_base_pointer; + typedef typename _NodeTypes::__void_pointer __void_pointer; + typedef typename _NodeTypes::__node_pointer __node_pointer; + typedef typename _NodeTypes::__node_pointer __node_const_pointer; + typedef typename _NodeTypes::__node_base_type __first_node; + typedef typename _NodeTypes::__node_base_pointer __node_base_pointer; + +private: + // check for sane allocator pointer rebinding semantics. Rebinding the + // allocator for a new pointer type should be exactly the same as rebinding + // the pointer using 'pointer_traits'. + static_assert((is_same<__node_pointer, typename __node_traits::pointer>::value), + "Allocator does not rebind pointers in a sane manner."); + typedef typename __rebind_alloc_helper<__node_traits, __first_node>::type + __node_base_allocator; + typedef allocator_traits<__node_base_allocator> __node_base_traits; + static_assert((is_same<__node_base_pointer, typename __node_base_traits::pointer>::value), + "Allocator does not rebind pointers in a sane manner."); private: @@ -755,10 +949,10 @@ private: typedef typename __bucket_list_deleter::pointer __node_pointer_pointer; // --- Member data begin --- - __bucket_list __bucket_list_; - __compressed_pair<__first_node, __node_allocator> __p1_; - __compressed_pair<size_type, hasher> __p2_; - __compressed_pair<float, key_equal> __p3_; + __bucket_list __bucket_list_; + __compressed_pair<__first_node, __node_allocator> __p1_; + __compressed_pair<size_type, hasher> __p2_; + __compressed_pair<float, key_equal> __p3_; // --- Member data end --- _LIBCPP_INLINE_VISIBILITY @@ -809,7 +1003,7 @@ public: explicit __hash_table(const allocator_type& __a); __hash_table(const __hash_table& __u); __hash_table(const __hash_table& __u, const allocator_type& __a); *** DIFF OUTPUT TRUNCATED AT 1000 LINES ***
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201608301827.u7UIRV2V097991>