Skip to content

Commit ed2fe13

Browse files
authored
Merge pull request dolphin-emu#14219 from Sintendo/stringutils-drop-tabs2spaces
StringUtils: Drop TabsToSpaces
2 parents 206e1ba + 558cee8 commit ed2fe13

File tree

2 files changed

+0
-14
lines changed

2 files changed

+0
-14
lines changed

Source/Core/Common/StringUtil.cpp

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#include <locale>
1717
#include <sstream>
1818
#include <string>
19-
#include <type_traits>
2019
#include <vector>
2120

2221
#include <fmt/format.h>
@@ -365,17 +364,6 @@ std::vector<std::string> SplitString(const std::string& str, const char delim)
365364
return output;
366365
}
367366

368-
std::string TabsToSpaces(int tab_size, std::string str)
369-
{
370-
const std::string spaces(tab_size, ' ');
371-
372-
size_t i = 0;
373-
while (str.npos != (i = str.find('\t')))
374-
str.replace(i, 1, spaces);
375-
376-
return str;
377-
}
378-
379367
std::string ReplaceAll(std::string result, std::string_view src, std::string_view dest)
380368
{
381369
size_t pos = 0;

Source/Core/Common/StringUtil.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,8 +180,6 @@ std::from_chars_result FromChars(std::string_view sv, std::floating_point auto&
180180
}
181181
} // namespace Common
182182

183-
std::string TabsToSpaces(int tab_size, std::string str);
184-
185183
std::vector<std::string> SplitString(const std::string& str, char delim);
186184

187185
// "C:/Windows/winhelp.exe" to "C:/Windows/", "winhelp", ".exe"

0 commit comments

Comments
 (0)