Closed alexey-malov closed 5 years ago
string StringReplace(const string& line, const string& search, const string& replace) { string newString(line); size_t position = newString.find(search, 0); while (position != string::npos) { newString.replace(position, search.length(), replace); position += replace.length(); position = newString.find(search, position); } return newString; }
Используйте расширение OpenCppCoverage для VisualStudio, чтобы обнаруживать строки, которые никогда не выполнялись