diff --git a/doc/counting_iterator.html b/doc/counting_iterator.html index 9e5b105..5ed9298 100644 --- a/doc/counting_iterator.html +++ b/doc/counting_iterator.html @@ -81,7 +81,7 @@ class counting_iterator counting_iterator(); counting_iterator(counting_iterator const& rhs); explicit counting_iterator(Incrementable x); - Incrementable base() const; + Incrementable const& base() const; reference operator*() const; counting_iterator& operator++(); counting_iterator& operator--(); @@ -105,9 +105,12 @@ else iterator_traversal<Incrementable>::type, Incrementable, const Incrementable&) -
[Note: implementers are encouraged to provide an implementation -of operator- and a default difference_type that avoid -overflows when Incrementable is a numeric type.]
+Incrementable base() const;
+Incrementable const& base() const;
Base const base() const;
+Base const& base() const;
[Note: specifying Base const gives implementations license to -return Base const& for efficiency's sake. If base() -returned just Base, it would be possible to call non-const -member functions on the result object directly]
Iterator base() const;
+Iterator const& base() const;
Iterator base() const;
+Iterator const& base() const;
Iterator base() const;
-Returns: | m_iterator | -
---|
UnaryFunction functor() const;
Iterator const& base() const;
+Returns: | m_iterator | +
---|
reference operator*() const;
Iterator base() const;
+Iterator const& base() const;
Incrementable base() const;
+Incrementable const& base() const;
Iterator base() const;
+Iterator const& base() const;
Authors: | David Abrahams, Jeremy Siek, Thomas Witt |
---|---|
Contact: | dave@boost-consulting.com, jsiek@osl.iu.edu, witt@ive.uni-hannover.de | +
Contact: | dave@boost-consulting.com, jsiek@osl.iu.edu, witt@styleadvisor.com |
organizations: | Boost Consulting, Indiana University Open Systems -Lab, University of Hanover Institute for Transport -Railway Operation and Construction | +Lab, Zephyr Associates, Inc.
date: | $Date$ |
Iterator base() const;
+Iterator const& base() const;
Base const base() const;
+Base const& base() const;
[Note: specifying Base const gives implementations license to -return Base const& for efficiency's sake. If base() -returned just Base, it would be possible to call non-const -member functions on the result object directly]
The enable_if_interoperable template used above is for exposition -purposes. The member operators should be only be in an overload set +purposes. The member operators should only be in an overload set provided the derived types Dr1 and Dr2 are interoperable, meaning that at least one of the types is convertible to the other. The enable_if_interoperable approach uses SFINAE to take the operators @@ -785,7 +785,7 @@ operator -(iterator_facade<Dr1,V1,TC1,R1,D1> const& lhs,
Note that as currently specified, istreambuf_iterator doesn't -meet the Readable Iterator requirements because its value_type -is not convertible to its reference type. We believe this to -be a defect in the standard; it should be fixed by changing its -reference type from value_type& to value_type const&.
The extensions in this paper suggest several changes we might make diff --git a/doc/permutation_iterator.html b/doc/permutation_iterator.html index 21fc381..456940a 100644 --- a/doc/permutation_iterator.html +++ b/doc/permutation_iterator.html @@ -97,9 +97,9 @@ public: ); reference operator*() const; permutation_iterator& operator++(); - ElementIterator base() const; + ElementIterator const& base() const; private: - ElementIterator m_iterator; // exposition only + ElementIterator m_elt; // exposition only IndexIterator m_order; // exposition only }; @@ -131,9 +131,10 @@ as IndexIterator and the same
If IndexIterator models Random Access Traversal Iterator and ElementIterator models Readable Lvalue Iterator then permutation_iterator models Random Access Iterator.
-permutation_iterator<X, I1, V1, C2, R1, D1> is interoperable -with permutation_iterator<Y, I2, V2, C2, R2, D2> if and only if -X is interoperable with Y.
+permutation_iterator<E1, X, V1, C2, R1, D1> is interoperable +with permutation_iterator<E2, Y, V2, C2, R2, D2> if and only if +X is interoperable with Y and E1 is convertible +to E2.
ElementIterator base() const;
+ElementIterator const& base() const;
Returns: | m_iterator | +
---|---|
Returns: | m_order |
Iterator base() const;
+Iterator const& base() const;