diff options
| author | 2024-02-20 21:17:59 -0500 | |
|---|---|---|
| committer | 2024-02-20 22:15:38 -0500 | |
| commit | c575a85233cfea2e0935a5609e4e13d980a8c28f (patch) | |
| tree | ebfb39a093a2042a8d15769532089a83c883d21a /src/common/string_util.cpp | |
| parent | audio: rewrite IHardwareOpusDecoderManager (diff) | |
| download | yuzu-c575a85233cfea2e0935a5609e4e13d980a8c28f.tar.gz yuzu-c575a85233cfea2e0935a5609e4e13d980a8c28f.tar.xz yuzu-c575a85233cfea2e0935a5609e4e13d980a8c28f.zip | |
audio: rewrite IAudioDevice
Diffstat (limited to 'src/common/string_util.cpp')
| -rw-r--r-- | src/common/string_util.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/common/string_util.cpp b/src/common/string_util.cpp index 72c481798..1909aced5 100644 --- a/src/common/string_util.cpp +++ b/src/common/string_util.cpp | |||
| @@ -38,6 +38,10 @@ std::string StringFromBuffer(std::span<const u8> data) { | |||
| 38 | return std::string(data.begin(), std::find(data.begin(), data.end(), '\0')); | 38 | return std::string(data.begin(), std::find(data.begin(), data.end(), '\0')); |
| 39 | } | 39 | } |
| 40 | 40 | ||
| 41 | std::string StringFromBuffer(std::span<const char> data) { | ||
| 42 | return std::string(data.begin(), std::find(data.begin(), data.end(), '\0')); | ||
| 43 | } | ||
| 44 | |||
| 41 | // Turns " hej " into "hej". Also handles tabs. | 45 | // Turns " hej " into "hej". Also handles tabs. |
| 42 | std::string StripSpaces(const std::string& str) { | 46 | std::string StripSpaces(const std::string& str) { |
| 43 | const std::size_t s = str.find_first_not_of(" \t\r\n"); | 47 | const std::size_t s = str.find_first_not_of(" \t\r\n"); |