Changeset 3527


Ignore:
Timestamp:
Oct 11, 2016, 9:06:08 AM (7 years ago)
Author:
Peter
Message:

refs #803. use new iterator concept in Averager

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/statistics/Averager.h

    r2817 r3527  
    3131
    3232#include <boost/concept_check.hpp>
     33#include <boost/iterator/iterator_concepts.hpp>
    3334
    3435#include <cmath>
     
    8687     \brief adding a range of values to Averager \a a
    8788
     89     Type Requirements:
     90     - \c InputIterator is a \readable_iterator
     91     - \c InputIterator is \single_pass_iterator
     92     - \c InputIterator 's value type is convertible to \c double
     93
    8894     \relates Averager
    8995   */
     
    9197  void add(Averager& a, InputIterator first, InputIterator last)
    9298  {
    93     BOOST_CONCEPT_ASSERT((boost::InputIterator<InputIterator>));
     99    BOOST_CONCEPT_ASSERT((boost_concepts::ReadableIterator<InputIterator>));
     100    BOOST_CONCEPT_ASSERT((boost_concepts::SinglePassIterator<InputIterator>));
     101    typedef typename boost::iterator_value<InputIterator>::type T;
     102    BOOST_CONCEPT_ASSERT((boost::Convertible<T, double>));
    94103    utility::check_iterator_is_unweighted(first);
    95104    for ( ; first != last; ++first)
Note: See TracChangeset for help on using the changeset viewer.