Compare commits

..

57 Commits

Author SHA1 Message Date
b2d616d789 Merge.
[SVN r43270]
2008-02-16 09:50:01 +00:00
2321b5c2fe Merge from trunk.
[SVN r43211]
2008-02-10 15:26:54 +00:00
b4b13ae470 Merge.
[SVN r43162]
2008-02-07 18:54:14 +00:00
fbde78a968 Merge.
[SVN r42905]
2008-01-21 20:15:02 +00:00
c1aea25e44 Merge from trunk, finally.
[SVN r41817]
2007-12-07 01:12:02 +00:00
b148e2fee6 Create a branch to fix links on.
[SVN r41573]
2007-12-02 10:07:42 +00:00
8085605217 fixed a serious oversigt
[SVN r41457]
2007-11-29 09:19:24 +00:00
0eb365edbe macro patch
[SVN r41183]
2007-11-17 21:24:16 +00:00
2e0d7eab4a removed some warnings
[SVN r41181]
2007-11-17 21:21:53 +00:00
637dc618d1 iostream macro patch
[SVN r41180]
2007-11-17 21:19:13 +00:00
dd1459f221 works after local test with vc8
[SVN r41177]
2007-11-17 20:44:29 +00:00
ba96d075b2 last updates
[SVN r41176]
2007-11-17 20:22:20 +00:00
a2f3a45214 minor update of comments
[SVN r41175]
2007-11-17 20:22:05 +00:00
6ac0cfe09c improved reference
[SVN r40968]
2007-11-09 15:15:28 +00:00
7b3857a9a8 minor tweaks to avoid warnings ... extension mechanism updated to follow new protocol
[SVN r40966]
2007-11-09 13:31:43 +00:00
2605b9ee45 update of new concepts, and replacement of range_size<T>::type with range_difference<T>::type throughut the library
[SVN r40965]
2007-11-09 13:30:57 +00:00
1509d5603b minor editorial issue
[SVN r40964]
2007-11-09 13:13:06 +00:00
93deddde63 major update wrt. new range concepts
[SVN r40962]
2007-11-09 10:27:42 +00:00
68a63cab85 added deprecated headers again for backward compatibility sake
[SVN r40629]
2007-10-31 21:48:11 +00:00
06c54ccd48 current version gave problem in regression ... to be updated later
[SVN r40612]
2007-10-30 19:47:40 +00:00
2e298b5e60 adds test for inclusion of concept header
[SVN r40521]
2007-10-28 10:11:54 +00:00
00e70244a5 fixes broken one from trunk ... still not finished
[SVN r40520]
2007-10-28 10:11:10 +00:00
3f98d69c94 added mfc/atl link
[SVN r40514]
2007-10-27 22:00:47 +00:00
4767db522b first update ... more to come
[SVN r40508]
2007-10-27 15:58:22 +00:00
f6e555dda3 updated example to new syntax
[SVN r40507]
2007-10-27 15:57:56 +00:00
01826978d6 cleaned up deprecated headers
[SVN r40506]
2007-10-27 15:57:20 +00:00
336c12b60f removed deprecated mfc stuff
[SVN r40425]
2007-10-24 15:53:54 +00:00
82768af3d2 roll-back of ADL names
[SVN r40423]
2007-10-24 15:19:16 +00:00
8984de1c74 roll back of ADL names
[SVN r40422]
2007-10-24 15:18:22 +00:00
4db083cd6d Shunsuke Sogame's MFC/ATL docs and tests
[SVN r40381]
2007-10-23 20:28:52 +00:00
f4cde208f2 Adding Shunsuke Sogame fantastic MFC/ATL mappings
[SVN r40379]
2007-10-23 20:23:05 +00:00
d130dff5ec cleanup
[SVN r40378]
2007-10-23 20:08:35 +00:00
aa9158b199 applied Ticket #1309 (new Patches)
[SVN r40377]
2007-10-23 19:56:39 +00:00
bbd9fdb7bd displabed some warnings and applied Ticket #1284: sub_range_copy.patch
[SVN r40376]
2007-10-23 19:50:59 +00:00
17514e1d44 added operator() to allow random access index with transform iterators
[SVN r40375]
2007-10-23 19:34:38 +00:00
d759c23552 added test for operator()
[SVN r40374]
2007-10-23 19:34:06 +00:00
cf9ad808a6 new fancy quickbook documentaion
[SVN r40373]
2007-10-23 19:12:19 +00:00
028bff0c22 changed ADL functions back the names of 1.34 ... these names have been in use for too long ... let's not break code that depends on them
[SVN r40372]
2007-10-23 19:07:38 +00:00
33a8016af3 change names of ADL functions back to 1.34 names ... the old names have been in use for too long so let's not break code that depends on them
[SVN r40371]
2007-10-23 19:06:39 +00:00
24466ae189 applied patch from Ticket #1302 (new Patches) to handle char arrays correctly
[SVN r40370]
2007-10-23 18:59:11 +00:00
c8ffe55ae5 added test for char array with nested null in response to Ticket #471
[SVN r40367]
2007-10-23 18:36:03 +00:00
a862a573df Applied patch from Ticket #1320
[SVN r40020]
2007-10-14 17:53:15 +00:00
0b0dfc0e06 Added missing boost namespace reference to as_literal.
[SVN r39683]
2007-10-04 11:51:51 +00:00
e0a76af0f9 Quiet unused argument warnings from gcc.
[SVN r39274]
2007-09-14 17:18:02 +00:00
51650f1aa2 Remove V1 Jamfiles
[SVN r38516]
2007-08-08 19:02:26 +00:00
aeb47120e3 fixed typo
[SVN r36684]
2007-01-10 18:57:20 +00:00
22b7b4ec8e commented out old array code
[SVN r36683]
2007-01-10 18:50:13 +00:00
a933622ae1 Allow building of shared versions of some Boost.Test libraries.
Adjust tests to use always use static linking to Boost.Test, since
linking to the shared version requires test changes.

Patch from Juergen Hunold.


[SVN r35989]
2006-11-10 19:09:56 +00:00
f49be0b382 *** empty log message ***
[SVN r35717]
2006-10-24 10:37:46 +00:00
007117cefb Merge in recent fixes for inspect errors.
[SVN r34973]
2006-08-27 10:40:36 +00:00
73bb3d899a *** empty log message ***
[SVN r34034]
2006-05-19 18:01:02 +00:00
4a8987865e dos2unix on some files
[SVN r34025]
2006-05-19 10:30:02 +00:00
f885495565 *** empty log message ***
[SVN r34015]
2006-05-18 21:27:29 +00:00
dc34cd6079 *** empty log message ***
[SVN r34014]
2006-05-18 21:11:55 +00:00
5850d7ce3e new traits and functions for v2
[SVN r34013]
2006-05-18 20:53:21 +00:00
554f832234 upgrade to v2
[SVN r34012]
2006-05-18 20:52:17 +00:00
dc96b440be v2 upgrade
[SVN r34011]
2006-05-18 19:17:04 +00:00
82 changed files with 150 additions and 243 deletions

