diff options
Diffstat (limited to 'src/common/string_util.h')
| -rw-r--r-- | src/common/string_util.h | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/src/common/string_util.h b/src/common/string_util.h index f76fc43dc..7e32d6405 100644 --- a/src/common/string_util.h +++ b/src/common/string_util.h | |||
| @@ -5,8 +5,6 @@ | |||
| 5 | #pragma once | 5 | #pragma once |
| 6 | 6 | ||
| 7 | #include <cstddef> | 7 | #include <cstddef> |
| 8 | #include <iomanip> | ||
| 9 | #include <sstream> | ||
| 10 | #include <string> | 8 | #include <string> |
| 11 | #include <vector> | 9 | #include <vector> |
| 12 | #include "common/common_types.h" | 10 | #include "common/common_types.h" |
| @@ -28,21 +26,6 @@ std::string StripQuotes(const std::string& s); | |||
| 28 | 26 | ||
| 29 | std::string StringFromBool(bool value); | 27 | std::string StringFromBool(bool value); |
| 30 | 28 | ||
| 31 | bool TryParse(const std::string& str, bool* output); | ||
| 32 | bool TryParse(const std::string& str, u32* output); | ||
| 33 | |||
| 34 | template <typename N> | ||
| 35 | static bool TryParse(const std::string& str, N* const output) { | ||
| 36 | std::istringstream iss(str); | ||
| 37 | |||
| 38 | N tmp = 0; | ||
| 39 | if (iss >> tmp) { | ||
| 40 | *output = tmp; | ||
| 41 | return true; | ||
| 42 | } else | ||
| 43 | return false; | ||
| 44 | } | ||
| 45 | |||
| 46 | std::string TabsToSpaces(int tab_size, std::string in); | 29 | std::string TabsToSpaces(int tab_size, std::string in); |
| 47 | 30 | ||
| 48 | void SplitString(const std::string& str, char delim, std::vector<std::string>& output); | 31 | void SplitString(const std::string& str, char delim, std::vector<std::string>& output); |