add missing constexpr to optional::value_or
[Credit to cpplearner] Differential Revision: https://reviews.llvm.org/D27850 git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@304813 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -897,7 +897,7 @@ public:
|
||||
|
||||
template <class _Up>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
value_type value_or(_Up&& __v) &&
|
||||
constexpr value_type value_or(_Up&& __v) &&
|
||||
{
|
||||
static_assert(is_move_constructible_v<value_type>,
|
||||
"optional<T>::value_or: T must be move constructible");
|
||||
|
||||
Reference in New Issue
Block a user