View File

@ -28,6 +28,5 @@ boostbook standalone
# <xsl:param>generate.section.toc.level=4
# <xsl:param>chunk.first.sections=7
# <xsl:param>toc.section.depth=10
<format>pdf:<xsl:param>boost.url.prefix=http://www.boost.org/doc/libs/release/doc/html
;

View File

@ -152,7 +152,7 @@ class=identifier>range_reverse_iterator</span></a><span class=special>;
</span><a href="#rend"><span class=identifier>rend</span></a><span class=special>( </span><span class=keyword>const </span><span
class=identifier>T</span><span class=special>&amp; </span><span class=identifier>r </span><span class=special>);
</span>
<span class=comment>//
</span><span class=comment>//
// Random Access Range functions
//
@ -235,7 +235,7 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
<td><code>A[sz]</code>
<td><code>a</code>
<td>denotes an array of type <code>A</code> of size <code>sz</code>
</tr>
<tr>
<tr>
<td><code>Char*</code>
<td><code>s</code>
@ -259,9 +259,9 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
<th>
Complexity</th>
</tr>
<tr >
<td><a name="range_iterator"></a><code>range_iterator&lt;X&gt;::type</code></td>
<tr>
<a name="range_iterator"></a>
<td><code>range_iterator&lt;X&gt;::type</code></td>
<td><code>T::iterator</code><br>
<code>P::first_type</code><br>
<code>A*</code><br>
@ -269,8 +269,8 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
<td>compile time</td>
</tr>
<tr>
<td><a name="range_const_iterator"></a><code>range_iterator&lt;const X&gt;::type</code></td>
<a name="range_const_iterator"></a>
<td><code>range_iterator&lt;const X&gt;::type</code></td>
<td><code>T::const_iterator</code><br>
<code>P::first_type</code><br>
<code>const A*</code><br>
@ -278,53 +278,54 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
<td>compile time</td>
</tr>
<tr>
<td><a name="range_value"></a><code>range_value&lt;X&gt;::type</code></td>
<a name="range_value"></a>
<td><code>range_value&lt;X&gt;::type</code></td>
<td><code>boost::iterator_value&lt;range_iterator&lt;X&gt;::type&gt;::type</code>
</td>
<td>compile time</td>
</tr>
<tr>
<td><a name="range_reference"></a><code>range_reference&lt;X&gt;::type</code></td>
<a name="range_reference"></a>
<td><code>range_reference&lt;X&gt;::type</code></td>
<td><code>boost::iterator_reference&lt;range_iterator&lt;X&gt;::type&gt;::type</code>
</td>
<td>compile time</td>
</tr>
<tr>
<td><a name="range_pointer"></a><code>range_pointer&lt;X&gt;::type</code></td>
<a name="range_pointer"></a>
<td><code>range_pointer&lt;X&gt;::type</code></td>
<td><code>boost::iterator_pointer&lt;range_iterator&lt;X&gt;::type&gt;::type</code>
</td>
<td>compile time</td>
</tr>
<tr>
<td><a name="range_category"></a><code>range_category&lt;X&gt;::type</code></td>
<a name="range_category"></a>
<td><code>range_category&lt;X&gt;::type</code></td>
<td><code>boost::iterator_category&lt;range_iterator&lt;X&gt;::type&gt;::type</code>
</td>
<td>compile time</td>
</tr>
<tr>
<td><a name="range_difference"></a><code>range_difference&lt;X&gt;::type</code></td>
<a name="range_difference"></a>
<td><code>range_difference&lt;X&gt;::type</code></td>
<td>
<code>boost::iterator_difference&lt;range_iterator&lt;X&gt;::type&gt;::type</code></td>
<td>compile time</td>
</tr>
</tr>
<tr>
<td><a name="range_reverse_iterator"></a><code>range_reverse_iterator&lt;X&gt;::type</code></td>
<a name="range_reverse_iterator"></a>
<td><code>range_reverse_iterator&lt;X&gt;::type</code></td>
<td><code>boost::reverse_iterator&lt;range_iterator&lt;X&gt;::type&gt;</code><br>
<td>compile time</td>
</tr>
<tr>
<td><a name="range_const_reverse_iterator"></a><code>range_reverse_iterator&lt;const X&gt;::type</code></td>
<a name="range_const_reverse_iterator"></a>
<td><code>range_reverse_iterator&lt;const X&gt;::type</code></td>
<td><code>boost::reverse_iterator&lt;range_iterator&lt;const X&gt;::type&gt;</code>
<br>
<td>compile time</td>
@ -345,11 +346,11 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
Complexity</th>
</tr>
<tr>
<td><a name="begin"></a><code>begin(x)</code></td>
<a name="begin"></a>
<td><code>begin(x)</code></td>
<td><code>range_iterator&lt;X&gt;::type</code></td>
<td>
<code>p.first</code> if <code>p</code> is of type <code>std::pair&lt;T&gt;<code><br>
<code>p.first</code> if <code>p</code> is of type <code>std::pair&ltT&gt;<code><br>
<code>a</code> if <code>a</code> is an array <br>
<code>range_begin(x)</code> if that expression would invoke a function found by ADL <br>
<code>t.begin()</code> otherwise
@ -357,11 +358,11 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
<td>constant time</td>
</tr>
<tr>
<td><a name="end"></a><code>end(x)</code></td>
<a name="end"></a>
<td><code>end(x)</code></td>
<td><code>range_iterator&lt;X&gt;::type</code></td>
<td>
<code>p.second</code> if <code>p</code> is of type <code>std::pair&lt;T&gt;<code><br>
<code>p.second</code> if <code>p</code> is of type <code>std::pair&ltT&gt;<code><br>
<code>a + sz</code> if <code>a</code> is an array of size <code>sz</code>
<br>
@ -372,16 +373,16 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
constant time </td>
</tr>
<tr>
<td><a name="empty"></a><code>empty(x)</code></td>
<a name="empty"></a>
<td><code>empty(x)</code></td>
<td><code>bool</code></td>
<td><code>boost::begin(x) == boost::end(x)</code><br>
<td> constant time <br>
</td>
</tr>
<tr>
<td><a name="distance"></a><code>distance(x)</code></td>
<a name="distance"></a>
<td><code>distance(x)</code></td>
<td><code>range_difference&lt;X&gt;::type</code></td>
<td>
<code>
@ -393,16 +394,16 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
</tr>
<tr>
<td><a name="size"></a><code>size(x)</code></td>
<a name="size"></a>
<td><code>size(x)</code></td>
<td><code>range_difference&lt;X&gt;::type</code></td>
<td><code> boost::end(x) - boost::begin(x)</code>
<td> constant time </td>
</tr>
<tr>
<td><a name="rbegin"></a><code>rbegin(x)</code></td>
<a name="rbegin"></a>
<td><code>rbegin(x)</code></td>
<td><code>range_reverse_iterator&lt;X&gt;::type</code></td>
<td><code>range_reverse_iterator&lt;X&gt;::type( boost::end(x) )</code>
<br>
@ -410,15 +411,15 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
</td>
</tr>
<tr>
<td> <a name="rend"></a><code>rend(x)</code></td>
<a name="rend"></a>
<td><code>rend(x)</code></td>
<td><code>range_reverse_iterator&lt;X&gt;::type</code></td>
<td><code>range_reverse_iterator&lt;X&gt;::type( boost::begin(x) )</code>
<td>constant time</td>
</tr>
<tr>
<td><a name="const_begin"></a><code>const_begin(x)</code></td>
<a name="const_begin"></a>
<td><code>const_begin(x)</code></td>
<td><code>range_iterator&lt;const X&gt;::type</code></td>
<td><code>range_iterator&lt;const X&gt;::type( boost::begin(x) )</code>
<br>
@ -426,15 +427,15 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
</td>
</tr>
<tr>
<td><a name="const_end"></a><code>const_end(x)</code></td>
<a name="const_end"></a>
<td><code>const_end(x)</code></td>
<td><code>range_iterator&lt;const X&gt;::type</code></td>
<td><code>range_iterator&lt;const X&gt;::type( boost::end(x) )</code>
<td>constant time</td>
</tr>
<tr>
<td><a name="const_rbegin"></a><code>const_rbegin(x)</code></td>
<a name="const_rbegin"></a>
<td><code>const_rbegin(x)</code></td>
<td><code>range_reverse_iterator&lt;const X&gt;::type</code></td>
<td><code>range_reverse_iterator&lt;const X&gt;::type( boost::rbegin(x) )</code>
<br>
@ -442,16 +443,16 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
</td>
</tr>
<tr>
<td><a name="const_rend"></a><code>const_rend(x)</code></td>
<a name="const_rend"></a>
<td><code>const_rend(x)</code></td>
<td><code>range_reverse_iterator&lt;const X&gt;::type</code></td>
<td><code>range_reverse_iterator&lt;const X&gt;::type( boost::rend(x) )</code>
<td>constant time</td>
</tr>
<tr>
<td><a name="as_literal"></a><code>as_literal(x)</code></td>
<a name="as_literal"></a>
<td><code>as_literal(x)</code></td>
<td><code>iterator_range&lt;U></code> where <code>U</code> is
<code>Char*</code> if <code>x</code> is a pointer to a
string and <code>U</code> is
@ -459,21 +460,20 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
</td>
<td>
<!-- <code>[a,a+sz-1)</code> if <code>a</code> is an array
of size <code>sz</code><br>-->
<code>[s,s + std::char_traits&lt;X&gt;::length(s))</code> if <code>s</code> is a <code>Char*</code> or an array of <code>Char</code>
<code>[a,a+sz-1)</code> if <code>a</code> is an array of size <code>sz</code><br>
<code>[s,s + std::char_traits&lt;X&gt;::length(s))</code> if <code>s</code> is a <code>Char*</code>
<br>
<code>[boost::begin(x),boost::end(x))</code> otherwise
</td>
<td>linear time for pointers to a string or arrays of
<code>Char</code>, constant time otherwise</td>
<td>linear time for pointers to a string, constant time
otherwise</td>
</tr>
<tr>
<td><a name="as_array"></a><code>as_array(x)</code></td>
<a name="as_array"></a>
<td><code>as_array(x)</code></td>
<td><code>iterator_range&lt;X></code> </td>
<td>
<code>[boost::begin(x),boost::end(x))</code>
@ -561,7 +561,7 @@ class=identifier>T</span><span class=special>&amp; </span><span class=identifier
Member type</th>
<th>
Related concept</th>
</tr>
<tr>
<tr>
<td><code>iterator</code></td>
<td><a href="range.html#single_pass_range">Single Pass Range</a></td>

