MCPcopy Create free account
hub / github.com/Kitware/CMake / cmSplitExtension

Function cmSplitExtension

Source/cmLocalUnixMakefileGenerator3.cxx:63–75  ·  view source on GitHub ↗

Helper function used below.

Source from the content-addressed store, hash-verified

61namespace {
62// Helper function used below.
63std::string cmSplitExtension(std::string const& in, std::string& base)
64{
65 std::string ext;
66 std::string::size_type dot_pos = in.rfind('.');
67 if (dot_pos != std::string::npos) {
68 // Remove the extension first in case &base == &in.
69 ext = in.substr(dot_pos);
70 base = in.substr(0, dot_pos);
71 } else {
72 base = in;
73 }
74 return ext;
75}
76
77#ifndef CMAKE_BOOTSTRAP
78// Helper function to add the Start Instrumentation command

Callers 1

Calls 2

rfindMethod · 0.80
substrMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…