Created on 2016-07-02.00:00:00 last changed 90 months ago
Proposed resolution:
This wording is relative to N4594.
Modify [optional.object.observe] as indicated:
constexpr T const* operator->() const; constexpr T* operator->();-1- Requires: *this contains a value.
-2- Returns: val. -3- Throws: Nothing. -4- Remarks:Unless T is a user-defined type with overloaded unary operator&, tThese functions shall be constexpr functions.
[ 2016-07 Chicago ]
Monday: P0 - tentatively ready
optional<T>::operator->s are constrained to be constexpr functions only when T is not a type with an overloaded unary operator&. This constrain comes from the need to use addressof (or a similar mechanism), and the inability to do so in a constant expression in C++14. Given that addressof is now constexpr, this constrain is no longer needed.
History | |||
---|---|---|---|
Date | User | Action | Args |
2017-07-30 20:15:43 | admin | set | status: wp -> c++17 |
2016-11-14 03:59:28 | admin | set | status: pending -> wp |
2016-11-14 03:55:22 | admin | set | status: ready -> pending |
2016-08-01 18:34:48 | admin | set | messages: + msg8280 |
2016-08-01 18:34:48 | admin | set | status: new -> ready |
2016-07-03 18:13:32 | admin | set | messages: + msg8238 |
2016-07-02 00:00:00 | admin | create |