8
doc/examples.html Normal file → Executable file
View File

@ -23,16 +23,16 @@
<ul >
<li >
<a href="../test/string.cpp" target="_self" ><code >string.cpp</code></a>
</li>
shows how to implement a container version of <code >std::find()</code> that
works with <code >char[],wchar_t[],char*,wchar_t*.</code>
</li>
<li >
<a href="../test/algorithm_example.cpp" target="_self" ><code >algorithm_example.cpp</code></a>
</li>
shows the replace example from the introduction.
</li>
<li> <a href="../test/iterator_range.cpp">iterator_range.cpp</a>
<li> <a href="../test/sub_range.cpp">sub_range.cpp</a>
<li> <a href="../test/iterator_pair.cpp">iterator_pair.cpp</a>

4
doc/faq.html Normal file → Executable file
View File

@ -22,7 +22,7 @@
<li >
<i>Why is there no difference between <code >range_iterator&lt;C&gt;::type</code>
and <code >range_const_iterator&lt;C&gt;::type</code> for <code>std::pair&lt;iterator, iterator&gt;</code></i>.
</li>
<p >
In general it is not possible nor desirable to find a corresponding <code >const_iterator</code>.
When it is possible to come up with one, the client might choose to construct a <code >std::pair&lt;const_iterator,const_iterator&gt;</code>
@ -33,7 +33,7 @@
is somewhat more convenient than a <code>pair</code> and that a <a
href="utility_class.html#sub_range"><code>sub_range</code></a> does
propagate const-ness. </p>
</li>
<li >
<i>Why is there not supplied more types or more functions?</i>
<p >

2
doc/headers.html Normal file → Executable file
View File

@ -167,7 +167,7 @@
</tr>
</table>
<br>
<br
</p>

0
doc/history_ack.html Normal file → Executable file
View File

4
doc/intro.html Normal file → Executable file
View File

