[libcxx-commits] [PATCH] D105795: [libcxx][algorithms] adds ranges::lower_bound and ranges::upper_bound
Tim Song via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Jul 13 12:51:51 PDT 2021
tcanens added inline comments.
================
Comment at: libcxx/include/__algorithm/lower_bound.h:95
+ _Ip operator()(_Ip __first, _Sp __last, const _Tp& __value, _Comp __comp = {}, _Proj __proj = {}) const {
+ auto __pred = [&__value, &__comp](const auto& __proj_elem){
+ return _VSTD::invoke(__comp, __proj_elem, __value);
----------------
`indirect_strict_weak_order` doesn't guarantee that the projected element is comparable after it's been turned into a const lvalue.
// `boolean-testable` // doesn't guarantee that it can be copied or moved.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105795/new/
https://reviews.llvm.org/D105795
More information about the libcxx-commits
mailing list