MCPcopy Index your code
hub / github.com/Kitware/CMake / testMethodIterators

Function testMethodIterators

Tests/CMakeLib/testString.cxx:614–631  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

612}
613
614static bool testMethodIterators()
615{
616 std::cout << "testMethodIterators()\n";
617 cm::String str = "abc";
618 ASSERT_TRUE(*str.begin() == 'a');
619 ASSERT_TRUE(*(str.end() - 1) == 'c');
620 ASSERT_TRUE(str.end() - str.begin() == 3);
621 ASSERT_TRUE(*str.cbegin() == 'a');
622 ASSERT_TRUE(*(str.cend() - 1) == 'c');
623 ASSERT_TRUE(str.cend() - str.cbegin() == 3);
624 ASSERT_TRUE(*str.rbegin() == 'c');
625 ASSERT_TRUE(*(str.rend() - 1) == 'a');
626 ASSERT_TRUE(str.rend() - str.rbegin() == 3);
627 ASSERT_TRUE(*str.crbegin() == 'c');
628 ASSERT_TRUE(*(str.crend() - 1) == 'a');
629 ASSERT_TRUE(str.crend() - str.crbegin() == 3);
630 return true;
631}
632
633static bool testMethod_clear()
634{

Callers

nothing calls this directly

Calls 8

cbeginMethod · 0.80
cendMethod · 0.80
rbeginMethod · 0.80
rendMethod · 0.80
crbeginMethod · 0.80
crendMethod · 0.80
beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…