@ -24,7 +24,7 @@
to a somewhat clumsy use of the algorithms with redundant specification
of container names. Therefore we would like to raise the abstraction level
for algorithms so they specify their interface in terms of <a
href="range.html">Ranges</a> as much as possible.
href=range.html>Ranges</a> as much as possible.
</p>
<p>
@ -108,7 +108,7 @@ class=identifier>ForwardReadableRange </span><span class=special>&gt;::</span><s
</span>
<span class=identifier>my_vector</span><span class=special>.</span><span
class=identifier>assign</span><span class=special>( </span><span class=identifier>values</span><span class=special>, </span><span class=identifier>boost</span><span class=special>::</span><span class=identifier>end</span><span class=special>( </span><span class=identifier>values </span><span class=special>) </span><span class=special>);</span>
<span class=keyword>typedef </span><span class=identifier>std</span><span class=special>::</span><span class=identifier>vector</span><span class=special>&lt;</span><span class=keyword>int</span><span class=special>&gt;::</span><span class=identifier>iterator </span><span class=identifier>iterator</span><span class=special>;
</span><span class=keyword>typedef </span><span class=identifier>std</span><span class=special>::</span><span class=identifier>vector</span><span class=special>&lt;</span><span class=keyword>int</span><span class=special>&gt;::</span><span class=identifier>iterator </span><span class=identifier>iterator</span><span class=special>;
</span><span class=identifier>std</span><span class=special>::</span><span class=identifier>pair</span><span class=special>&lt;</span><span class=identifier>iterator</span><span class=special>,</span><span class=identifier>iterator</span><span class=special>&gt; </span><span class=identifier>my_view</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>my_vector </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>my_vector </span><span class=special>) </span><span class=special>+ </span><span class=identifier>N </span><span class=special>);
</span><span class=keyword>char </span><span class=identifier>str_val</span><span class=special>[] </span><span class=special>= </span><span class=string>&quot;a string&quot;</span><span class=special>;

View File

