[libcxx-commits] [PATCH] D121523: [libc++][ranges] Implement ranges::count{, _if}
Nikolas Klauser via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Sat Apr 2 01:04:01 PDT 2022
philnik added inline comments.
================
Comment at: libcxx/test/std/algorithms/alg.nonmodifying/alg.count/ranges.count.pass.cpp:245
+ int a[] = {5, 5, 4, 3, 2, 1};
+ std::same_as<signed char> auto ret = std::ranges::count(DiffTypeIterator(a), DiffTypeIterator(a + 6), 4);
+ assert(ret == 1);
----------------
var-const wrote:
> Nit: `s/auto/decltype(auto)/` (here and below).
I think we should stick with `auto` and only use `decltype(auto)` if we want to check that a reference is returned.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D121523/new/
https://reviews.llvm.org/D121523
More information about the libcxx-commits
mailing list