changed reference type of counting_iterator to avoid problems on VC++

[SVN r8474]
This commit is contained in:
Jeremy Siek 2000-12-17 21:53:22 +00:00
parent 42ddb0d47b
commit 0c68369f23

View File

@ -35,14 +35,14 @@ namespace boost {
template <class IntegerType> template <class IntegerType>
struct counting_iterator_policies : public default_iterator_policies struct counting_iterator_policies : public default_iterator_policies
{ {
const IntegerType& IntegerType
dereference(type<const IntegerType&>, const IntegerType& i) const dereference(type<IntegerType>, const IntegerType& i) const
{ return i; } { return i; }
}; };
template <class IntegerType> template <class IntegerType>
struct counting_iterator_traits { struct counting_iterator_traits {
typedef IntegerType value_type; typedef IntegerType value_type;
typedef const IntegerType& reference; typedef IntegerType reference;
typedef value_type* pointer; typedef value_type* pointer;
typedef std::ptrdiff_t difference_type; typedef std::ptrdiff_t difference_type;
typedef std::random_access_iterator_tag iterator_category; typedef std::random_access_iterator_tag iterator_category;