@ -291,7 +291,7 @@ ul.auto-toc {
</head>
<body>
<div class="document" id="boost-range-mfc-atl-extension">
<h1 class="title"><img alt="Boost" src="../../ptr_container/doc/boost.png" /> Range MFC/ATL Extension</h1>
<h1 class="title"><img alt="Boost" src="http://www.boost.org/libs/ptr_container/doc/boost.png" /> Range MFC/ATL Extension</h1>
<table class="docinfo" frame="void" rules="none">
<col class="docinfo-name" />
<col class="docinfo-content" />

5
doc/portability.html Normal file → Executable file
View File

@ -29,8 +29,9 @@ href="http://boost.sourceforge.net/regression-logs/developer/range.html">here</a
template partial specialization. For non-conforming compilers there might be a
chance that it works anyway thanks to workarounds in the type traits library.
</p>
<p> Visual C++ 6/7.0 has a limited support for arrays: as long as the arrays
are of built-in type it should work.
<pp>
Visual C++ 6/7.0 has a limited support for arrays: as long as the arrays are
of built-in type it should work.
</p>
<p >
Notice also that some compilers cannot do function template ordering properly.

14
doc/range.html Normal file → Executable file
View File

@ -1,4 +1,3 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<!--
-- Copyright (c) Jeremy Siek 2000
@ -91,7 +90,7 @@ functions as free-standing functions to allow for a layer of indirection. </p>
<code>boost</code></p>-->
<hr>
<a name="single_pass_range"></a>
<a name="single_pass_range">
<H2>Single Pass Range</H2>
<h3>Notation</h3>
@ -228,7 +227,7 @@ otherwise</TD>
<hr>
<a name=forward_range></a><h2>Forward Range</h2>
<a name=forward_range><h2>Forward Range</h2>
<h3>Notation</h3>
<Table>
@ -256,7 +255,7 @@ Range</a>
<hr>
<a name="bidirectional_range"></a><h2>Bidirectional Range</h2>
<a name="bidirectional_range"><h2>Bidirectional Range</h2>
<h3>Notation</h3>
<Table>
@ -284,8 +283,7 @@ s-lib-bidirectional-traversal-iterators">Bidirectional Traversal Iterator.</a>
<hr>
<a name=random_access_range></a><h2>Random Access Range</h2>
<h3>Description</h3>
<a name=random_access_range><h2>Random Access Range</h2> <h3>Description</h3>
<p>
A range <code>X</code> where <code>boost::range_iterator&lt;X>::type</code> is a model
of <a
@ -301,10 +299,10 @@ href="../../iterator/doc/new-iter-concepts.html#random-access-traversal-iterator
<hr>
<a name=concept_checking></a><h2>Concept Checking</h2>
<a name=concept_checking><h2>Concept Checking</h2>
Each of the range concepts has a corresponding concept checking
class in the file <code>&lt;boost/range/concepts.hpp&gt;</code>. These classes may be
class in the file <code><boost/range/concepts.hpp></codE>. These classes may be
used in conjunction with the <a
href="../../concept_check/concept_check.htm">Boost Concept
Check</a> library to insure that the type of a template parameter

0
doc/style.css Normal file → Executable file
View File

2
doc/style.html Normal file → Executable file
View File

@ -53,7 +53,7 @@
<a href="range.html#bidirectional_range">Bidirectional Range</a> <li>
<a href="range.html#random_access_range">Random Access Range</a> </ul>
</ul>
Notice how we have used the categories from the <a href="../../iterator/doc/new-iter-concepts.html">new
Notice how we have used the categories from the <a href=../../iterator/doc/new-iter-concepts.html>new
style iterators</a>.
<p>

View File

@ -1,78 +0,0 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Boost.Range Upgrading </title> <link rel="stylesheet"
href="style.css" type="text/css">
</head>
<body>
<table border="0" >
<tr>
<td ><img src="../../../boost.png" border="0" ></td>
<td ><h1 align="center">Boost.Range </h1></td>
</tr>
</table>
<h2 >Upgrading from Boost v. 1.34.*</h2><a name="v1.34" ></a>
<p >
Boost v. 1.35 introduced some larger refactorings of the library:
</p>
<ul >
<li>Direct support for character arrays was abandoned in favor of
uniform treatment of all arrays. Instead string algorithms can use
the new function <a
href="boost_range.html#as_literal">as_literal()</a>.</li>
<li><a
href="boost_range.html#size">boost::size()</a> now requires a Random Access Range. The old behavior is provided as <a
href="boost_range.html#distance">boost::distance()</a> </li>
<li> <code>range_size&lt;T&gt;::type</code> has been completely removed
in favor of <code>range_difference&lt;T&gt;::type</code>
<li>
<code>boost_range_begin()</code> and <code>boost_range_end()</code>
have been renamed <code>range_begin()</code> and <code>range_begin()</code>, respectively.</li>
<li><code>range_result_iterator&lt;T&gt;::type</code> and
<code>range_reverse_result_iterator&lt;T&gt;::type</code> are have
been renamed
<code>range_iterator&lt;T&gt;::type</code> and
<code>range_reverse_iterator&lt;T&gt;::type</code>.
</li>
<li>The procedure that makes a custom type work with the library
has been greatly simplified. See <a
href="boost_range.html#minimal_interface">extending the library </a>
for details.</li>
</ul>
<hr>
<p>
&copy; <a name="Copyright" id="Copyright">Copyright</a> Thorsten Ottosen 2008.
</p>
<p>
Distributed under the Boost Software License, Version 1.0. (See
accompanying file LICENSE_1_0.txt or copy at <a href=
"http://www.boost.org/LICENSE_1_0.txt">www.boost.org/LICENSE_1_0.txt</a>)
</p>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
</body>
</html>

View File

@ -27,9 +27,10 @@
<ul>
<li>
Class <a href="#iter_range"><code>iterator_range</code></a>
Class <a href=#iter_range><code>iterator_range</code></a>
<li>
Class <a href="#sub_range"><code>sub_range</code></a>
Class <a href=#sub_range><code>sub_range</code></a>
</ul>
</ul>
The <code>iterator_range</code> class is templated on a <a
@ -83,7 +84,7 @@ corresponding <code>const_iterator</code> is. </p>
</span><span class=keyword>typedef </span><span class=identifier>ForwardTraversalIterator </span><span class=identifier>const_iterator</span><span class=special>;</span>
<span class=keyword>typedef </span><span class=identifier>iterator_difference</span><span class=special>&lt;</span><span class=identifier>iterator</span><span class=special>&gt;::</span><span class=identifier>type </span><span class=identifier>difference_type</span><span class=special>;</span>
<span class=keyword>public</span><span class=special>: </span><span class=comment>// construction, assignment
</span><span class=keyword>public</span><span class=special>: </span><span class=comment>// construction, assignment
</span><span class=keyword>template</span><span class=special>&lt; </span><span class=keyword>class </span><span class=identifier>ForwardTraversalIterator2 </span><span class=special>&gt;
</span><span class=identifier>iterator_range</span><span class=special>( </span><span class=identifier>ForwardTraversalIterator2 </span><span class=identifier>Begin</span><span class=special>, </span><span class=identifier>ForwardTraversalIterator2 </span><span class=identifier>End </span><span class=special>);
@ -109,7 +110,7 @@ corresponding <code>const_iterator</code> is. </p>
</span><span class=keyword>operator </span><a href="#unspecified_bool"><span class=identifier>unspecified_bool_type</span></a><span class=special>() </span><span class=keyword>const</span><span class=special>;
</span> <span class=keyword>bool</span> <span
class=identifier><a href="#equal">equal</a></span><span
class=special>( </span><span class=keyword>const</span> <span class=identifier>iterator_range</span><span class=special>&amp; ) </span><span
class=special>( </span><span class=keyword>const</span> <span class=identifier>iterator_range</span><span class=special>& ) </span><span
class=keyword>const;</span>
<span class=identifier>reference </span><span class=identifier>front</span><span class=special>() </span><span class=keyword>const</span><span class=special>;</span>
<span class=identifier>reference </span><span class=identifier>back</span><span class=special>() </span><span class=keyword>const</span><span class=special>;</span>
@ -118,7 +119,7 @@ class=keyword>const;</span>
<span class=comment>// for Random Access Range only: </span>
<span class=identifier>reference </span><span class=keyword>operator</span><span class=special>[]( </span><span class=identifier>difference_type </span><span class=identifier>at </span><span class=special>) </span><span class=keyword>const</span><span class=special>;</span>
<span class=identifier>value_type</span> <span class=keyword>operator</span><span class=special>()( </span><span class=identifier>difference_type </span><span class=identifier>at </span><span class=special>) </span><span class=keyword>const</span><span class=special>;</span>
<span class=special>};
</span><span class=special>};
</span><span class=comment>// stream output
</span><span class=keyword>template</span><span class=special>&lt; </span><span class=keyword>class </span><span class=identifier>ForwardTraversalIterator</span><span class=special>, </span><span class=keyword>class </span><span class=identifier>T</span><span class=special>, </span><span class=keyword>class </span><span class=identifier>Traits </span><span class=special>&gt;
@ -163,7 +164,7 @@ class=keyword>const;</span>
</span><span class=keyword>bool </span><span class=keyword>operator</span><span class=special>&lt;( </span><span class=keyword>const </span><span class=identifier>ForwardRange</span><span class=special>&amp; </span><span class=identifier>l</span><span class=special>,
</span><span class=keyword>const </span><span class=identifier>iterator_range</span><span class=special>&lt;</span><span class=identifier>ForwardTraversalIterator</span><span class=special>&gt;&amp; </span><span class=identifier>r </span><span class=special>);</span>
<span class=comment>// external construction
</span><span class=comment>// external construction
</span><span class=keyword>template</span><span class=special>&lt; </span><span class=keyword>class </span><span class=identifier>ForwardTraversalIterator </span><span class=special>&gt;
</span><span class=identifier>iterator_range</span><span class=special>&lt; </span><span class=identifier>ForwardTraversalIterator </span><span class=special>&gt;
</span><span class=identifier>make_iterator_range</span><span class=special>( </span><span class=identifier>ForwardTraversalIterator </span><span class=identifier>Begin</span><span class=special>,
@ -189,7 +190,7 @@ class=keyword>const;</span>
</span><span class=keyword>typename </span><span class=identifier>range_difference</span><span class=special>&lt;</span><span class=identifier>Range</span><span class=special>&gt;::</span><span class=identifier>type </span><span class=identifier>advance_begin</span><span class=special>,
</span><span class=keyword>typename </span><span class=identifier>range_difference</span><span class=special>&lt;</span><span class=identifier>Range</span><span class=special>&gt;::</span><span class=identifier>type </span><span class=identifier>advance_end </span><span class=special>);</span>
<span class=comment>// convenience
</span><span class=comment>// convenience
</span><span class=keyword>template</span><span class=special>&lt; </span><span class=keyword>class </span><span class=identifier>Sequence</span><span class=special>, </span><span class=keyword>class </span><span class=identifier>ForwardRange </span><span class=special>&gt;
</span><span class=identifier>Sequence </span><a href="#copy_range"><span
class=identifier>copy_range</span></a><span class=special>( </span><span
@ -225,9 +226,9 @@ non-const iterators from the same container. </p>
<p>
<a name="equal"></a>
<code>bool equal( iterator_range&amp; r ) const;</code>
<code>bool equal( iterator_range& r ) const;</code>
<blockquote>
<i>Returns</i> <code>begin() == r.begin() &amp;&amp; end() == r.end();</code>
<i>Returns</i> <code>begin() == r.begin() && end() == r.end();</code>
</blockquote>
</p>
@ -235,21 +236,21 @@ non-const iterators from the same container. </p>
<p>
<a name="comparison"></a>
<code>bool operator==( const ForwardRange1&amp; l, const ForwardRange2&amp; r );</code>
<code>bool operator==( const ForwardRange1& l, const ForwardRange2& r );</code>
<blockquote>
<i>Returns</i> <code>size(l) != size(r) ? false : std::equal( begin(l), end(l), begin(r) );</code> </blockquote> </p>
<code>bool operator!=( const ForwardRange1&amp; l, const ForwardRange2&amp; r );</code>
<code>bool operator!=( const ForwardRange1& l, const ForwardRange2& r );</code>
<blockquote>
<i>Returns</i> <code>!( l == r );</code>
</blockquote>
<code>bool operator<( const ForwardRange1&amp; l, const ForwardRange2&amp; r );</code>
<code>bool operator<( const ForwardRange1& l, const ForwardRange2& r );</code>
<blockquote>
<i>Returns</i> <code>std::lexicographical_compare( begin(l), end(l), begin(r), end(r) );</code> </blockquote>
<p>
<a name="make_iterator_range"></a>
<pre>
iterator_range make_iterator_range( Range&amp; r,
iterator_range make_iterator_range( Range& r,
typename range_difference&lt;Range>::type advance_begin,
typename range_difference&lt;Range>::type advance_end );
</pre>
@ -265,7 +266,7 @@ return make_iterator_range( new_begin, new_end );
</blockquote>
<p>
<a name="copy_range"></a>
<code>Sequence copy_range( const ForwardRange&amp; r );</code>
<code>Sequence copy_range( const ForwardRange& r );</code>
<blockquote>
<i>Returns</i> <code>Sequence( begin(r), end(r) );</code>
</blockquote>
@ -291,7 +292,7 @@ class can propagate constness since it knows what a corresponding
</span><span class=keyword>class </span><span class=identifier>sub_range </span><span class=special>: </span><span class=keyword>public </span><span class=identifier>iterator_range</span><span class=special>&lt; </span><span class=keyword>typename </span><span class=identifier>range_iterator</span><span class=special>&lt;</span><span class=identifier>ForwardRange</span><span class=special>&gt;::</span><span class=identifier>type </span><span class=special>&gt;
</span><span class=special>{
</span><span class=keyword>public</span><span class=special>: </span>
<span class=keyword>typedef </span><span class=keyword>typename </span><span class=identifier>range_iterator</span><span class=special>&lt;</span><span class=identifier>ForwardRange</span><span class=special>&gt;::</span><span class=identifier>type </span><span class=identifier>iterator</span><span class=special>;</span>
<span class=keyword>typedef </span><span class=keyword>typename </span><span class=identifier>range_iterator</span><span class=special>&lt;</span><span class=identifier>ForwardRange</span><spanclass=special>&gt;::</span><span class=identifier>type </span><span class=identifier>iterator</span><span class=special>;</span>
<span class=keyword>typedef </span><span class=keyword>typename </span><span class=identifier>range_iterator</span><span class=special>&lt;</span><span class=keyword>const </span><span class=identifier>ForwardRange</span><span class=special>&gt;::</span><span class=identifier>type </span><span class=identifier>const_iterator</span><span class=special>;</span>
<span class=keyword>typedef </span><span class=keyword>typename </span><span class=identifier>iterator_difference</span><span class=special>&lt;</span><span class=identifier>iterator</span><span class=special>&gt;::</span><span class=identifier>type </span><span class=identifier>difference_type</span><span class=special>;</span>
@ -328,7 +329,7 @@ class can propagate constness since it knows what a corresponding
<span class=keyword>const </span><span class=identifier>value_type</span><span class=special>&amp; </span><span class=keyword>operator</span><span class=special>[]( </span><span class=identifier>difference_type </span><span class=identifier>at </span><span class=special>) </span><span class=keyword>const</span><span class=special>;</span>
<span class=keyword>public</span><span class=special>:
</span><span class=comment>// rest of interface inherited from <a href="#iter_range"><code>iterator_range</code></a>
</span><span class=comment>// rest of interface inherited from <a href=#iter_range><code>iterator_range</code></a>
</span><span class=special>};
</span>
<span class=special>} </span><span class=comment>// namespace 'boost'</span>

0
include/boost/range.hpp Normal file → Executable file
View File

0
include/boost/range/as_array.hpp Normal file → Executable file
View File

24
include/boost/range/as_literal.hpp Normal file → Executable file
View File

@ -8,8 +8,8 @@
// For more information, see http://www.boost.org/libs/range/
//
#ifndef BOOST_RANGE_AS_LITERAL_HPP
#define BOOST_RANGE_AS_LITERAL_HPP
#ifndef BOOST_RANGE_DETAIL_AS_LITERAL_HPP
#define BOOST_RANGE_DETAIL_AS_LITERAL_HPP
#if defined(_MSC_VER) && (_MSC_VER >= 1200)
# pragma once
@ -25,9 +25,7 @@
#include <boost/detail/workaround.hpp>
#include <cstring>
#ifndef BOOST_NO_CWCHAR
#include <cwchar>
#endif
namespace boost
{
@ -38,12 +36,10 @@ namespace boost
return strlen( s );
}
#ifndef BOOST_NO_CWCHAR
inline std::size_t length( const wchar_t* s )
{
return wcslen( s );
}
#endif
//
// Remark: the compiler cannot choose between T* and T[sz]
@ -61,7 +57,7 @@ namespace boost
return true;
}
#ifndef BOOST_NO_CWCHAR
inline bool is_char_ptr( wchar_t* )
{
return true;
@ -71,7 +67,6 @@ namespace boost
{
return true;
}
#endif
template< class T >
inline long is_char_ptr( T /* r */ )
@ -112,13 +107,22 @@ namespace boost
template< class Char, std::size_t sz >
inline iterator_range<Char*> as_literal( Char (&arr)[sz] )
{
return range_detail::make_range( arr, range_detail::is_char_ptr(arr) );
#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x590)) && __BORLANDC__ >= 0x590
return boost::make_iterator_range<Char*>( arr, arr + sz - 1 );
#else
return boost::make_iterator_range( arr, arr + sz - 1 );
#endif
}
template< class Char, std::size_t sz >
inline iterator_range<const Char*> as_literal( const Char (&arr)[sz] )
{
return range_detail::make_range( arr, range_detail::is_char_ptr(arr) );
#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x590)) && __BORLANDC__ >= 0x590
return boost::make_iterator_range<const Char*>( arr, arr + sz - 1 );
#else
return boost::make_iterator_range( arr, arr + sz - 1 );
#endif
}
}

