MCPcopy Create free account
hub / github.com/catboost/catboost / FindIndex

Function FindIndex

util/generic/algorithm.h:195–200  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

193
194template <class C, class T>
195constexpr size_t FindIndex(C&& c, const T& x) {
196 using std::begin;
197 using std::end;
198 auto it = Find(begin(c), end(c), x);
199 return it == end(c) ? NPOS : (it - begin(c));
200}
201
202template <class C, class P>
203constexpr size_t FindIndexIf(C&& c, P p) {

Callers 8

containsMethod · 0.85
insertMethod · 0.85
eraseMethod · 0.85
containsMethod · 0.85
insertMethod · 0.85
eraseMethod · 0.85
Y_UNIT_TESTFunction · 0.85

Calls 3

FindFunction · 0.70
beginFunction · 0.70
endFunction · 0.70

Tested by

no test coverage detected