Add all() (#8445).

Includes test cases.
This commit is contained in:
Ahmed Charles
2014-02-22 18:02:07 -08:00
parent e8b37ccf10
commit 1b880102fe
4 changed files with 77 additions and 0 deletions

View File

@@ -202,6 +202,7 @@ public:
dynamic_bitset&amp; <a href="#flip2">flip</a>(size_type n);
dynamic_bitset&amp; <a href="#flip1">flip</a>();
bool <a href="#test">test</a>(size_type n) const;
bool <a href="#all">all</a>() const;
bool <a href="#any">any</a>() const;
bool <a href="#none">none</a>() const;
dynamic_bitset <a href="#op-not">operator~</a>() const;
@@ -1122,6 +1123,15 @@ size_type <a id="count">count</a>() const
set.<br />
<b>Throws:</b> nothing.
<hr />
<pre>
bool <a id="all">all</a>() const
</pre>
<b>Returns:</b> <tt>true</tt> if all bits in this bitset are set or
if <tt>size() == 0</tt>, and otherwise returns <tt>false</tt>.<br />
<b>Throws:</b> nothing.
<hr />
<pre>
bool <a id="any">any</a>() const