[libcxx-commits] [PATCH] D126193: [libc++][ranges] Implement `ranges::clamp`

Konstantin Varlamov via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Sat Jul 30 16:06:16 PDT 2022


var-const updated this revision to Diff 448819.
var-const marked an inline comment as done.
var-const added a comment.

- Fix a bug where the result of applying a projection could lose its value category and add a test;
- fix incorrect assertion checking that `low <= high` and add an assertion test for it;
- add SFINAE tests;
- add `ranges::clamp` to the relevant `robust` test suites;
- address the existing feedback.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D126193

Files:
  libcxx/docs/Status/RangesAlgorithms.csv
  libcxx/include/CMakeLists.txt
  libcxx/include/__algorithm/clamp.h
  libcxx/include/__algorithm/ranges_clamp.h
  libcxx/include/algorithm
  libcxx/include/module.modulemap.in
  libcxx/test/libcxx/algorithms/ranges_robust_against_copying_comparators.pass.cpp
  libcxx/test/libcxx/algorithms/ranges_robust_against_copying_projections.pass.cpp
  libcxx/test/libcxx/private_headers.verify.cpp
  libcxx/test/std/algorithms/alg.sorting/alg.clamp/assert.ranges_clamp.pass.cpp
  libcxx/test/std/algorithms/alg.sorting/alg.clamp/ranges.clamp.pass.cpp
  libcxx/test/std/algorithms/ranges_robust_against_nonbool_predicates.pass.cpp
  libcxx/test/std/algorithms/ranges_robust_against_omitting_invoke.pass.cpp
  libcxx/test/std/library/description/conventions/customization.point.object/niebloid.compile.pass.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D126193.448819.patch
Type: text/x-patch
Size: 17445 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20220730/fcee46c3/attachment-0001.bin>


More information about the libcxx-commits mailing list