summaryrefslogtreecommitdiff
path: root/source/fud_string.cpp
diff options
context:
space:
mode:
authorDominick Allen <djallen@librehumanitas.org>2024-09-25 11:41:50 -0500
committerDominick Allen <djallen@librehumanitas.org>2024-09-25 11:41:50 -0500
commitdbb305fa27baada32d29d6f8904bdc02ac494e13 (patch)
tree982997034ad234f4d4e669b849ab6fb2c280bb21 /source/fud_string.cpp
parent255fa256b106506e0c951f704314c5c633217468 (diff)
Add iterator to string api.
Diffstat (limited to 'source/fud_string.cpp')
-rw-r--r--source/fud_string.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/source/fud_string.cpp b/source/fud_string.cpp
index 57bf1e0..74742e1 100644
--- a/source/fud_string.cpp
+++ b/source/fud_string.cpp
@@ -287,6 +287,16 @@ String String::append(const String& rhs) const
return output;
}
+const utf8* String::begin() const
+{
+ return data();
+}
+
+const utf8* String::end() const
+{
+ return data() + size();
+}
+
bool StringView::nullTerminated() const
{
return m_data != nullptr && m_data[m_length] == '\0';