X-Git-Url: https://git.donarmstrong.com/?p=rsem.git;a=blobdiff_plain;f=boost%2Frange%2Fdistance.hpp;fp=boost%2Frange%2Fdistance.hpp;h=42a106de0323f7bfe44f581d1531ccbe323f5500;hp=0000000000000000000000000000000000000000;hb=2d71eb92104693ca9baa5a2e1c23eeca776d8fd3;hpb=da57529b92adbb7ae74a89861cb39fb35ac7c62d diff --git a/boost/range/distance.hpp b/boost/range/distance.hpp new file mode 100644 index 0000000..42a106d --- /dev/null +++ b/boost/range/distance.hpp @@ -0,0 +1,34 @@ +// Boost.Range library +// +// Copyright Thorsten Ottosen 2003-2006. Use, modification and +// distribution is subject to the Boost Software License, Version +// 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +// +// For more information, see http://www.boost.org/libs/range/ +// + +#ifndef BOOST_RANGE_DISTANCE_HPP +#define BOOST_RANGE_DISTANCE_HPP + +#if defined(_MSC_VER) && (_MSC_VER >= 1200) +# pragma once +#endif + +#include +#include +#include + +namespace boost +{ + + template< class T > + inline BOOST_DEDUCED_TYPENAME range_difference::type + distance( const T& r ) + { + return std::distance( boost::begin( r ), boost::end( r ) ); + } + +} // namespace 'boost' + +#endif