ΒΆtemplate <typename R, typename UnaryPredicate>
auto count_if(R&& Range, UnaryPredicate P) ->
typename std::iterator_traits<
decltype(adl_begin(
Range))>::difference_type
template <typename R, typename UnaryPredicate>
auto count_if(R&& Range, UnaryPredicate P) ->
typename std::iterator_traits<
decltype(adl_begin(
Range))>::difference_type
Description
Wrapper function around std::count_if to count the number of times an element satisfying a given predicate occurs in a range.
Declared at: llvm/include/llvm/ADT/STLExtras.h:1256
Templates
- R
- UnaryPredicate
Parameters
- R&& Range
- UnaryPredicate P