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

Function InsertOrUpdate

library/cpp/expression/expression.cpp:529–537  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

527}
528
529static size_t InsertOrUpdate(TVector<TString>& values, const TString& v) {
530 for (size_t i = 0, size = values.size(); i < size; ++i) {
531 if (values[i] == v) {
532 return i;
533 }
534 }
535 values.push_back(v);
536 return values.size() - 1;
537}
538
539struct TFrame {
540 TFrame() = delete;

Callers 1

BuildExpressionMethod · 0.70

Calls 2

sizeMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected