Created on 2025-07-15.00:00:00 last changed 3 days ago
Proposed resolution:
This wording is relative to N5014.
Modify [optional.ref.assign] as indicated:
template<class U> constexpr T& emplace(U&& u) noexcept(is_nothrow_constructible_v<T&, U>);-4- Constraints: […]
-5- Effects: Equivalent to: convert-ref-init-val(std::forward<U>(u)). -?- Returns: *val.
[ 2025-08-27; Reflector poll ]
Set status to Tentatively Ready after nine votes in favour during reflector poll.
The specification for optional<T&>::emplace in [optional.ref.assign] is not specifying the returned value via a Returns: element; however the function does indeed return something (a T&). Such a Returns: element is there for the primary template's `emplace` (cf. [optional.assign]).
History | |||
---|---|---|---|
Date | User | Action | Args |
2025-08-28 11:23:49 | admin | set | messages: + msg14972 |
2025-08-28 11:23:49 | admin | set | status: new -> ready |
2025-07-26 16:08:13 | admin | set | messages: + msg14907 |
2025-07-15 00:00:00 | admin | create |