[libcxx-commits] [PATCH] D121964: [libc++][ranges] Implement ranges::binary_search and ranges::{lower, upper}_bound

Eric Fiselier via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Sat Jun 11 07:59:04 PDT 2022


EricWF added a comment.

Amazing tests. Unfortunately, this change causes breakages in `std::lower_bound` because `ranges::distance` is not a drop-in replacement for `std::distance`, and that breaks existing code as it switches between C++17 and C++20.
I'm working on minimizing a reproducer.



================
Comment at: libcxx/test/std/algorithms/alg.sorting/alg.binary.search/binary.search/ranges.binary_search.pass.cpp:8
+//===----------------------------------------------------------------------===//
+
+// UNSUPPORTED: c++03, c++11, c++14, c++17
----------------
Great tests BTW.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D121964



More information about the libcxx-commits mailing list