Modernize std::replace with ranges

This commit is contained in:
mitaclaw
2024-09-29 11:08:08 -07:00
parent 72436a0d1f
commit 0a80243a92
5 changed files with 6 additions and 6 deletions

View File

@ -107,7 +107,7 @@ std::vector<std::string> DoFileSearch(const std::vector<std::string>& directorie
if constexpr (os_separator != DIR_SEP_CHR)
{
for (auto& path : result)
std::replace(path.begin(), path.end(), '\\', DIR_SEP_CHR);
std::ranges::replace(path, '\\', DIR_SEP_CHR);
}
return result;