Add ADL guard namespace for boost::distance(rng).

This commit is contained in:
morinmorin
2018-09-23 21:45:30 +09:00
parent 70d1727ed3
commit 9192996a93

View File

@ -23,13 +23,18 @@
namespace boost
{
template< class T >
inline BOOST_CXX14_CONSTEXPR BOOST_DEDUCED_TYPENAME range_difference<T>::type
distance( const T& r )
namespace range_distance_adl_barrier
{
return boost::distance( boost::begin( r ), boost::end( r ) );
template< class T >
inline BOOST_CXX14_CONSTEXPR BOOST_DEDUCED_TYPENAME range_difference<T>::type
distance( const T& r )
{
return boost::iterators::distance( boost::begin( r ), boost::end( r ) );
}
}
using namespace range_distance_adl_barrier;
} // namespace 'boost'
#endif