8
include/boost/range/begin.hpp Normal file → Executable file
View File

@ -73,15 +73,15 @@ namespace range_detail
// May this be discarded? Or is it needed for bad compilers?
//
template< typename T, std::size_t sz >
inline const T* range_begin( const T (&a)[sz] )
inline const T* range_begin( const T (&array)[sz] )
{
return a;
return array;
}
template< typename T, std::size_t sz >
inline T* range_begin( T (&a)[sz] )
inline T* range_begin( T (&array)[sz] )
{
return a;
return array;
}

0
include/boost/range/category.hpp Normal file → Executable file
View File

0
include/boost/range/concepts.hpp Normal file → Executable file
View File

0
include/boost/range/config.hpp Normal file → Executable file
View File

0
include/boost/range/const_iterator.hpp Normal file → Executable file
View File

0
include/boost/range/const_reverse_iterator.hpp Normal file → Executable file
View File

4
include/boost/range/detail/as_literal.hpp Normal file → Executable file
View File

@ -8,8 +8,8 @@
// For more information, see http://www.boost.org/libs/range/
//
#ifndef BOOST_RANGE_DETAIL_AS_LITERAL_HPP
#define BOOST_RANGE_DETAIL_AS_LITERAL_HPP
#ifndef BOOST_RANGE_AS_LITERAL_HPP
#define BOOST_RANGE_AS_LITERAL_HPP
#if defined(_MSC_VER) && (_MSC_VER >= 1200)
# pragma once

