mirror of
https://github.com/boostorg/optional.git
synced 2025-07-22 16:47:15 +02:00
none_t is no loner constructible from literal 0
This caused problems because: optional<T> o = 0; always worked. But often it would create an uninitialized optional.
This commit is contained in:
@ -30,7 +30,7 @@
|
||||
<p>
|
||||
Type <code class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></code> is
|
||||
<a href="http://www.sgi.com/tech/stl/EqualityComparable.html" target="_top"><code class="computeroutput"><span class="identifier">EqualityComparable</span></code></a> whenever <code class="computeroutput"><span class="identifier">T</span></code> is <a href="http://www.sgi.com/tech/stl/EqualityComparable.html" target="_top"><code class="computeroutput"><span class="identifier">EqualityComparable</span></code></a>. Two optional
|
||||
objects containing a value compare in the same as their contained values.
|
||||
objects containing a value compare in the same way as their contained values.
|
||||
The uninitialized state of <code class="computeroutput"><span class="identifier">optional</span><span class="special"><</span><span class="identifier">T</span><span class="special">></span></code>
|
||||
is treated as a distinct value, equal to itself, and unequal to any value
|
||||
of type <code class="computeroutput"><span class="identifier">T</span></code>:
|
||||
|
Reference in New Issue
Block a user