mirror of
https://github.com/boostorg/iterator.git
synced 2025-07-23 01:17:16 +02:00
added use of interoperable with to specialized iterators
[SVN r21701]
This commit is contained in:
@ -142,6 +142,10 @@ tag <tt class="literal"><span class="pre">CategoryOrTraversal</span></tt>. Othe
|
||||
<tt class="literal"><span class="pre">counting_iterator</span></tt> models Random Access Traversal Iterator.
|
||||
Otherwise, <tt class="literal"><span class="pre">counting_iterator</span></tt> models the same iterator traversal
|
||||
concepts modeled by <tt class="literal"><span class="pre">Incrementable</span></tt>.</p>
|
||||
<p>If iterator <tt class="literal"><span class="pre">X</span></tt> is interoperable with iterator <tt class="literal"><span class="pre">Y</span></tt> then
|
||||
<tt class="literal"><span class="pre">counting_iterator<X,C1,D1></span></tt> is interoperable with
|
||||
<tt class="literal"><span class="pre">counting_iterator<Y,C2,D2></span></tt> if both counting iterators have the
|
||||
same traversal category and difference type.</p>
|
||||
</div>
|
||||
<div class="section" id="counting-iterator-operations">
|
||||
<h1><a class="toc-backref" href="#id5" name="counting-iterator-operations"><tt class="literal"><span class="pre">counting_iterator</span></tt> operations</a></h1>
|
||||
@ -268,7 +272,7 @@ indirectly printing out the numbers from 0 to 7
|
||||
<hr class="footer" />
|
||||
<div class="footer">
|
||||
<a class="reference" href="counting_iterator.rst">View document source</a>.
|
||||
Generated on: 2004-01-13 14:26 UTC.
|
||||
Generated on: 2004-01-13 19:49 UTC.
|
||||
Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -83,6 +83,11 @@ tag ``CategoryOrTraversal``. Otherwise, if
|
||||
Otherwise, ``counting_iterator`` models the same iterator traversal
|
||||
concepts modeled by ``Incrementable``.
|
||||
|
||||
If iterator ``X`` is interoperable with iterator ``Y`` then
|
||||
``counting_iterator<X,C1,D1>`` is interoperable with
|
||||
``counting_iterator<Y,C2,D2>`` if both counting iterators have the
|
||||
same traversal category and difference type.
|
||||
|
||||
|
||||
|
||||
``counting_iterator`` operations
|
||||
|
@ -1540,6 +1540,8 @@ Random Access Traversal Iterator</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>If iterator <tt class="literal"><span class="pre">X</span></tt> is interoperable with iterator <tt class="literal"><span class="pre">Y</span></tt> then
|
||||
<tt class="literal"><span class="pre">reverse_iterator<X></span></tt> is interoperable with <tt class="literal"><span class="pre">reverse_iterator<Y></span></tt>.</p>
|
||||
</div>
|
||||
<div class="section" id="reverse-iterator-operations">
|
||||
<h4><a class="toc-backref" href="#id50" name="reverse-iterator-operations"><tt class="literal"><span class="pre">reverse_iterator</span></tt> operations</a></h4>
|
||||
@ -1741,6 +1743,9 @@ the <tt class="literal"><span class="pre">Iterator</span></tt> argument models.<
|
||||
</table>
|
||||
<p>If <tt class="literal"><span class="pre">transform_iterator</span></tt> models Writable Lvalue Iterator then it is a
|
||||
mutable iterator (as defined in the old iterator requirements).</p>
|
||||
<p>If iterator <tt class="literal"><span class="pre">X</span></tt> is interoperable with iterator <tt class="literal"><span class="pre">Y</span></tt> then
|
||||
<tt class="literal"><span class="pre">transform_iterator<F1,</span> <span class="pre">X,</span> <span class="pre">R1,</span> <span class="pre">V1></span></tt> is interoperable with
|
||||
<tt class="literal"><span class="pre">transform_iterator<F2,</span> <span class="pre">Y,</span> <span class="pre">R2,</span> <span class="pre">V2></span></tt>.</p>
|
||||
</div>
|
||||
<div class="section" id="transform-iterator-operations">
|
||||
<h4><a class="toc-backref" href="#id55" name="transform-iterator-operations"><tt class="literal"><span class="pre">transform_iterator</span></tt> operations</a></h4>
|
||||
@ -1963,6 +1968,9 @@ following tables.</p>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>If iterator <tt class="literal"><span class="pre">X</span></tt> is interoperable with iterator <tt class="literal"><span class="pre">Y</span></tt> then
|
||||
<tt class="literal"><span class="pre">filter_iterator<P1,</span> <span class="pre">X></span></tt> is interoperable with
|
||||
<tt class="literal"><span class="pre">filter_iterator<P2,</span> <span class="pre">Y></span></tt>.</p>
|
||||
</div>
|
||||
<div class="section" id="filter-iterator-operations">
|
||||
<h4><a class="toc-backref" href="#id60" name="filter-iterator-operations"><tt class="literal"><span class="pre">filter_iterator</span></tt> operations</a></h4>
|
||||
@ -2161,6 +2169,10 @@ tag <tt class="literal"><span class="pre">CategoryOrTraversal</span></tt>. Othe
|
||||
<tt class="literal"><span class="pre">counting_iterator</span></tt> models Random Access Traversal Iterator.
|
||||
Otherwise, <tt class="literal"><span class="pre">counting_iterator</span></tt> models the same iterator traversal
|
||||
concepts modeled by <tt class="literal"><span class="pre">Incrementable</span></tt>.</p>
|
||||
<p>If iterator <tt class="literal"><span class="pre">X</span></tt> is interoperable with iterator <tt class="literal"><span class="pre">Y</span></tt> then
|
||||
<tt class="literal"><span class="pre">counting_iterator<X,C1,D1></span></tt> is interoperable with
|
||||
<tt class="literal"><span class="pre">counting_iterator<Y,C2,D2></span></tt> if both counting iterators have the
|
||||
same traversal category and difference type.</p>
|
||||
</div>
|
||||
<div class="section" id="counting-iterator-operations">
|
||||
<h4><a class="toc-backref" href="#id65" name="counting-iterator-operations"><tt class="literal"><span class="pre">counting_iterator</span></tt> operations</a></h4>
|
||||
@ -2332,7 +2344,7 @@ LocalWords: OtherIncrementable Coplien -->
|
||||
<hr class="footer" />
|
||||
<div class="footer">
|
||||
<a class="reference" href="facade-and-adaptor.rst">View document source</a>.
|
||||
Generated on: 2004-01-13 18:27 UTC.
|
||||
Generated on: 2004-01-13 19:49 UTC.
|
||||
Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -175,6 +175,9 @@ following tables.</p>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>If iterator <tt class="literal"><span class="pre">X</span></tt> is interoperable with iterator <tt class="literal"><span class="pre">Y</span></tt> then
|
||||
<tt class="literal"><span class="pre">filter_iterator<P1,</span> <span class="pre">X></span></tt> is interoperable with
|
||||
<tt class="literal"><span class="pre">filter_iterator<P2,</span> <span class="pre">Y></span></tt>.</p>
|
||||
</div>
|
||||
<div class="section" id="filter-iterator-operations">
|
||||
<h1><a class="toc-backref" href="#id5" name="filter-iterator-operations"><tt class="literal"><span class="pre">filter_iterator</span></tt> operations</a></h1>
|
||||
@ -378,7 +381,7 @@ int main()
|
||||
<hr class="footer" />
|
||||
<div class="footer">
|
||||
<a class="reference" href="filter_iterator.rst">View document source</a>.
|
||||
Generated on: 2004-01-13 18:08 UTC.
|
||||
Generated on: 2004-01-13 19:49 UTC.
|
||||
Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -87,6 +87,11 @@ following tables.
|
||||
+-------------------------------------------------------+---------------------------------+
|
||||
|
||||
|
||||
If iterator ``X`` is interoperable with iterator ``Y`` then
|
||||
``filter_iterator<P1, X>`` is interoperable with
|
||||
``filter_iterator<P2, Y>``.
|
||||
|
||||
|
||||
``filter_iterator`` operations
|
||||
..............................
|
||||
|
||||
|
@ -927,11 +927,14 @@ provide rather than how they're implemented.
|
||||
|
||||
:Proposed resolution: **Needs work**
|
||||
|
||||
Remove the specfication of inheritance, and add lots of specification
|
||||
to make up for it. In iterator_adaptor, that means duplicating a lot of
|
||||
function prototypes. In the other adaptors, that means making sure we
|
||||
state what concepts are modeled. Also, we will need an Interoperable
|
||||
Iterator concept to accomplish this.
|
||||
Remove the specfication of inheritance, and explicit specification of
|
||||
all the functionality that was inherited. In iterator_adaptor, that
|
||||
means adding a lot of function prototypes. In the other adaptors, that
|
||||
means making sure we state what concepts are modeled, in addition to
|
||||
specifying the semantics of some core operations. Also, the
|
||||
Interoperable Iterators concept is added to the new iterator concepts,
|
||||
and this concept is used in the specification of the iterator
|
||||
adaptors.
|
||||
|
||||
I'll start on the work of changing the specification for the
|
||||
specialized adaptors. -Jeremy
|
||||
|
@ -127,6 +127,8 @@ Random Access Traversal Iterator</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>If iterator <tt class="literal"><span class="pre">X</span></tt> is interoperable with iterator <tt class="literal"><span class="pre">Y</span></tt> then
|
||||
<tt class="literal"><span class="pre">reverse_iterator<X></span></tt> is interoperable with <tt class="literal"><span class="pre">reverse_iterator<Y></span></tt>.</p>
|
||||
</div>
|
||||
<div class="section" id="reverse-iterator-operations">
|
||||
<h1><a class="toc-backref" href="#id5" name="reverse-iterator-operations"><tt class="literal"><span class="pre">reverse_iterator</span></tt> operations</a></h1>
|
||||
@ -269,7 +271,7 @@ sequence in double-reversed (normal) order: hello world!
|
||||
<hr class="footer" />
|
||||
<div class="footer">
|
||||
<a class="reference" href="reverse_iterator.rst">View document source</a>.
|
||||
Generated on: 2004-01-13 18:15 UTC.
|
||||
Generated on: 2004-01-13 19:49 UTC.
|
||||
Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -69,6 +69,11 @@ specified in the following table:
|
||||
+---------------------------------------+-----------------------------------+
|
||||
|
||||
|
||||
If iterator ``X`` is interoperable with iterator ``Y`` then
|
||||
``reverse_iterator<X>`` is interoperable with ``reverse_iterator<Y>``.
|
||||
|
||||
|
||||
|
||||
``reverse_iterator`` operations
|
||||
...............................
|
||||
|
||||
|
@ -157,6 +157,9 @@ the <tt class="literal"><span class="pre">Iterator</span></tt> argument models.<
|
||||
</table>
|
||||
<p>If <tt class="literal"><span class="pre">transform_iterator</span></tt> models Writable Lvalue Iterator then it is a
|
||||
mutable iterator (as defined in the old iterator requirements).</p>
|
||||
<p>If iterator <tt class="literal"><span class="pre">X</span></tt> is interoperable with iterator <tt class="literal"><span class="pre">Y</span></tt> then
|
||||
<tt class="literal"><span class="pre">transform_iterator<F1,</span> <span class="pre">X,</span> <span class="pre">R1,</span> <span class="pre">V1></span></tt> is interoperable with
|
||||
<tt class="literal"><span class="pre">transform_iterator<F2,</span> <span class="pre">Y,</span> <span class="pre">R2,</span> <span class="pre">V2></span></tt>.</p>
|
||||
</div>
|
||||
<div class="section" id="transform-iterator-operations">
|
||||
<h1><a class="toc-backref" href="#id5" name="transform-iterator-operations"><tt class="literal"><span class="pre">transform_iterator</span></tt> operations</a></h1>
|
||||
@ -318,7 +321,7 @@ adding 4 to each element in the array:
|
||||
<hr class="footer" />
|
||||
<div class="footer">
|
||||
<a class="reference" href="transform_iterator.rst">View document source</a>.
|
||||
Generated on: 2004-01-13 18:27 UTC.
|
||||
Generated on: 2004-01-13 19:49 UTC.
|
||||
Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
|
||||
</div>
|
||||
</body>
|
||||
|
@ -102,6 +102,11 @@ the ``Iterator`` argument models.
|
||||
If ``transform_iterator`` models Writable Lvalue Iterator then it is a
|
||||
mutable iterator (as defined in the old iterator requirements).
|
||||
|
||||
If iterator ``X`` is interoperable with iterator ``Y`` then
|
||||
``transform_iterator<F1, X, R1, V1>`` is interoperable with
|
||||
``transform_iterator<F2, Y, R2, V2>``.
|
||||
|
||||
|
||||
|
||||
``transform_iterator`` operations
|
||||
.................................
|
||||
|
Reference in New Issue
Block a user