0
include/boost/range/detail/begin.hpp Normal file → Executable file
View File

0
include/boost/range/detail/collection_traits.hpp Normal file → Executable file
View File

View File

0
include/boost/range/detail/common.hpp Normal file → Executable file
View File

0
include/boost/range/detail/const_iterator.hpp Normal file → Executable file
View File

0
include/boost/range/detail/detail_str.hpp Normal file → Executable file
View File

0
include/boost/range/detail/difference_type.hpp Normal file → Executable file
View File

0
include/boost/range/detail/empty.hpp Normal file → Executable file
View File

0
include/boost/range/detail/end.hpp Normal file → Executable file
View File

0
include/boost/range/detail/implementation_help.hpp Normal file → Executable file
View File

0
include/boost/range/detail/iterator.hpp Normal file → Executable file
View File

0
include/boost/range/detail/remove_extent.hpp Normal file → Executable file
View File

0
include/boost/range/detail/sfinae.hpp Normal file → Executable file
View File

0
include/boost/range/detail/size.hpp Normal file → Executable file
View File

0
include/boost/range/detail/size_type.hpp Normal file → Executable file
View File

0
include/boost/range/detail/sizer.hpp Normal file → Executable file
View File

0
include/boost/range/detail/str_types.hpp Normal file → Executable file
View File

0
include/boost/range/detail/value_type.hpp Normal file → Executable file
View File

0
include/boost/range/detail/vc6/end.hpp Normal file → Executable file
View File

0
include/boost/range/detail/vc6/size.hpp Normal file → Executable file
View File

0
include/boost/range/difference_type.hpp Normal file → Executable file
View File

0
include/boost/range/distance.hpp Normal file → Executable file
View File

0
include/boost/range/empty.hpp Normal file → Executable file
View File

8
include/boost/range/end.hpp Normal file → Executable file
View File

@ -71,15 +71,15 @@ namespace range_detail
//////////////////////////////////////////////////////////////////////
template< typename T, std::size_t sz >
inline const T* range_end( const T (&a)[sz] )
inline const T* range_end( const T (&array)[sz] )
{
return range_detail::array_end<T,sz>( a );
return range_detail::array_end<T,sz>( array );
}
template< typename T, std::size_t sz >
inline T* range_end( T (&a)[sz] )
inline T* range_end( T (&array)[sz] )
{
return range_detail::array_end<T,sz>( a );
return range_detail::array_end<T,sz>( array );
}
#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) && \

0
include/boost/range/functions.hpp Normal file → Executable file
View File

0
include/boost/range/iterator.hpp Normal file → Executable file
View File

28
include/boost/range/iterator_range.hpp Normal file → Executable file
View File

@ -28,13 +28,11 @@
# endif
#endif // #ifndef BOOST_OLD_IOSTREAMS
#include <boost/assert.hpp>
#include <boost/iterator/iterator_traits.hpp>
#include <boost/type_traits/is_abstract.hpp>
#include <boost/range/functions.hpp>
#include <boost/range/iterator.hpp>
#include <boost/range/difference_type.hpp>
#include <boost/utility/enable_if.hpp>
#include <boost/iterator/iterator_traits.hpp>
#include <boost/assert.hpp>
#include <iterator>
#include <algorithm>
#ifndef _STLP_NO_IOSTREAMS
@ -167,12 +165,6 @@ namespace boost
//! iterator type
typedef IteratorT iterator;
private: // for return value of operator()()
typedef BOOST_DEDUCED_TYPENAME
boost::mpl::if_< boost::is_abstract<value_type>,
reference, value_type >::type abstract_value_type;
public:
iterator_range() : m_Begin( iterator() ), m_End( iterator() )
#ifndef NDEBUG
, singular( true )
@ -185,7 +177,7 @@ namespace boost
m_Begin(Begin), m_End(End)
#ifndef NDEBUG
, singular(false)
#endif
#endif
{}
//! Constructor from a Range
@ -210,7 +202,7 @@ namespace boost
template< class Range >
iterator_range( const Range& r, iterator_range_detail::const_range_tag ) :
m_Begin( impl::adl_begin( r ) ), m_End( impl::adl_end( r ) )
#ifndef NDEBUG
#ifndef NDEBUG
, singular(false)
#endif
{}
@ -219,7 +211,7 @@ namespace boost
template< class Range >
iterator_range( Range& r, iterator_range_detail::range_tag ) :
m_Begin( impl::adl_begin( r ) ), m_End( impl::adl_end( r ) )
#ifndef NDEBUG
#ifndef NDEBUG
, singular(false)
#endif
{}
@ -360,8 +352,8 @@ namespace boost
// When storing transform iterators, operator[]()
// fails because it returns by reference. Therefore
// operator()() is provided for these cases.
//
abstract_value_type operator()( difference_type at ) const
//
value_type operator()( difference_type at ) const
{
BOOST_ASSERT( at >= 0 && at < size() );
return m_Begin[at];
@ -390,15 +382,13 @@ namespace boost
bool singular;
#endif
#ifndef NDEBUG
public:
bool is_singular() const
{
#ifndef NDEBUG
return singular;
#else
return false;
#endif
}
#endif
protected:
//

0
include/boost/range/metafunctions.hpp Normal file → Executable file
View File

0
include/boost/range/mutable_iterator.hpp Normal file → Executable file
View File

0
include/boost/range/pointer.hpp Normal file → Executable file
View File

0
include/boost/range/rbegin.hpp Normal file → Executable file
View File

0
include/boost/range/reference.hpp Normal file → Executable file
View File

0
include/boost/range/rend.hpp Normal file → Executable file
View File

0
include/boost/range/result_iterator.hpp Normal file → Executable file
View File

0
include/boost/range/reverse_iterator.hpp Normal file → Executable file
View File

0
include/boost/range/reverse_result_iterator.hpp Normal file → Executable file
View File

0
include/boost/range/size.hpp Normal file → Executable file
View File

0
include/boost/range/size_type.hpp Normal file → Executable file
View File

14
include/boost/range/sub_range.hpp Normal file → Executable file
View File

@ -23,8 +23,6 @@
#include <boost/range/size_type.hpp>
#include <boost/range/difference_type.hpp>
#include <boost/assert.hpp>
#include <boost/type_traits/is_reference.hpp>
#include <boost/type_traits/remove_reference.hpp>
namespace boost
{
@ -43,12 +41,6 @@ namespace boost
typedef BOOST_DEDUCED_TYPENAME range_difference<ForwardRange>::type difference_type;
typedef BOOST_DEDUCED_TYPENAME range_size<ForwardRange>::type size_type;
typedef BOOST_DEDUCED_TYPENAME base::reference reference;
public: // for return value of front/back
typedef BOOST_DEDUCED_TYPENAME
boost::mpl::if_< boost::is_reference<reference>,
const BOOST_DEDUCED_TYPENAME boost::remove_reference<reference>::type&,
reference >::type const_reference;
public:
sub_range() : base()
@ -120,7 +112,7 @@ namespace boost
return base::front();
}
const_reference front() const
const value_type& front() const
{
return base::front();
}
@ -130,7 +122,7 @@ namespace boost
return base::back();
}
const_reference back() const
const value_type& back() const
{
return base::back();
}
@ -140,7 +132,7 @@ namespace boost
return base::operator[](sz);
}
const_reference operator[]( difference_type sz ) const
const value_type& operator[]( difference_type sz ) const
{
return base::operator[](sz);
}

