mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-04-28 13:28:01 +03:00
sys: fix games.yml hdd paths
This commit is contained in:
parent
d6dde225bd
commit
d03393ffe9
4 changed files with 24 additions and 8 deletions
|
@ -612,7 +612,7 @@ std::vector<std::string> fmt::split(std::string_view source, std::initializer_li
|
|||
|
||||
std::string fmt::trim(const std::string& source, std::string_view values)
|
||||
{
|
||||
usz begin = source.find_first_not_of(values);
|
||||
const usz begin = source.find_first_not_of(values);
|
||||
|
||||
if (begin == source.npos)
|
||||
return {};
|
||||
|
@ -620,6 +620,16 @@ std::string fmt::trim(const std::string& source, std::string_view values)
|
|||
return source.substr(begin, source.find_last_not_of(values) + 1);
|
||||
}
|
||||
|
||||
std::string fmt::trim_front(const std::string& source, std::string_view values)
|
||||
{
|
||||
const usz begin = source.find_first_not_of(values);
|
||||
|
||||
if (begin == source.npos)
|
||||
return {};
|
||||
|
||||
return source.substr(begin);
|
||||
}
|
||||
|
||||
void fmt::trim_back(std::string& source, std::string_view values)
|
||||
{
|
||||
const usz index = source.find_last_not_of(values);
|
||||
|
|
|
@ -125,6 +125,7 @@ namespace fmt
|
|||
|
||||
std::vector<std::string> split(std::string_view source, std::initializer_list<std::string_view> separators, bool is_skip_empty = true);
|
||||
std::string trim(const std::string& source, std::string_view values = " \t");
|
||||
std::string trim_front(const std::string& source, std::string_view values = " \t");
|
||||
void trim_back(std::string& source, std::string_view values = " \t");
|
||||
|
||||
template <typename T>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue