MCPcopy Create free account
hub / github.com/CodingGay/BlackDex / extractClassName

Function extractClassName

Bcore/src/main/cpp/Dobby/tests/catch.hpp:9983–9993  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9981}
9982
9983std::string extractClassName(StringRef const &classOrQualifiedMethodName) {
9984 std::string className = classOrQualifiedMethodName;
9985 if (startsWith(className, '&')) {
9986 std::size_t lastColons = className.rfind("::");
9987 std::size_t penultimateColons = className.rfind("::", lastColons - 1);
9988 if (penultimateColons == std::string::npos)
9989 penultimateColons = 1;
9990 className = className.substr(penultimateColons, lastColons - penultimateColons);
9991 }
9992 return className;
9993}
9994
9995} // end namespace Catch
9996// end catch_test_case_registry_impl.cpp

Callers 1

AutoRegMethod · 0.85

Calls 3

startsWithFunction · 0.85
rfindMethod · 0.80
substrMethod · 0.45

Tested by

no test coverage detected