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

Method RemoveVariablesInString

Source/cmMakefile.cxx:2816–2836  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2814}
2815
2816void cmMakefile::RemoveVariablesInString(std::string& source,
2817 bool atOnly) const
2818{
2819 if (!atOnly) {
2820 cmsys::RegularExpression var("(\\${[A-Za-z_0-9]*})");
2821 while (var.find(source)) {
2822 source.erase(var.start(), var.end() - var.start());
2823 }
2824 }
2825
2826 if (!atOnly) {
2827 cmsys::RegularExpression varb("(\\$ENV{[A-Za-z_0-9]*})");
2828 while (varb.find(source)) {
2829 source.erase(varb.start(), varb.end() - varb.start());
2830 }
2831 }
2832 cmsys::RegularExpression var2("(@[A-Za-z_0-9]*@)");
2833 while (var2.find(source)) {
2834 source.erase(var2.start(), var2.end() - var2.start());
2835 }
2836}
2837
2838void cmMakefile::InitCMAKE_CONFIGURATION_TYPES(std::string const& genDefault)
2839{

Callers

nothing calls this directly

Calls 4

eraseMethod · 0.80
findMethod · 0.45
startMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected