Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:30:07

0001 //  (C) Copyright Christopher Jefferson 2011.
0002 //  Use, modification and distribution are subject to the
0003 //  Boost Software License, Version 1.0. (See accompanying file
0004 //  LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
0005 
0006 //  See http://www.boost.org for most recent version.
0007 
0008 //  config for libc++
0009 //  Might need more in here later.
0010 
0011 #if !defined(_LIBCPP_VERSION)
0012 #  include <ciso646>
0013 #  if !defined(_LIBCPP_VERSION)
0014 #      error "This is not libc++!"
0015 #  endif
0016 #endif
0017 
0018 #define BOOST_STDLIB "libc++ version " BOOST_STRINGIZE(_LIBCPP_VERSION)
0019 
0020 #define BOOST_HAS_THREADS
0021 
0022 #ifdef _LIBCPP_HAS_NO_VARIADICS
0023 #    define BOOST_NO_CXX11_HDR_TUPLE
0024 #endif
0025 
0026 // BOOST_NO_CXX11_ALLOCATOR should imply no support for the C++11
0027 // allocator model. The C++11 allocator model requires a conforming
0028 // std::allocator_traits which is only possible with C++11 template
0029 // aliases since members rebind_alloc and rebind_traits require it.
0030 #if defined(_LIBCPP_HAS_NO_TEMPLATE_ALIASES)
0031 #    define BOOST_NO_CXX11_ALLOCATOR
0032 #    define BOOST_NO_CXX11_POINTER_TRAITS
0033 #endif
0034 
0035 #if __cplusplus < 201103
0036 //
0037 // These two appear to be somewhat useable in C++03 mode, there may be others...
0038 //
0039 //#  define BOOST_NO_CXX11_HDR_ARRAY
0040 //#  define BOOST_NO_CXX11_HDR_FORWARD_LIST
0041 
0042 #  define BOOST_NO_CXX11_HDR_CODECVT
0043 #  define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE
0044 #  define BOOST_NO_CXX11_HDR_EXCEPTION
0045 #  define BOOST_NO_CXX11_HDR_INITIALIZER_LIST
0046 #  define BOOST_NO_CXX11_HDR_MUTEX
0047 #  define BOOST_NO_CXX11_HDR_RANDOM
0048 #  define BOOST_NO_CXX11_HDR_RATIO
0049 #  define BOOST_NO_CXX11_HDR_REGEX
0050 #  define BOOST_NO_CXX11_HDR_SYSTEM_ERROR
0051 #  define BOOST_NO_CXX11_HDR_THREAD
0052 #  define BOOST_NO_CXX11_HDR_TUPLE
0053 #  define BOOST_NO_CXX11_HDR_TYPEINDEX
0054 #  define BOOST_NO_CXX11_HDR_UNORDERED_MAP
0055 #  define BOOST_NO_CXX11_HDR_UNORDERED_SET
0056 #  define BOOST_NO_CXX11_NUMERIC_LIMITS
0057 #  define BOOST_NO_CXX11_ALLOCATOR
0058 #  define BOOST_NO_CXX11_POINTER_TRAITS
0059 #  define BOOST_NO_CXX11_SMART_PTR
0060 #  define BOOST_NO_CXX11_HDR_FUNCTIONAL
0061 #  define BOOST_NO_CXX11_STD_ALIGN
0062 #  define BOOST_NO_CXX11_ADDRESSOF
0063 #  define BOOST_NO_CXX11_HDR_ATOMIC
0064 #  define BOOST_NO_CXX11_ATOMIC_SMART_PTR
0065 #  define BOOST_NO_CXX11_HDR_CHRONO
0066 #  define BOOST_NO_CXX11_HDR_TYPE_TRAITS
0067 #  define BOOST_NO_CXX11_HDR_FUTURE
0068 #elif _LIBCPP_VERSION < 3700
0069 //
0070 // These appear to be unusable/incomplete so far:
0071 //
0072 #  define BOOST_NO_CXX11_HDR_ATOMIC
0073 #  define BOOST_NO_CXX11_ATOMIC_SMART_PTR
0074 #  define BOOST_NO_CXX11_HDR_CHRONO
0075 #  define BOOST_NO_CXX11_HDR_TYPE_TRAITS
0076 #  define BOOST_NO_CXX11_HDR_FUTURE
0077 #endif
0078 
0079 
0080 #if _LIBCPP_VERSION < 3700
0081 // libc++ uses a non-standard messages_base
0082 #define BOOST_NO_STD_MESSAGES
0083 #endif
0084 
0085 // C++14 features
0086 #if (_LIBCPP_VERSION < 3700) || (__cplusplus <= 201402L)
0087 #  define BOOST_NO_CXX14_STD_EXCHANGE
0088 #endif
0089 
0090 // C++17 features
0091 #if (_LIBCPP_VERSION < 4000) || (__cplusplus <= 201402L)
0092 #  define BOOST_NO_CXX17_STD_APPLY
0093 #  define BOOST_NO_CXX17_HDR_OPTIONAL
0094 #  define BOOST_NO_CXX17_HDR_STRING_VIEW
0095 #  define BOOST_NO_CXX17_HDR_VARIANT
0096 #endif
0097 #if (_LIBCPP_VERSION > 4000) && (__cplusplus > 201402L) && !defined(_LIBCPP_ENABLE_CXX17_REMOVED_AUTO_PTR)
0098 #  define BOOST_NO_AUTO_PTR
0099 #endif
0100 #if (_LIBCPP_VERSION > 4000) && (__cplusplus > 201402L) && !defined(_LIBCPP_ENABLE_CXX17_REMOVED_RANDOM_SHUFFLE)
0101 #  define BOOST_NO_CXX98_RANDOM_SHUFFLE
0102 #endif
0103 #if (_LIBCPP_VERSION > 4000) && (__cplusplus > 201402L) && !defined(_LIBCPP_ENABLE_CXX17_REMOVED_BINDERS)
0104 #  define BOOST_NO_CXX98_BINDERS
0105 #endif
0106 
0107 #if defined(__cplusplus) && defined(__has_include)
0108 #if __has_include(<version>)
0109 #include <version>
0110 
0111 #if !defined(__cpp_lib_execution) || (__cpp_lib_execution < 201603L)
0112 #  define BOOST_NO_CXX17_HDR_EXECUTION
0113 #endif
0114 #if !defined(__cpp_lib_invoke) || (__cpp_lib_invoke < 201411L)
0115 #define BOOST_NO_CXX17_STD_INVOKE
0116 #endif
0117 
0118 #if(_LIBCPP_VERSION < 9000)
0119 // as_writable_bytes is missing.
0120 #  define BOOST_NO_CXX20_HDR_SPAN
0121 #endif
0122 
0123 #else
0124 #define BOOST_NO_CXX17_STD_INVOKE      // Invoke support is incomplete (no invoke_result)
0125 #define BOOST_NO_CXX17_HDR_EXECUTION
0126 #endif
0127 #else
0128 #define BOOST_NO_CXX17_STD_INVOKE      // Invoke support is incomplete (no invoke_result)
0129 #define BOOST_NO_CXX17_HDR_EXECUTION
0130 #endif
0131 
0132 #if _LIBCPP_VERSION < 10000  // What's the correct version check here?
0133 #define BOOST_NO_CXX17_ITERATOR_TRAITS
0134 #endif
0135 
0136 #if (_LIBCPP_VERSION <= 1101) && !defined(BOOST_NO_CXX11_THREAD_LOCAL)
0137 // This is a bit of a sledgehammer, because really it's just libc++abi that has no
0138 // support for thread_local, leading to linker errors such as
0139 // "undefined reference to `__cxa_thread_atexit'".  It is fixed in the
0140 // most recent releases of libc++abi though...
0141 #  define BOOST_NO_CXX11_THREAD_LOCAL
0142 #endif
0143 
0144 #if defined(__linux__) && (_LIBCPP_VERSION < 6000) && !defined(BOOST_NO_CXX11_THREAD_LOCAL)
0145 // After libc++-dev is installed on Trusty, clang++-libc++ almost works,
0146 // except uses of `thread_local` fail with undefined reference to
0147 // `__cxa_thread_atexit`.
0148 //
0149 // clang's libc++abi provides an implementation by deferring to the glibc
0150 // implementation, which may or may not be available (it is not on Trusty).
0151 // clang 4's libc++abi will provide an implementation if one is not in glibc
0152 // though, so thread local support should work with clang 4 and above as long
0153 // as libc++abi is linked in.
0154 #  define BOOST_NO_CXX11_THREAD_LOCAL
0155 #endif
0156 
0157 #if defined(__has_include)
0158 #if !__has_include(<shared_mutex>)
0159 #  define BOOST_NO_CXX14_HDR_SHARED_MUTEX
0160 #elif __cplusplus <= 201103
0161 #  define BOOST_NO_CXX14_HDR_SHARED_MUTEX
0162 #endif
0163 #elif __cplusplus < 201402
0164 #  define BOOST_NO_CXX14_HDR_SHARED_MUTEX
0165 #endif
0166 
0167 #if !defined(BOOST_NO_CXX14_HDR_SHARED_MUTEX) && (_LIBCPP_VERSION < 5000)
0168 #  define BOOST_NO_CXX14_HDR_SHARED_MUTEX
0169 #endif
0170 
0171 #if _LIBCPP_VERSION >= 15000
0172 //
0173 // Unary function is now deprecated in C++11 and later:
0174 //
0175 #if __cplusplus >= 201103L
0176 #define BOOST_NO_CXX98_FUNCTION_BASE
0177 #endif
0178 #endif
0179 
0180 //  --- end ---