/usr/include/boost/range
NameSizeModeActions
adaptor/-0755rm
algorithm/-0755rm
algorithm_ext/-0755rm
detail/-0755rm
adaptors.hpp10960644editdlrm
algorithm.hpp39100644editdlrm
algorithm_ext.hpp10750644editdlrm
any_range.hpp65840644editdlrm
as_array.hpp9510644editdlrm
as_literal.hpp38370644editdlrm
atl.hpp168400644editdlrm
begin.hpp35550644editdlrm
category.hpp6980644editdlrm
combine.hpp11560644editdlrm
concepts.hpp136320644editdlrm
config.hpp13160644editdlrm
const_iterator.hpp19240644editdlrm
const_reverse_iterator.hpp10010644editdlrm
counting_range.hpp22160644editdlrm
difference_type.hpp12240644editdlrm
distance.hpp9880644editdlrm
empty.hpp7100644editdlrm
end.hpp36150644editdlrm
functions.hpp6800644editdlrm
has_range_iterator.hpp23750644editdlrm
irange.hpp80200644editdlrm
istream_range.hpp10970644editdlrm
iterator.hpp19780644editdlrm
iterator_range.hpp5300644editdlrm
iterator_range_core.hpp274390644editdlrm
iterator_range_hash.hpp5700644editdlrm
iterator_range_io.hpp26560644editdlrm
join.hpp28250644editdlrm
metafunctions.hpp8080644editdlrm
mfc.hpp243400644editdlrm
mfc_map.hpp38660644editdlrm
mutable_iterator.hpp20310644editdlrm
numeric.hpp60680644editdlrm
pointer.hpp7300644editdlrm
range_fwd.hpp13660644editdlrm
rbegin.hpp11880644editdlrm
reference.hpp7120644editdlrm
rend.hpp11890644editdlrm
result_iterator.hpp8110644editdlrm
reverse_iterator.hpp10950644editdlrm
reverse_result_iterator.hpp8650644editdlrm
size.hpp21940644editdlrm
size_type.hpp22980644editdlrm
sub_range.hpp77550644editdlrm
traversal.hpp7310644editdlrm
value_type.hpp6970644editdlrm
Edit: /usr/include/boost/range/numeric.hpp (6068B)
// Copyright 2009-2014 Neil Groves. // Distributed under 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) // // Copyright 2006 Thorsten Ottosen. // Distributed under 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) // // Copyright 2004 Eric Niebler. // Distributed under 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) // // Contains range-based versions of the numeric std algorithms // #if defined(_MSC_VER) #pragma once #endif #ifndef BOOST_RANGE_NUMERIC_HPP #define BOOST_RANGE_NUMERIC_HPP #include #include #include #include #include #include #include #include #include namespace boost { template inline Value accumulate(const SinglePassRange& rng, Value init) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); return std::accumulate(boost::begin(rng), boost::end(rng), init); } template inline Value accumulate(const SinglePassRange& rng, Value init, BinaryOperation op) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept )); return std::accumulate(boost::begin(rng), boost::end(rng), init, op); } namespace range_detail { template inline bool inner_product_precondition( const SinglePassRange1&, const SinglePassRange2&, std::input_iterator_tag, std::input_iterator_tag) { return true; } template inline bool inner_product_precondition( const SinglePassRange1& rng1, const SinglePassRange2& rng2, std::forward_iterator_tag, std::forward_iterator_tag) { return boost::size(rng2) >= boost::size(rng1); } } // namespace range_detail template< class SinglePassRange1, class SinglePassRange2, class Value > inline Value inner_product( const SinglePassRange1& rng1, const SinglePassRange2& rng2, Value init) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); BOOST_ASSERT( range_detail::inner_product_precondition( rng1, rng2, typename range_category::type(), typename range_category::type())); return std::inner_product( boost::begin(rng1), boost::end(rng1), boost::begin(rng2), init); } template< class SinglePassRange1, class SinglePassRange2, class Value, class BinaryOperation1, class BinaryOperation2 > inline Value inner_product( const SinglePassRange1& rng1, const SinglePassRange2& rng2, Value init, BinaryOperation1 op1, BinaryOperation2 op2) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); BOOST_ASSERT( range_detail::inner_product_precondition( rng1, rng2, typename range_category::type(), typename range_category::type())); return std::inner_product( boost::begin(rng1), boost::end(rng1), boost::begin(rng2), init, op1, op2); } template inline OutputIterator partial_sum(const SinglePassRange& rng, OutputIterator result) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); return std::partial_sum(boost::begin(rng), boost::end(rng), result); } template inline OutputIterator partial_sum( const SinglePassRange& rng, OutputIterator result, BinaryOperation op) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); return std::partial_sum(boost::begin(rng), boost::end(rng), result, op); } template inline OutputIterator adjacent_difference( const SinglePassRange& rng, OutputIterator result) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); return std::adjacent_difference(boost::begin(rng), boost::end(rng), result); } template inline OutputIterator adjacent_difference( const SinglePassRange& rng, OutputIterator result, BinaryOperation op) { BOOST_RANGE_CONCEPT_ASSERT(( SinglePassRangeConcept)); return std::adjacent_difference(boost::begin(rng), boost::end(rng), result, op); } } // namespace boost #endif