[libcxx-commits] [libcxx] [libc++][string] P3044R2: sub-`string_view` from `string` (PR #147095)

Hristo Hristov via libcxx-commits libcxx-commits at lists.llvm.org
Mon Sep 22 00:40:14 PDT 2025


================
@@ -1763,6 +1765,13 @@ public:
   }
 #  endif
 
+#  if _LIBCPP_STD_VER >= 26
+  [[nodiscard]] _LIBCPP_HIDE_FROM_ABI constexpr basic_string_view<_CharT, _Traits>
+  subview(size_type __pos = 0, size_type __n = npos) const {
+    return basic_string_view<_CharT, _Traits>(*this).subview(__pos, __n);
+  }
+#  endif
----------------
H-G-Hristov wrote:

For some reason GH failed to pick up this change and display it correctly at least in my browser. It should be fine now after I restarted the browser.

https://github.com/llvm/llvm-project/pull/147095


More information about the libcxx-commits mailing list