[boost][range] - Update to relax preconditions for the strided adaptor, and numerous fixes to inspection report issues.

[SVN r67418]
This commit is contained in:
Neil Groves
2010-12-22 22:31:33 +00:00
parent 1ff26bc99b
commit 612cec17bb
286 changed files with 4007 additions and 1192 deletions

View File

@ -24,7 +24,7 @@
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="range.reference.extending.method_2"></a><a class="link" href="method_2.html" title="Method 2: provide free-standing functions and specialize metafunctions"> Method 2: provide
<a name="range.reference.extending.method_2"></a><a class="link" href="method_2.html" title="Method 2: provide free-standing functions and specialize metafunctions">Method 2: provide
free-standing functions and specialize metafunctions</a>
</h4></div></div></div>
<p>
@ -83,6 +83,26 @@
</p>
</td>
</tr>
<tr>
<td>
<p>
<code class="computeroutput"><span class="identifier">range_calculate_size</span><span class="special">(</span><span class="identifier">x</span><span class="special">)</span></code>
</p>
</td>
<td>
<p>
Optional. This can be used to specify a mechanism for constant-time
computation of the size of a range. The default behaviour is
to return <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">end</span><span class="special">(</span><span class="identifier">x</span><span class="special">)</span> <span class="special">-</span>
<span class="identifier">boost</span><span class="special">::</span><span class="identifier">begin</span><span class="special">(</span><span class="identifier">x</span><span class="special">)</span></code>
for random access ranges, and to return <code class="computeroutput"><span class="identifier">x</span><span class="special">.</span><span class="identifier">size</span><span class="special">()</span></code> for ranges with lesser traversal
capability. This behaviour can be changed by implementing <code class="computeroutput"><span class="identifier">range_calculate_size</span></code> in a manner
that will be found via ADL. The ability to calculate size in
O(1) is often possible even with ranges with traversal categories
less than random access.
</p>
</td>
</tr>
</tbody>
</table></div>
<p>