0
include/boost/range/value_type.hpp Normal file → Executable file
View File

6
index.html Normal file → Executable file
View File

@ -22,7 +22,7 @@
</p>
<p>
Use, modification and distribution is subject to the Boost Software License, Version 1.0
(see <a href="http://www.boost.org/LICENSE_1_0.txt">
(see <a href=http://www.boost.org/LICENSE_1_0.txt>
http://www.boost.org/LICENSE_1_0.txt</a>).
</p>
@ -34,7 +34,7 @@
</p>
<ul>
<li> <a href="doc/intro.html">Introduction </a>
<li> <a href="doc/intro.html">Introduction </a></code>
<li><a href="doc/range.html">Range concepts:</a>
<ul>
@ -55,8 +55,6 @@
<li><a href="doc/mfc_atl.html">MFC/ATL mapping (courtesy of Shunsuke
Sogame)</a></li>
<li><a href="doc/portability.html">Portability</a>
<li><a href="doc/upgrading.html">Upgrading from Boost v.
1.34.*</a></li>
<li><a href="doc/faq.html">FAQ</a>
<li><a href="doc/history_ack.html">History and acknowledgment</a>

View File

@ -12,9 +12,9 @@ rule range-test ( name : includes * )
{
return [
run $(name).cpp /boost/test//boost_unit_test_framework/<link>static
:
:
: <toolset>gcc:<cxxflags>"-Wall -Wunused "
:
: $(includes)
] ;
}

0
test/adl_conformance.cpp Normal file → Executable file
View File

0
test/adl_conformance_no_using.cpp Normal file → Executable file
View File

0
test/algorithm_example.cpp Normal file → Executable file
View File

0
test/array.cpp Normal file → Executable file
View File

0
test/compat2.cpp Normal file → Executable file
View File

0
test/compat3.cpp Normal file → Executable file
View File

0
test/const_ranges.cpp Normal file → Executable file
View File

0
test/extension_mechanism.cpp Normal file → Executable file
View File

0
test/iterator_pair.cpp Normal file → Executable file
View File

0
test/iterator_range.cpp Normal file → Executable file
View File

0
test/mfc.cpp Normal file → Executable file
View File

0
test/partial_workaround.cpp Normal file → Executable file
View File

0
test/reversible_range.cpp Normal file → Executable file
View File

0
test/std_container.cpp Normal file → Executable file
View File

34
test/string.cpp Normal file → Executable file
View File

@ -137,7 +137,14 @@ void check_char()
BOOST_CHECK_EQUAL( str_end( char_s ), str_end1 );
BOOST_CHECK_EQUAL( str_empty( char_s ), (char_s == 0 || char_s[0] == char()) );
BOOST_CHECK_EQUAL( sz, std::char_traits<char>::length( char_s ) );
/*
BOOST_CHECK_EQUAL( str_begin( char_s2 ), char_s2 );
std::size_t sz2 = size( char_s2 );
const char* str_end12 = str_begin( char_s2 ) + sz;
BOOST_CHECK_EQUAL( str_end( char_s2 ), str_end12 );
BOOST_CHECK_EQUAL( empty( char_s2 ), (char_s2 == 0 || char_s2[0] == char()) );
BOOST_CHECK_EQUAL( sz2, std::char_traits<char>::length( char_s2 ) );
*/
BOOST_CHECK_EQUAL( str_begin( my_string ), my_string );
range_iterator<char_array_t>::type str_end2 = str_begin( my_string ) + str_size(my_string);
range_iterator<char_array_t>::type str_end3 = str_end(my_string);
@ -158,20 +165,6 @@ void check_char()
BOOST_CHECK( find_const( as_array( my_string ), to_search ) != str_end(my_string) );
BOOST_CHECK( find_const( as_array( my_const_string ), to_search ) != str_end(my_string) );
//
// Test that as_literal() always scan for null terminator
//
char an_array[] = "foo\0bar";
BOOST_CHECK_EQUAL( str_begin( an_array ), an_array );
BOOST_CHECK_EQUAL( str_end( an_array ), an_array + 3 );
BOOST_CHECK_EQUAL( str_size( an_array ), 3 );
const char a_const_array[] = "foobar\0doh";
BOOST_CHECK_EQUAL( str_begin( a_const_array ), a_const_array );
BOOST_CHECK_EQUAL( str_end( a_const_array ), a_const_array + 6 );
BOOST_CHECK_EQUAL( str_size( a_const_array ), 6 );
}
@ -179,6 +172,9 @@ void check_char()
void check_string()
{
check_char();
// check_char<volatile char>();
// check_char<const char>();
// check_char<const volatile char>();
#ifndef BOOST_NO_STD_WSTRING
typedef wchar_t* wchar_iterator_t;
@ -201,7 +197,13 @@ void check_string()
BOOST_CHECK_EQUAL( str_end(char_ws), (str_begin( char_ws ) + sz) );
BOOST_CHECK_EQUAL( str_empty( char_ws ), (char_ws == 0 || char_ws[0] == wchar_t()) );
BOOST_CHECK_EQUAL( sz, std::char_traits<wchar_t>::length( char_ws ) );
/*
std::size_t sz2 = size( char_ws2 );
BOOST_CHECK_EQUAL( str_begin( char_ws2 ), char_ws2 );
BOOST_CHECK_EQUAL( str_end( char_ws2 ), (begin( char_ws2 ) + sz2) );
BOOST_CHECK_EQUAL( empty( char_ws2 ), (char_ws2 == 0 || char_ws2[0] == wchar_t()) );
BOOST_CHECK_EQUAL( sz2, std::char_traits<wchar_t>::length( char_ws2 ) );
*/
wchar_t to_search = L'n';
BOOST_CHECK( find( char_ws, to_search ) != str_end(char_ws) );

0
test/sub_range.cpp Normal file → Executable file
View File