forked from boostorg/core
Remove BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
Process #ifndef...#else...#endif blocks. [SVN r86245]
This commit is contained in:
committed by
Peter Dimov
parent
e03dc68219
commit
3401b1e37b
@@ -258,7 +258,6 @@ struct stlport_40_debug_iterator_traits
|
|||||||
|
|
||||||
template <class T> struct pointer_iterator_traits;
|
template <class T> struct pointer_iterator_traits;
|
||||||
|
|
||||||
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
|
|
||||||
template <class T>
|
template <class T>
|
||||||
struct pointer_iterator_traits<T*>
|
struct pointer_iterator_traits<T*>
|
||||||
{
|
{
|
||||||
@@ -268,50 +267,6 @@ struct pointer_iterator_traits<T*>
|
|||||||
typedef std::random_access_iterator_tag iterator_category;
|
typedef std::random_access_iterator_tag iterator_category;
|
||||||
typedef std::ptrdiff_t difference_type;
|
typedef std::ptrdiff_t difference_type;
|
||||||
};
|
};
|
||||||
# else
|
|
||||||
|
|
||||||
// In case of no template partial specialization, and if T is a
|
|
||||||
// pointer, iterator_traits<T>::value_type can still be computed. For
|
|
||||||
// some basic types, remove_pointer is manually defined in
|
|
||||||
// type_traits/broken_compiler_spec.hpp. For others, do it yourself.
|
|
||||||
|
|
||||||
template<class P> class please_invoke_BOOST_TT_BROKEN_COMPILER_SPEC_on_cv_unqualified_pointee;
|
|
||||||
|
|
||||||
template<class P>
|
|
||||||
struct pointer_value_type
|
|
||||||
: mpl::if_<
|
|
||||||
is_same<P, typename remove_pointer<P>::type>
|
|
||||||
, please_invoke_BOOST_TT_BROKEN_COMPILER_SPEC_on_cv_unqualified_pointee<P>
|
|
||||||
, typename remove_const<
|
|
||||||
typename remove_pointer<P>::type
|
|
||||||
>::type
|
|
||||||
>
|
|
||||||
{
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
template<class P>
|
|
||||||
struct pointer_reference
|
|
||||||
: mpl::if_<
|
|
||||||
is_same<P, typename remove_pointer<P>::type>
|
|
||||||
, please_invoke_BOOST_TT_BROKEN_COMPILER_SPEC_on_cv_unqualified_pointee<P>
|
|
||||||
, typename remove_pointer<P>::type&
|
|
||||||
>
|
|
||||||
{
|
|
||||||
};
|
|
||||||
|
|
||||||
template <class T>
|
|
||||||
struct pointer_iterator_traits
|
|
||||||
{
|
|
||||||
typedef T pointer;
|
|
||||||
typedef std::random_access_iterator_tag iterator_category;
|
|
||||||
typedef std::ptrdiff_t difference_type;
|
|
||||||
|
|
||||||
typedef typename pointer_value_type<T>::type value_type;
|
|
||||||
typedef typename pointer_reference<T>::type reference;
|
|
||||||
};
|
|
||||||
|
|
||||||
# endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
|
|
||||||
|
|
||||||
// We'll sort iterator types into one of these classifications, from which we
|
// We'll sort iterator types into one of these classifications, from which we
|
||||||
// can determine the difference_type, pointer, reference, and value_type
|
// can determine the difference_type, pointer, reference, and value_type
|
||||||
|
Reference in New Issue
Block a user