a577f786b6
* include/std/optional (Optional_base(const _Tp&)) (Optional_base(_Tp&&), using _Base::_Base): Remove. (optional(nullopt_t)): New. (optional(_Up&&)): Invoke base directly with in_place rather than creating a temporary, add default template argument, change constraints. (optional(const optional<_Up>&)): Invoke base directly with in_place, remove unnecessary constraints. (optional(optional<_Up>&& __t)): Likewise. (optional(in_place_t, _Args&&...)): New. (optional(in_place_t, initializer_list<_Up>, _Args&&...)): Likewise. (operator=(_Up&&)): Add default template argument, change constraints. (operator=(const optional<_Up>&)): Put is_same first in the constraints. (operator=(optional<_Up>&&)): Likewise. * testsuite/20_util/optional/assignment/5.cc: Add a test to verify assignment from something that can't be perfect-forwarded. * testsuite/20_util/optional/cons/value.cc: Add tests to verify that a nested optional is disengaged when constructed from a disengaged element type, and to verify that assignments from an engaged element type engage the optional. From-SVN: r239593 |
||
---|---|---|
.. | ||
algorithm | ||
any | ||
array | ||
atomic | ||
bitset | ||
chrono | ||
codecvt | ||
complex | ||
condition_variable | ||
deque | ||
forward_list | ||
fstream | ||
functional | ||
future | ||
iomanip | ||
ios | ||
iosfwd | ||
iostream | ||
istream | ||
iterator | ||
limits | ||
list | ||
locale | ||
map | ||
memory | ||
mutex | ||
numeric | ||
optional | ||
ostream | ||
queue | ||
random | ||
ratio | ||
regex | ||
scoped_allocator | ||
set | ||
shared_mutex | ||
sstream | ||
stack | ||
stdexcept | ||
streambuf | ||
string | ||
string_view | ||
system_error | ||
thread | ||
tuple | ||
type_traits | ||
typeindex | ||
unordered_map | ||
unordered_set | ||
utility | ||
valarray | ||
variant | ||
vector |