[libcxx-commits] [libcxx] [libc++] Implement LWG4406: value_or return statement is inconsistent with Mandates (PR #189568)
William Tran-Viet via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Mar 31 19:23:12 PDT 2026
================
@@ -49,6 +49,19 @@ constexpr bool test() {
assert(x == 10);
}
+ // LWG3424: return type is remove_cv_t<T>
+ {
+ const std::expected<const int, int> e(5);
----------------
smallp-o-p wrote:
Pedantically, we should also test for `const volatile T`, `volatile T`.
https://github.com/llvm/llvm-project/pull/189568
More information about the libcxx-commits
mailing list