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

Method rfind

util/generic/string_ut.cpp:578–596  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

576 }
577#if 0
578 void rfind() {
579 // 21.3.6.2
580 TStringType s(Data.one_two_three_one_two_three());
581
582 UNIT_ASSERT(s.rfind(Data.two()) == 18);
583 UNIT_ASSERT(s.rfind(Data.two(), 0) == TStringType::npos);
584 UNIT_ASSERT(s.rfind(Data.two(), 11) == 4);
585 UNIT_ASSERT(s.rfind(*Data.w()) == 19);
586
587 TStringType test(Data.aba());
588
589 UNIT_ASSERT(test.rfind(Data.a(), 2, 1) == 2);
590 UNIT_ASSERT(test.rfind(Data.a(), 1, 1) == 0);
591 UNIT_ASSERT(test.rfind(Data.a(), 0, 1) == 0);
592
593 UNIT_ASSERT(test.rfind(*Data.a(), 2) == 2);
594 UNIT_ASSERT(test.rfind(*Data.a(), 1) == 0);
595 UNIT_ASSERT(test.rfind(*Data.a(), 0) == 0);
596 }
597#endif
598 void find_last_not_of() {
599 // 21.3.6.6

Callers

nothing calls this directly

Calls 5

twoMethod · 0.80
abaMethod · 0.80
wMethod · 0.45
aMethod · 0.45

Tested by

no test coverage detected