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

Method find_last_of

util/generic/string_ut.cpp:560–576  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

558 }
559
560 void find_last_of() {
561 // 21.3.6.4
562 TStringType s(Data_.one_two_three_one_two_three());
563
564 UNIT_ASSERT(s.find_last_of(Data_.abcde()) == 26);
565 UNIT_ASSERT(s.find_last_of(TStringType(Data_.abcde())) == 26);
566
567 TStringType test(Data_.aba());
568
569 UNIT_ASSERT(test.find_last_of(Data_.a(), 2, 1) == 2);
570 UNIT_ASSERT(test.find_last_of(Data_.a(), 1, 1) == 0);
571 UNIT_ASSERT(test.find_last_of(Data_.a(), 0, 1) == 0);
572
573 UNIT_ASSERT(test.find_last_of(*Data_.a(), 2) == 2);
574 UNIT_ASSERT(test.find_last_of(*Data_.a(), 1) == 0);
575 UNIT_ASSERT(test.find_last_of(*Data_.a(), 0) == 0);
576 }
577#if 0
578 void rfind() {
579 // 21.3.6.2

Callers

nothing calls this directly

Calls 4

abcdeMethod · 0.80
abaMethod · 0.80
aMethod · 0.45

Tested by

no test coverage detected