ff27340046
The macro definitions in <version> should depend on the same preprocessor conditions as the original macros in other headers. Otherwise <version> can define macros that imply the availability of features that are not actually defined. This fix is incomplete, as __cpp_lib_filesystem should depend on whether libstdc++fs.a is supported, and several macros should only be defined when _GLIBCXX_HOSTED is defined. Also, the feature test macros should define their value as type long, but most are type int. * include/bits/c++config (_GLIBCXX_HAVE_BUILTIN_HAS_UNIQ_OBJ_REP) (_GLIBCXX_HAVE_BUILTIN_IS_AGGREGATE): Move definitions here. (_GLIBCXX_HAVE_BUILTIN_LAUNDER): Likewise. Use !__is_identifier instead of __has_builtin. * include/std/type_traits (_GLIBCXX_HAVE_BUILTIN_HAS_UNIQ_OBJ_REP) (_GLIBCXX_HAVE_BUILTIN_IS_AGGREGATE): Remove definitions from here. * include/std/version [!_GLIBCXX_HAS_GTHREADS] (__cpp_lib_shared_timed_mutex, __cpp_lib_scoped_lock) (__cpp_lib_shared_mutex): Don't define when Gthreads not in use. [!_GLIBCXX_HAVE_BUILTIN_HAS_UNIQ_OBJ_REP] (__cpp_lib_has_unique_object_representations): Don't define when builtin not available. [!_GLIBCXX_HAVE_BUILTIN_IS_AGGREGATE] (__cpp_lib_is_aggregate): Likewise. [!_GLIBCXX_HAVE_BUILTIN_LAUNDER] (__cpp_lib_launder): Likewise. * libsupc++/new (_GLIBCXX_HAVE_BUILTIN_LAUNDER): Remove definition from here. From-SVN: r263184 |
||
---|---|---|
.. | ||
array_type_info.cc | ||
atexit_arm.cc | ||
atexit_thread.cc | ||
atomic_lockfree_defines.h | ||
bad_alloc.cc | ||
bad_array_length.cc | ||
bad_array_new.cc | ||
bad_cast.cc | ||
bad_typeid.cc | ||
class_type_info.cc | ||
cxxabi_forced.h | ||
cxxabi_init_exception.h | ||
cxxabi.h | ||
del_op.cc | ||
del_opa.cc | ||
del_opant.cc | ||
del_opnt.cc | ||
del_ops.cc | ||
del_opsa.cc | ||
del_opv.cc | ||
del_opva.cc | ||
del_opvant.cc | ||
del_opvnt.cc | ||
del_opvs.cc | ||
del_opvsa.cc | ||
dyncast.cc | ||
eh_alloc.cc | ||
eh_arm.cc | ||
eh_atomics.h | ||
eh_aux_runtime.cc | ||
eh_call.cc | ||
eh_catch.cc | ||
eh_exception.cc | ||
eh_globals.cc | ||
eh_personality.cc | ||
eh_ptr.cc | ||
eh_term_handler.cc | ||
eh_terminate.cc | ||
eh_throw.cc | ||
eh_tm.cc | ||
eh_type.cc | ||
eh_unex_handler.cc | ||
enum_type_info.cc | ||
exception | ||
exception_defines.h | ||
exception_ptr.h | ||
exception.h | ||
function_type_info.cc | ||
fundamental_type_info.cc | ||
guard_error.cc | ||
guard.cc | ||
hash_bytes.cc | ||
hash_bytes.h | ||
initializer_list | ||
Makefile.am | ||
Makefile.in | ||
nested_exception.cc | ||
nested_exception.h | ||
new | ||
new_handler.cc | ||
new_op.cc | ||
new_opa.cc | ||
new_opant.cc | ||
new_opnt.cc | ||
new_opv.cc | ||
new_opva.cc | ||
new_opvant.cc | ||
new_opvnt.cc | ||
pbase_type_info.cc | ||
pmem_type_info.cc | ||
pointer_type_info.cc | ||
pure.cc | ||
si_class_type_info.cc | ||
tinfo2.cc | ||
tinfo.cc | ||
tinfo.h | ||
typeinfo | ||
unwind-cxx.h | ||
vec.cc | ||
vmi_class_type_info.cc | ||
vterminate.cc | ||
vtv_stubs.cc |