[libcxx-commits] [PATCH] D93074: [libc++] Split allocator_traits and pointer_traits out of <memory>
Louis Dionne via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Thu Dec 10 15:46:08 PST 2020
ldionne created this revision.
Herald added subscribers: jkorous, mgorny.
ldionne requested review of this revision.
Herald added a project: libc++.
Herald added a subscriber: libcxx-commits.
Herald added a reviewer: libc++.
In addition to making the code a lot easier to grasp by localizing many
helper functions to the only file where they are actually needed, this
will allow creating helper functions that depend on allocator_traits
outside of <memory>.
This is done as part of implementing array support in allocate_shared,
which requires non-trivial array initialization algorithms that would be
better to keep out of <memory> for sanity. It's also a first step towards
splitting up our monolithic headers into finer grained ones, which will
make it easier to reuse functionality across the library. For example,
it's just weird that we had to define `addressof` inside <type_traits>
to avoid circular dependencies -- instead it's better to implement those
in true helper headers.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D93074
Files:
libcxx/include/CMakeLists.txt
libcxx/include/__memory/allocator_traits.h
libcxx/include/__memory/base.h
libcxx/include/__memory/pointer_traits.h
libcxx/include/exception
libcxx/include/iterator
libcxx/include/memory
libcxx/include/type_traits
libcxx/test/std/containers/sequences/vector/vector.cons/copy.move_only.verify.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D93074.311043.patch
Type: text/x-patch
Size: 60356 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20201210/826c3bcb/attachment-0001.bin>
More information about the libcxx-commits
mailing list