[libcxx-commits] [libcxx] [libc++] Optimize copy construction and assignment of __tree (PR #151304)

Louis Dionne via libcxx-commits libcxx-commits at lists.llvm.org
Wed Jul 30 07:36:25 PDT 2025


================

----------------
ldionne wrote:

Comments about the tests, not attached to this file:
1. I don't think we even test assignment into an empty map -- we should
2. I don't think we test assignment FROM an empty map -- we should
3. Also a test where the leaf nodes are at different positions
4. There's probably more stuff missing, we might want to overhaul these tests

Many of these comments also apply to copy construction, and copy-construction using a map and an allocator. They also apply to `set` and the unordered variants, obviously.

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


More information about the libcxx-commits mailing list