Replace the references to the SGI documentation

This commit just removes all the links to the SGI documentation and
replaces most of them with links to cppreference.com. The SGI docs were
likely used by Jeremy Siek at the time because they were a good and
clear reference. But we have cppreference.com now, which is much better.
And, in the event it disappears, we can still revert this commit.

Some links have simply been removed (e.g. those to the documentation of
basic_string, which really didn't seem opportune).
This commit is contained in:
Gennaro Prota
2025-06-21 16:15:19 +02:00
parent cc2e543137
commit 8d2b37a8f8

View File

@@ -15,30 +15,6 @@
http://www.boost.org/LICENSE_1_0.txt)
-->
<!--
Copyright (c) 1996-1999
Silicon Graphics Computer Systems, Inc.
Permission to use, copy, modify, distribute and sell this software
and its documentation for any purpose is hereby granted without fee,
provided that the above copyright notice appears in all copies and
that both that copyright notice and this permission notice appear
in supporting documentation. Silicon Graphics makes no
representations about the suitability of this software for any
purpose. It is provided "as is" without express or implied warranty.
Copyright (c) 1994
Hewlett-Packard Company
Permission to use, copy, modify, distribute and sell this software
and its documentation for any purpose is hereby granted without fee,
provided that the above copyright notice appears in all copies and
that both that copyright notice and this permission notice appear
in supporting documentation. Hewlett-Packard Company makes no
representations about the suitability of this software for any
purpose. It is provided "as is" without express or implied warranty.
-->
<head>
<title>dynamic_bitset&lt;Block, Allocator&gt;</title>
<link rel="stylesheet" type="text/css" href="../../rst.css" />
@@ -90,7 +66,7 @@ of bits in the set can change at runtime.</p>
<p>The <tt>dynamic_bitset</tt> class is nearly identical to the
<a href=
"https://boost.org/sgi/stl/bitset.html"><tt>std::bitset</tt></a>
"https://en.cppreference.com/w/cpp/utility/bitset"><tt>std::bitset</tt></a>
class. The difference is that the size of a
<tt>dynamic_bitset</tt> (the number of bits) can change at runtime,
whereas the size of a <tt>std::bitset</tt> is specified at compile-time
@@ -344,7 +320,7 @@ input/output and some bitwise operations).
<h3><a id="rationale">Rationale</a></h3>
<p>
<tt>dynamic_bitset</tt> is not a <a href=
"https://boost.org/sgi/stl/Container.html">Container</a> and
"https://en.cppreference.com/w/cpp/named_req/Container">Container</a> and
does not provide iterators for the following reason:
</p>
@@ -359,8 +335,8 @@ people try to use iterators from <tt>std::vector&lt;bool&gt;</tt>
with a Standard algorithm such as <tt>std::search</tt>. The
<tt>std::search</tt> requirements say that the iterator must be a
<a href=
"https://boost.org/sgi/stl/ForwardIterator.html">Forward
Iterator</a>, but the <tt>std::vector&lt;bool&gt;::iterator</tt>
"https://en.cppreference.com/w/cpp/named_req/ForwardIterator">LegacyForwardIterator</a>,
but the <tt>std::vector&lt;bool&gt;::iterator</tt>
does not meet this requirement because of the proxy reference.
Depending on the implementation, they may or not be a compile
error or even a run-time error due to this misuse. For further
@@ -370,8 +346,7 @@ by not pretending to be a container.</li>
</ul>
<p>Some people prefer the name "toggle" to "flip". The name
"flip" was chosen because that is the name used in <a href=
"https://boost.org/sgi/stl/bitset.html"><tt>std::bitset</tt></a>.
"flip" was chosen because that is the name used in std::bitset.
In fact, most of the function names for <tt>dynamic_bitset</tt>
were chosen for this reason.</p>
@@ -413,14 +388,11 @@ in the header <a href=
</table>
<h3><a id="concepts-modeled">Concepts modeled</a></h3>
<a href=
"https://boost.org/sgi/stl/Assignable.html">Assignable</a>, <a
"https://en.cppreference.com/w/cpp/named_req/CopyAssignable">CopyAssignable</a>, <a
href=
"https://boost.org/sgi/stl/DefaultConstructible.html">Default
Constructible</a>, <a href=
"https://boost.org/sgi/stl/EqualityComparable.html">Equality
Comparable</a>, <a href=
"https://boost.org/sgi/stl/LessThanComparable.html">LessThan
Comparable</a>.
"https://en.cppreference.com/w/cpp/named_req/DefaultConstructible">DefaultConstructible</a>, <a href=
"https://en.cppreference.com/w/cpp/named_req/EqualityComparable">EqualityComparable</a>, <a href=
"https://en.cppreference.com/w/cpp/named_req/LessThanComparable">LessThanComparable</a>.
<h3><a id="type-requirements">Type requirements</a></h3>
@@ -584,8 +556,7 @@ for this bitset is a default-constructed object of type
<b>Throws:</b> Nothing unless the default constructor of
<tt>Allocator</tt> throws an exception.<br />
(Required by <a href=
"https://boost.org/sgi/stl/DefaultConstructible.html">Default
Constructible</a>.)
"https://en.cppreference.com/w/cpp/named_req/DefaultConstructible">DefaultConstructible</a>.)
<hr />
<pre>
@@ -652,7 +623,7 @@ allocator in <tt>x</tt>. <br />
(<tt>std::bad_alloc</tt> if
<tt>Allocator=std::allocator</tt>).<br />
(Required by <a href=
"https://boost.org/sgi/stl/Assignable.html">Assignable</a>.)
"https://en.cppreference.com/w/cpp/named_req/CopyConstructible">CopyConstructible</a>.)
<hr />
<pre>
@@ -735,8 +706,8 @@ position <tt>(b * bits_per_block + i)</tt> in the bitset (where
<br />
<b>Requires:</b> <tt>BlockInputIterator</tt> must be either an
integral type or a model of <a href=
"https://boost.org/sgi/stl/InputIterator.html">Input
Iterator</a> whose <tt>value_type</tt> is the same type as
"https://en.cppreference.com/w/cpp/named_req/InputIterator">LegacyInputIterator</a>
whose <tt>value_type</tt> is the same type as
<tt>Block</tt>.<br /> <b>Throws:</b> An allocation error if
memory is exhausted (<tt>std::bad_alloc</tt> if
<tt>Allocator=std::allocator</tt>).<br />
@@ -745,12 +716,9 @@ memory is exhausted (<tt>std::bad_alloc</tt> if
<pre>
template&lt;typename Char, typename Traits, typename Alloc&gt;
explicit
<a id="cons3">dynamic_bitset</a>(const <a href=
"https://boost.org/sgi/stl/basic_string.html">std::basic_string</a>&lt;Char,Traits,Alloc&gt;&amp; s,
<a id="cons3">dynamic_bitset</a>(const std::basic_string&lt;Char,Traits,Alloc&gt;&amp; s,
typename std::basic_string&lt;CharT, Traits, Alloc&gt;::size_type pos = 0,
typename std::basic_string&lt;CharT, Traits, Alloc&gt;::size_type n = <a
href=
"https://boost.org/sgi/stl/basic_string.html">std::basic_string</a>&lt;Char,Traits,Alloc&gt;::npos,
typename std::basic_string&lt;CharT, Traits, Alloc&gt;::size_type n = std::basic_string&lt;Char,Traits,Alloc&gt;::npos,
const Allocator&amp; alloc = Allocator())
</pre>
@@ -809,7 +777,7 @@ dynamic_bitset&amp; <a id=
<b>Returns:</b> <tt>*this</tt>.<br />
<b>Throws:</b> nothing. <br />
(Required by <a href=
"https://boost.org/sgi/stl/Assignable.html">Assignable</a>.)
"https://en.cppreference.com/w/cpp/named_req/CopyAssignable">CopyAssignable</a>.)
<hr />
<pre>
@@ -912,8 +880,8 @@ for (; first != last; ++first)
<b>Requires:</b> The <tt>BlockInputIterator</tt> type must be a
model of <a href=
"https://boost.org/sgi/stl/InputIterator.html">Input
Iterator</a> and the <tt>value_type</tt> must be the same type as
"https://en.cppreference.com/w/cpp/named_req/InputIterator">LegacyInputIterator</a>
and the <tt>value_type</tt> must be the same type as
<tt>Block</tt>.<br />
<b>Throws:</b> An allocation error if memory is exhausted
(<tt>std::bad_alloc</tt> if
@@ -1401,9 +1369,7 @@ rhs.size()</tt> and if for all <tt>i</tt> in the range
<tt>[0,rhs.size())</tt>, <tt>(*this)[i] == rhs[i]</tt>. Otherwise
returns <tt>false</tt>.<br />
<b>Throws:</b> nothing.<br />
(Required by <a href=
"https://boost.org/sgi/stl/EqualityComparable.html">Equality
Comparable</a>.)
(Required by <tt>EqualityComparable</tt>.)
<hr />
<pre>
@@ -1413,9 +1379,7 @@ bool <a id=
<b>Returns:</b> <tt>!((*this) == rhs)</tt><br />
<b>Throws:</b> nothing.<br />
(Required by <a href=
"https://boost.org/sgi/stl/EqualityComparable.html">Equality
Comparable</a>.)
(Required by <tt>EqualityComparable</tt>.)
<hr />
<pre>
@@ -1425,13 +1389,9 @@ bool <a id=
<b>Returns:</b> <tt>true</tt> if this bitset is lexicographically
less than <tt>rhs</tt>, and returns <tt>false</tt> otherwise.
(See the description of <a href=
"https://boost.org/sgi/stl/lexicographical_compare.html">lexicographical_compare</a>
for a definition of lexicographic ordering). <br />
<br />
<b>Throws:</b> nothing.<br />
(Required by <a href=
"https://boost.org/sgi/stl/LessThanComparable.html">Less Than
Comparable</a>.)
(Required by <tt>LessThanComparable</tt>.)
<hr />
<pre>
@@ -1442,9 +1402,7 @@ bool <a id=
<b>Returns:</b> <tt>!((*this) &lt; rhs || (*this) ==
rhs)</tt><br />
<b>Throws:</b> nothing.<br />
(Required by <a href=
"https://boost.org/sgi/stl/LessThanComparable.html">Less Than
Comparable</a>.)
(Required by <tt>LessThanComparable</tt>.)
<hr />
<pre>
@@ -1454,9 +1412,7 @@ bool <a id=
<b>Returns:</b> <tt>(*this) &lt; rhs || (*this) == rhs</tt><br />
<b>Throws:</b> nothing.<br />
(Required by <a href=
"https://boost.org/sgi/stl/LessThanComparable.html">Less Than
Comparable</a>.)
(Required by <tt>LessThanComparable</tt>.)
<hr />
<pre>
@@ -1466,9 +1422,7 @@ bool <a id=
<b>Returns:</b> <tt>(*this) &gt; rhs || (*this) == rhs</tt><br />
<b>Throws:</b> nothing.<br />
(Required by <a href=
"https://boost.org/sgi/stl/LessThanComparable.html">Less Than
Comparable</a>.)
(Required by <tt>LessThanComparable</tt>.)
<hr />
<h3><a id="non-member-functions">Non-member functions</a></h3>
@@ -1526,8 +1480,7 @@ bitsets <tt>a</tt> and <tt>b</tt>.<br />
template &lt;typename CharT, typename Alloc&gt;
void <a id=
"to_string">to_string</a>(const dynamic_bitset&lt;Block, Allocator&gt;&amp; b,
<a href=
"https://boost.org/sgi/stl/basic_string.html">std::basic_string</a>&lt;Char,Traits,Alloc&gt;&amp; s)
std::basic_string&lt;Char,Traits,Alloc&gt;&amp; s)
</pre>
<b>Effects:</b> Copies a representation of <tt>b</tt> into the
@@ -1565,8 +1518,8 @@ block <tt>bval</tt> written, the bit <tt>(bval &gt;&gt; i) &amp;
+ i)</tt> in the bitset.<br />
<b>Requires:</b> The type <tt>BlockOutputIterator</tt> must be a
model of <a href=
"https://boost.org/sgi/stl/OutputIterator.html">Output
Iterator</a> and its <tt>value_type</tt> must be the same type as
"https://en.cppreference.com/w/cpp/named_req/OutputIterator">LegacyOutputIterator</a>
and its <tt>value_type</tt> must be the same type as
<tt>Block</tt>. Further, the size of the output range must be
greater or equal <tt>b.num_blocks()</tt>.
@@ -1581,8 +1534,8 @@ void <a id=
<b>Effects:</b> Reads blocks from the iterator range into the
bitset. <br />
<b>Requires:</b> The type <tt>BlockIterator</tt> must be a model
of <a href="https://boost.org/sgi/stl/InputIterator.html">Input
Iterator</a> and its <tt>value_type</tt> must be the same type as
of <a href="https://en.cppreference.com/w/cpp/named_req/InputIterator">LegacyInputIterator</a>
and its <tt>value_type</tt> must be the same type as
<tt>Block</tt>. The size of the iterator range must be less or
equal to <tt>b.num_blocks()</tt>.
@@ -1762,12 +1715,6 @@ nested class <tt>reference</tt>.
</ul>
<hr />
<h3><a id="see-also">See also</a></h3>
<tt><a href=
"https://boost.org/sgi/stl/bitset.html">std::bitset</a></tt>,
<tt><a href=
"https://boost.org/sgi/stl/Vector.html">std::vector</a></tt>,
<h3><a id="acknowledgements">Acknowledgements</a></h3>