[libcxx-commits] [PATCH] D100216: [libc++] Split a few things out of <memory>

Marek Kurdej via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Fri Apr 9 11:53:41 PDT 2021


curdeius added inline comments.


================
Comment at: libcxx/include/__memory/temporary_buffer.h:29
+pair<_Tp*, ptrdiff_t>
+get_temporary_buffer(ptrdiff_t __n) _NOEXCEPT
+{
----------------
Sidenote, why isn't it guarded with `	#if _LIBCPP_STD_VER <= 14 || defined(_LIBCPP_ENABLE_CXX17_REMOVED_xyz)` like `auto_ptr`?


================
Comment at: libcxx/include/memory:685
 #include <__memory/allocator_traits.h>
+#include <__memory/auto_ptr.h>
 #include <__memory/base.h>
----------------
IMO there would be a "real" benefit of splitting those headers if their inclusion were guarded by `	#if _LIBCPP_STD_VER <= 14 || defined(_LIBCPP_ENABLE_CXX17_REMOVED_xyz)`. WDYT?
That cannot apply to allocator of course as not all of it was removed in C++20.

By real, I mean more than just going down with the line count.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D100216



More information about the libcxx-commits mailing list