diff --git a/doc/has_virtual_destructor.qbk b/doc/has_virtual_destructor.qbk index 5bc3e65..d7fb8bf 100644 --- a/doc/has_virtual_destructor.qbk +++ b/doc/has_virtual_destructor.qbk @@ -12,14 +12,13 @@ __inherit If T is a (possibly cv-qualified) type with a virtual destructor then inherits from __true_type, otherwise inherits from __false_type. -__compat This trait is provided for completeness, since it's part of the -Technical Report on C++ Library Extensions. However, there is currently no -way to portably implement this trait. The default version provided +__compat There is currently no +way to portably implement this trait: the default version always inherits from __false_type, and has to be explicitly specialized for types with virtual destructors unless the compiler used has compiler __intrinsics that enable the trait to do the right thing: -Currently (May 2011) compilers more recent than Visual C++ 8, GCC-4.3, Greenhills 6.0, -Intel-11.0, and Codegear have the necessary compiler __intrinsics to ensure that this +Currently (June 2015) compilers more recent than Visual C++ 8, GCC-4.3, Greenhills 6.0, +Intel-11.0, plus Codegear and Clang have the necessary compiler __intrinsics to ensure that this trait "just works". You may also test to see if the necessary __intrinsics are available by checking to see if the macro `BOOST_HAS_VIRTUAL_DESTRUCTOR` is defined. diff --git a/doc/integral_constant.qbk b/doc/integral_constant.qbk index 58403cf..663ff08 100644 --- a/doc/integral_constant.qbk +++ b/doc/integral_constant.qbk @@ -12,6 +12,7 @@ typedef integral_constant type; typedef T value_type; static const T value = val; + constexpr operator T()const; }; typedef integral_constant true_type; diff --git a/doc/is_array.qbk b/doc/is_array.qbk index be384f3..c8a4543 100644 --- a/doc/is_array.qbk +++ b/doc/is_array.qbk @@ -16,9 +16,7 @@ __std_ref 3.9.2 and 8.3.4. __header ` #include ` or ` #include ` -__compat If the compiler does not support -partial-specialization of class templates, then this template -can give the wrong result with function types. +[all_compilers] __examples diff --git a/doc/is_base_of.qbk b/doc/is_base_of.qbk index 78712b3..c65eb9a 100644 --- a/doc/is_base_of.qbk +++ b/doc/is_base_of.qbk @@ -28,11 +28,7 @@ __std_ref 10. __header ` #include ` or ` #include ` -__compat If the compiler does not support partial-specialization of class templates, -then this template can not be used with function types. There are some older compilers -which will produce compiler errors if `Base` is a private base class of `Derived`, or if -`Base` is an ambiguous base of `Derived`. These compilers include Borland C++, older -versions of Sun Forte C++, Digital Mars C++, and older versions of EDG based compilers. +[all_compilers] __examples diff --git a/doc/is_class.qbk b/doc/is_class.qbk index 1e7879e..f5d56cb 100644 --- a/doc/is_class.qbk +++ b/doc/is_class.qbk @@ -16,13 +16,9 @@ __std_ref 3.9.2 and 9.2. __header ` #include ` or ` #include ` -__compat Without (some as yet unspecified) help from the compiler, -we cannot distinguish between union and class types, as a result this type -will erroneously inherit from __true_type for union types. See also __is_union. -Currently (May 2011) compilers more recent than Visual C++ 8, GCC-4.3, Greenhills 6.0, -Intel-11.0, and Codegear have the necessary compiler __intrinsics to ensure that this -trait "just works". You may also test to see if the necessary __intrinsics are available -by checking to see if the macro `BOOST_IS_CLASS` is defined. +__compat This trait works correctly for almost all current compilers (as of June 2015), with just a minority +of older compilers not correctly detecting all the corner cases. You can check the macro `BOOST_TT_HAS_CONFORMING_IS_CLASS_IMPLEMENTATION` +which is defined to 1 when the class works correctly in all cases. __examples diff --git a/doc/is_complex.qbk b/doc/is_complex.qbk index 0c4f981..5646910 100644 --- a/doc/is_complex.qbk +++ b/doc/is_complex.qbk @@ -15,6 +15,8 @@ some type `U`), otherwise false. __std_ref 26.2. +[all_compilers] + __header ` #include ` or ` #include ` [endsect] diff --git a/doc/is_compound.qbk b/doc/is_compound.qbk index 392efd5..80e9f27 100644 --- a/doc/is_compound.qbk +++ b/doc/is_compound.qbk @@ -15,6 +15,8 @@ a compound type (see also __is_fundamental). __std_ref 3.9.2. +[all_compilers] + __header ` #include ` or ` #include ` __examples diff --git a/doc/is_const.qbk b/doc/is_const.qbk index ed3acaa..5853274 100644 --- a/doc/is_const.qbk +++ b/doc/is_const.qbk @@ -17,6 +17,8 @@ __std_ref 3.9.3. __header ` #include ` or ` #include ` +[all_compilers] + __examples [:`is_const` inherits from `__true_type`.] diff --git a/doc/is_convertible.qbk b/doc/is_convertible.qbk index cbaf2fb..63305cb 100644 --- a/doc/is_convertible.qbk +++ b/doc/is_convertible.qbk @@ -35,10 +35,7 @@ for example: __std_ref 4 and 8.5. -__compat This template is currently broken with Borland C++ Builder 5 (and earlier), -for constructor-based conversions, and for the Metrowerks 7 (and earlier) -compiler in all cases. If the compiler does not support `__is_abstract`, then the -template parameter `To` must not be an abstract type. +[all_compilers] __header ` #include ` or ` #include ` diff --git a/doc/is_copy_assignable.qbk b/doc/is_copy_assignable.qbk index e1de31a..5555441 100644 --- a/doc/is_copy_assignable.qbk +++ b/doc/is_copy_assignable.qbk @@ -19,8 +19,7 @@ In other words, inherits from __true_type only if copy assignment of `T` from `c marked with `= delete`, `T` does not derives from `boost::noncopyable` and is not marked with `BOOST_MOVABLE_BUT_NOT_COPYABLE(T)`. -__compat If the compiler does not support partial-specialization of class -templates, then this template can not be used. +__compat Requires the C++11 features `decltype` and SFINAE-expressions for full support. If your compiler does not support C++11 deleted functions (`= delete`) or does not support SFINAE for the deleted assignments, then derive your classes from `boost::noncopyable` or diff --git a/doc/is_copy_constructible.qbk b/doc/is_copy_constructible.qbk index 0168f27..12a7d6d 100644 --- a/doc/is_copy_constructible.qbk +++ b/doc/is_copy_constructible.qbk @@ -19,14 +19,13 @@ In other words, inherits from __true_type only if copy constructor of `T` not marked with `= delete`, `T` does not derives from `boost::noncopyable` and does not marked with `BOOST_MOVABLE_BUT_NOT_COPYABLE(T)`. -__compat If the compiler does not support partial-specialization of class -templates, then this template can not be used. +__compat This trait requires the C++11 features `decltype` and SFINAE-expression support for full support. If your compiler does not support C++11 deleted functions (`= delete`) or does not support SFINAE for the deleted constructors, then derive your classes from `boost::noncopyable` or mark them with `BOOST_MOVABLE_BUT_NOT_COPYABLE(T)` to show that class is noncopyable. -Trait does not care about access modifiers, so if you see errors like this: +The trait does not care about access modifiers, so if you see errors like this: 'T::T(const T&)' is private boost/type_traits/is_copy_constructible.hpp:68:5: error: within this context diff --git a/doc/is_empty.qbk b/doc/is_empty.qbk index e89e9a4..029a300 100644 --- a/doc/is_empty.qbk +++ b/doc/is_empty.qbk @@ -24,11 +24,6 @@ by checking to see if the macro BOOST_IS_EMPTY is defined. Can not be used with incomplete types. -Can not be used with union types, until is_union can be made to work. - -If the compiler does not support partial-specialization of class templates, -then this template can not be used with abstract types. - __examples [:Given: `struct empty_class {};` ] diff --git a/doc/is_enum.qbk b/doc/is_enum.qbk index d937fa6..f31617d 100644 --- a/doc/is_enum.qbk +++ b/doc/is_enum.qbk @@ -16,10 +16,7 @@ __std_ref 3.9.2 and 7.2. __header ` #include ` or ` #include ` -__compat Requires a correctly functioning __is_convertible template; - this means that is_enum is currently broken under Borland C++ Builder 5, - and for the Metrowerks compiler prior to version 8, other compilers - should handle this template just fine. +[all_compilers] __examples diff --git a/doc/is_final.qbk b/doc/is_final.qbk index 6f3e326..e0b5f65 100644 --- a/doc/is_final.qbk +++ b/doc/is_final.qbk @@ -20,7 +20,7 @@ class types declared with the final specifier using only standard C++, as a result this type will never inherit from __true_type, unless the user explicitly specializes the template for their user-defined final class types, or unless the compiler supplies some unspecified intrinsic that implements this functionality. -Currently (Aug 2014) compilers more recent than GCC-4.7, and Clang +Currently (June 2015) compilers more recent than GCC-4.7, Oracle-12.4, and Clang have the necessary compiler __intrinsics to ensure that this trait "just works". You may also test to see if the necessary __intrinsics are available by checking to see if the macro `BOOST_IS_FINAL` is defined. diff --git a/doc/is_floating_point.qbk b/doc/is_floating_point.qbk index 43f043b..22d4b0b 100644 --- a/doc/is_floating_point.qbk +++ b/doc/is_floating_point.qbk @@ -14,6 +14,8 @@ otherwise inherits from __false_type. __std_ref 3.9.1p8. +[all_compilers] + __header ` #include ` or ` #include ` __examples diff --git a/doc/is_function.qbk b/doc/is_function.qbk index c9cbae1..9c3c91e 100644 --- a/doc/is_function.qbk +++ b/doc/is_function.qbk @@ -21,6 +21,8 @@ __is_reference respectively: __std_ref 3.9.2p1 and 8.3.5. +[all_compilers] + __header ` #include ` or ` #include ` __examples diff --git a/doc/is_fundamental.qbk b/doc/is_fundamental.qbk index 8e4b4b0..da71a8c 100644 --- a/doc/is_fundamental.qbk +++ b/doc/is_fundamental.qbk @@ -15,6 +15,8 @@ point and void types (see also __is_integral, __is_floating_point and __is_void) __std_ref 3.9.1. +[all_compilers] + __header ` #include ` or ` #include ` __examples diff --git a/doc/is_integral.qbk b/doc/is_integral.qbk index 5d4add2..b26275b 100644 --- a/doc/is_integral.qbk +++ b/doc/is_integral.qbk @@ -14,6 +14,8 @@ otherwise inherits from __false_type. __std_ref 3.9.1p7. +[all_compilers] + __header ` #include ` or ` #include ` __examples diff --git a/doc/is_lvalue_reference.qbk b/doc/is_lvalue_reference.qbk index bd5349c..7e3390e 100644 --- a/doc/is_lvalue_reference.qbk +++ b/doc/is_lvalue_reference.qbk @@ -15,10 +15,7 @@ otherwise inherits from __false_type. __std_ref 3.9.2 and 8.3.2. -__compat If the compiler does not -support partial-specialization of class templates, -then this template may report the wrong result for function types, -and for types that are both const and volatile qualified. +[all_compilers] __header ` #include ` or ` #include ` diff --git a/doc/is_member_function_pointer.qbk b/doc/is_member_function_pointer.qbk index 673b306..5f485ea 100644 --- a/doc/is_member_function_pointer.qbk +++ b/doc/is_member_function_pointer.qbk @@ -15,6 +15,8 @@ otherwise inherits from __false_type. __std_ref 3.9.2 and 8.3.3. +[all_compilers] + __header ` #include ` or ` #include ` __examples diff --git a/doc/is_member_object_pointer.qbk b/doc/is_member_object_pointer.qbk index 87510a9..75a8fbd 100644 --- a/doc/is_member_object_pointer.qbk +++ b/doc/is_member_object_pointer.qbk @@ -15,6 +15,8 @@ otherwise inherits from __false_type. __std_ref 3.9.2 and 8.3.3. +[all_compilers] + __header ` #include ` or ` #include ` __examples diff --git a/doc/is_member_pointer.qbk b/doc/is_member_pointer.qbk index f45372f..3122e7f 100644 --- a/doc/is_member_pointer.qbk +++ b/doc/is_member_pointer.qbk @@ -16,6 +16,8 @@ otherwise inherits from __false_type. __std_ref 3.9.2 and 8.3.3. +[all_compilers] + __header ` #include ` or ` #include ` __examples diff --git a/doc/type_traits.qbk b/doc/type_traits.qbk index 3c3a28d..9b0f68c 100644 --- a/doc/type_traits.qbk +++ b/doc/type_traits.qbk @@ -275,8 +275,8 @@ See __has_trivial_constructor. [include is_compound.qbk] [include is_const.qbk] [include is_convertible.qbk] -[include is_copy_constructible.qbk] [include is_copy_assignable.qbk] +[include is_copy_constructible.qbk] [include is_empty.qbk] [include is_enum.qbk] [include is_final.qbk]