diff options
author | Kae <80987908+Novaenia@users.noreply.github.com> | 2024-03-15 21:28:11 +1100 |
---|---|---|
committer | Kae <80987908+Novaenia@users.noreply.github.com> | 2024-03-15 21:28:11 +1100 |
commit | 6fa0afd758a6351873df813cd7e70b1904714ed6 (patch) | |
tree | fbf45f18af0962a1d9ed3a2f44d8bb208c032645 /source/core/StarString.cpp | |
parent | 696abcca71274fbda2470f1941cb2e06b6ff8c61 (diff) |
experimental asset load scripts
Diffstat (limited to 'source/core/StarString.cpp')
-rw-r--r-- | source/core/StarString.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/core/StarString.cpp b/source/core/StarString.cpp index b236656..db785e6 100644 --- a/source/core/StarString.cpp +++ b/source/core/StarString.cpp @@ -407,7 +407,7 @@ bool String::hasCharOrWhitespace(Char c) const { return hasChar(c); } -String String::replace(String const& rplc, String const& val) const { +String String::replace(String const& rplc, String const& val, CaseSensitivity cs) const { size_t index; size_t sz = size(); size_t rsz = rplc.size(); @@ -417,7 +417,7 @@ String String::replace(String const& rplc, String const& val) const { if (rplc.empty()) return *this; - index = find(rplc); + index = find(rplc, 0, cs); if (index == NPos) return *this; @@ -431,7 +431,7 @@ String String::replace(String const& rplc, String const& val) const { for (size_t i = 0; i < rsz; ++i) ++it; - size_t nindex = find(rplc, index); + size_t nindex = find(rplc, index, cs); for (size_t i = index; i < nindex && i < sz; ++i) ret.append(*it++); |