diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2022-04-14 11:00:36 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2022-04-14 13:29:41 +0200 |
commit | 871adb006645d0fd5eeecab70ea4c937de85c38e (patch) | |
tree | 6052ed6889a468952263774157a3a4f2dc54f3b6 | |
parent | 206efef78ea367de76f000a1760dbd8bc7785b0c (diff) |
Fix comment again
...which had been butchered by c7fb93764b321e5bf4cd143dd0c29be60de6d8f8 "Cleanup
comment": e4ff847fe0796420ba8023b70cad8589f5f19e9f "loplugin:stringview check
for getToken and trim" had turned this into a template, but had not lifted the
other restrictions. But while at it, also adapt the mention of "OString" and
"std::string_view" in the comment to that
e4ff847fe0796420ba8023b70cad8589f5f19e9f change.
Change-Id: I3c27efe145c4bea6c4b16f81da671bf22160545c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133000
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
-rw-r--r-- | include/o3tl/string_view.hxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/include/o3tl/string_view.hxx b/include/o3tl/string_view.hxx index dec21bd70338..eb98e243c8b1 100644 --- a/include/o3tl/string_view.hxx +++ b/include/o3tl/string_view.hxx @@ -48,8 +48,9 @@ inline int compareToIgnoreAsciiCase(std::u16string_view s1, std::u16string_view return rtl_ustr_compareIgnoreAsciiCase_WithLength(s1.data(), s1.size(), s2.data(), s2.size()); }; -// Similar to OString::getToken, returning the first token of a std::string_view, starting at a -// given position: +// Similar to O[U]String::getToken, returning the first token of a std::[u16]string_view, starting +// at a given position (and if needed, it can be extended to return the n'th token instead of just +// the first, or support an initial position of npos): template <typename charT, typename traits = std::char_traits<charT>> inline std::basic_string_view<charT, traits> getToken(std::basic_string_view<charT, traits> sv, charT delimiter, std::size_t& position) |