From a4bf12cacabd18b236b1b700721b3c5cb83ba1e0 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Mon, 13 Mar 2023 13:35:49 -0700 Subject: [PATCH] Weakly_unwrappable should use _Allow_inheriting_unwrap_v ... so as not to require `_Prevent_inheriting_unwrap`. The intent of the unwrapping design is that `_Prevent_inheriting_unwrap` is optional. --- stl/inc/xutility | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/stl/inc/xutility b/stl/inc/xutility index d4b5112f2de..51cdd466fe8 100644 --- a/stl/inc/xutility +++ b/stl/inc/xutility @@ -2287,9 +2287,8 @@ namespace ranges { using sentinel_t = decltype(_RANGES end(_STD declval<_Rng&>())); template - concept _Weakly_unwrappable = - same_as::_Prevent_inheriting_unwrap, remove_cvref_t<_Wrapped>> - && requires(_Wrapped&& _Wr) { _STD forward<_Wrapped>(_Wr)._Unwrapped(); }; + concept _Weakly_unwrappable = _Allow_inheriting_unwrap_v> + && requires(_Wrapped&& _Wr) { _STD forward<_Wrapped>(_Wr)._Unwrapped(); }; template concept _Weakly_unwrappable_sentinel = _Weakly_unwrappable&>;