mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
StringUtil: Remove JoinStrings
With 12 uses of `JoinStrings` in the codebase vs 36 uses of `fmt::join`, fmtlib's range adapter for string concatenation with delimiters is clearly the preferred option.
This commit is contained in:
@ -8,6 +8,7 @@
|
||||
#include <vector>
|
||||
|
||||
#include <fmt/format.h>
|
||||
#include <fmt/ranges.h>
|
||||
|
||||
#include "Common/CommonTypes.h"
|
||||
#include "Common/FileUtil.h"
|
||||
@ -141,7 +142,7 @@ std::string EscapePath(const std::string& path)
|
||||
for (const std::string& split_string : split_strings)
|
||||
escaped_split_strings.push_back(EscapeFileName(split_string));
|
||||
|
||||
return JoinStrings(escaped_split_strings, "/");
|
||||
return fmt::to_string(fmt::join(escaped_split_strings, "/"));
|
||||
}
|
||||
|
||||
std::string UnescapeFileName(const std::string& filename)
|
||||
|
Reference in New Issue
Block a user