[libcxx-commits] [PATCH] D130057: [libc++][ranges][NFC] Test that range algorithms support iterators requiring `iter_move`.

Hui via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Tue Jul 19 03:09:50 PDT 2022


huixie90 accepted this revision.
huixie90 added inline comments.


================
Comment at: libcxx/test/std/algorithms/ranges_robust_against_proxy_iterators.pass.cpp:119
+    test(std::ranges::transform, in, out, std::identity{});
+    test(std::ranges::transform, in, in2, out, binary_func);
+  }
----------------
`binary_func` seem to return `bool` and `transform` would write these `bool`s to the output. I guess it works for the `int` overload because `bool` is convertible to `int`. But for `MoveOnly` overload, it probably doesn't work. 



Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D130057



More information about the libcxx-commits mailing list