This completes libc++'s implementation of P0879 "Constexpr for swap and swap related functions."
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2018/p0879r0.html
For the feature-macro adjustment, see
https://cplusplus.github.io/LWG/issue3256
Paths
| Differential D93661
[libc++] [P0879] constexpr std::sort, and add new tests for it ClosedPublic Authored by • Quuxplusone on Dec 21 2020, 12:54 PM.
Details
Summary This completes libc++'s implementation of P0879 "Constexpr for swap and swap related functions." For the feature-macro adjustment, see
Diff Detail
Event Timeline
• Quuxplusone mentioned this in D95248: [libc++][doc] Update the release notes.Jan 22 2021, 11:59 AM Comment Actions What's the status of this? Can you please rebase so CI runs (there were some CI issues during the holidays, I remember patch application failing). Ping me when this is ready for review, until then I'm marking as "changes requested". This revision now requires changes to proceed.Jan 25 2021, 9:10 AM • Quuxplusone added a parent revision: D93557: [libc++] [P0879] constexpr std::nth_element, and rewrite its tests.. Comment ActionsRebase on D93557, and indicate that we're now targeting release 13.0 not 12.0. ldionne added inline comments.
This revision now requires changes to proceed.Jan 28 2021, 8:02 AM • Quuxplusone added inline comments.
Comment Actions Rebase on main (after landing D94807) At least on OSX, this patch has no effect on the output of nm libc++.dylib or ls -l libc++.dylib. The effect on libc++.a is that it shrinks from 7968'560 to 7968'408 bytes; the diff in nm libc++.a | sort is this, which I don't see why this should happen at all, but anyway it's not a bad thing: 000000000001bfc0 T __ZNSt3__16locale5__impC2ERKS1_RKNS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEi 000000000001c6c0 T __ZNSt3__16locale5__impC1ERKS1_RKNS_12basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEEi 000000000001c6d0 T __ZNSt3__16locale5__impC2ERKS1_S3_i -000000000001d188 b __ZZNSt3__117iostream_categoryEvE1s -000000000001d190 b __ZGVZNSt3__117iostream_categoryEvE1s -000000000001d198 b __ZZNSt3__18ios_base5iwordEiE5error -000000000001d1a0 b __ZZNSt3__18ios_base5pwordEiE5error -000000000001d1a8 S __ZNSt3__18ios_base9__xindex_E +000000000001d180 b __ZZNSt3__117iostream_categoryEvE1s +000000000001d188 b __ZGVZNSt3__117iostream_categoryEvE1s +000000000001d190 b __ZZNSt3__18ios_base5iwordEiE5error +000000000001d198 b __ZZNSt3__18ios_base5pwordEiE5error +000000000001d1a0 S __ZNSt3__18ios_base9__xindex_E 000000000001d4e8 b __ZZNSt3__115future_categoryEvE3__f 000000000001d4f0 b __ZGVZNSt3__115future_categoryEvE3__f 000000000001e430 T __ZNSt3__16locale5__impC1ERKS1_S3_i 000000000001e440 T __ZNSt3__16locale5__impC2ERKS1_PNS0_5facetEl This revision is now accepted and ready to land.Feb 3 2021, 2:33 PM Closed by commit rG493f1407927c: [libc++] [P0879] constexpr std::sort (authored by • arthur.j.odwyer). · Explain WhyFeb 3 2021, 3:57 PM This revision was automatically updated to reflect the committed changes. danlark added inline comments.
• Quuxplusone added inline comments.
Revision Contents
Diff 313237 libcxx/docs/Cxx2aStatusIssuesStatus.csv
libcxx/docs/Cxx2aStatusPaperStatus.csv
libcxx/docs/FeatureTestMacroTable.rst
libcxx/include/algorithm
libcxx/include/version
libcxx/test/std/algorithms/alg.sorting/alg.sort/sort/sort_constexpr.pass.cpp
libcxx/test/std/algorithms/alg.sorting/alg.sort/sort/sort_constexpr_comp.pass.cpp
libcxx/test/std/language.support/support.limits/support.limits.general/algorithm.version.pass.cpp
libcxx/test/std/language.support/support.limits/support.limits.general/version.version.pass.cpp
libcxx/utils/generate_feature_test_macro_components.py
|
This comment was never correct. _Compare may be Pred&, or it may be __debug_less<Pred> without the &.