Makes the following operations constexpr: * `std::swap(optional, optional)` * `optional(optional<U> const&)` * `optional(optional<U>&&)` * `~optional()` * `operator=(nullopt_t)` * `operator=(U&&)` * `operator=(optional<U> const&)` * `operator=(optional<U>&&)` * `emplace(Args&&...)` * `emplace(initializer_list<U>, Args&&...)` * `swap(optional&)` * `reset()` P2231 has been accepted by plenary, with the committee recommending implementers retroactively apply to C++20. It's necessary for us to implement _`semiregular-box`_ and _`non-propagating-cache`_, both of which are required for ranges (otherwise we'll need to reimplement `std::optional` with these members `constexpr`ified). Differential Revision: https://reviews.llvm.org/D102119 |
||
|---|---|---|
| .. | ||
| optional.bad_optional_access | ||
| optional.comp_with_t | ||
| optional.hash | ||
| optional.nullops | ||
| optional.nullopt | ||
| optional.object | ||
| optional.relops | ||
| optional.specalg | ||
| optional.syn | ||
| iterator_concept_conformance.compile.pass.cpp | ||