[libcxx-commits] [PATCH] D155701: [libc++][expected] Implement LWG3836

Mark de Wever via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Sat Jul 29 06:25:30 PDT 2023


Mordante added a comment.

In D155701#4535643 <https://reviews.llvm.org/D155701#4535643>, @yronglin wrote:

> Thanks for your review and sorry for the very late reply!

No problem, I was quite busy with the release the last week.



================
Comment at: libcxx/docs/Status/Cxx23Issues.csv:293
 "`3833 <https://wg21.link/LWG3833>`__","Remove specialization ``template<size_t N> struct formatter<const charT[N], charT>``","February 2023","|Complete|","17.0","|format|"
-"`3836 <https://wg21.link/LWG3836>`__","``std::expected<bool, E1>`` conversion constructor ``expected(const expected<U, G>&)`` should take precedence over ``expected(U&&)`` with operator ``bool``","February 2023","","",""
+"`3836 <https://wg21.link/LWG3836>`__","``std::expected<bool, E1>`` conversion constructor ``expected(const expected<U, G>&)`` should take precedence over ``expected(U&&)`` with operator ``bool``","February 2023","|Complete|","17.0",""
 "`3843 <https://wg21.link/LWG3843>`__","``std::expected<T,E>::value() &`` assumes ``E`` is copy constructible","February 2023","|Complete|","17.0",""
----------------
We missed the LLVM 17 deadline.


================
Comment at: libcxx/include/__expected/expected.h:181
+                       _Not<is_convertible<const expected<_Up, _OtherErr>&, _Tp>>,
+                       _Not<is_convertible<const expected<_Up, _OtherErr>&&, _Tp>> > >,
+
----------------
yronglin wrote:
> Mordante wrote:
> > This was needed for C++03.
> Thanks for the tip, does the header file for C++23 also need this?
In C++23 we can use `>>>>`.


================
Comment at: libcxx/include/optional:735
+        _IsNotSame<__remove_cvref_t<_Up>, optional>::value && 
+        // LWG3836
+        (!is_same_v<remove_cv_t<_Tp>, bool> || !__is_std_optional<__remove_cvref_t<_Up>>::value),
----------------
Mordante wrote:
> likewise
I still see the LWG number.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D155701/new/

https://reviews.llvm.org/D155701



More information about the libcxx-commits mailing list