[libcxx-commits] [PATCH] D155359: [libc++] Implement stringstream members of P0408R7 (Efficient Access to basic_stringbuf's Buffer)

Mark de Wever via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Sun Jul 16 06:27:43 PDT 2023


Mordante accepted this revision.
Mordante added a comment.
This revision is now accepted and ready to land.

In D155359#4503029 <https://reviews.llvm.org/D155359#4503029>, @pfusik wrote:

> (and I don't feel confident to use chained patches at this point)

Normally I would encourage you to try it. However in about 2 months we'll move the GitHub, so it's not that important.

LGTM with one request.



================
Comment at: libcxx/include/sstream:207
+    explicit basic_stringstream(const basic_string<char_type, traits_type, allocator_type>& s,
                                 ios_base::openmode which = ios_base::out|ios_base::in);
+    basic_stringstream(ios_base::openmode which, const allocator_type& a);                // C++20
----------------
Can you do this as a drive-by improvement?


================
Comment at: libcxx/include/sstream:1054
+    template <class _SAlloc>
+      requires (!is_same_v<_SAlloc, allocator_type>)
+    _LIBCPP_HIDE_FROM_ABI explicit basic_stringstream(const basic_string<_CharT, _Traits, _SAlloc>& __s,
----------------
Note to self, this one is constrained again.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D155359



More information about the libcxx-commits mailing list