diff options
author | Mårten Nordheim <[email protected]> | 2023-06-02 19:01:09 +0200 |
---|---|---|
committer | Mårten Nordheim <[email protected]> | 2023-06-20 22:04:04 +0000 |
commit | 054a64ce67421b213df73a9bcfda3fa6e9c6e64f (patch) | |
tree | d9684a3bbd4816dab47163a00c3f1fe5cab7a81b | |
parent | f667445006c52f26103540ae18964a0015a297db (diff) |
QStringView: size is encoded with code units not code points
Code points is what you get when surrogate pairs have been joined
Pick-to: 6.6 6.5 6.2
Change-Id: I86c4131de5782ce1e6342217947a603ca16bb521
Reviewed-by: Giuseppe D'Angelo <[email protected]>
Reviewed-by: Thiago Macieira <[email protected]>
-rw-r--r-- | src/corelib/text/qstringview.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/text/qstringview.cpp b/src/corelib/text/qstringview.cpp index 914f5a39d9a..302637eebf8 100644 --- a/src/corelib/text/qstringview.cpp +++ b/src/corelib/text/qstringview.cpp @@ -471,7 +471,7 @@ QT_BEGIN_NAMESPACE /*! \fn qsizetype QStringView::size() const - Returns the size of this string view, in UTF-16 code points (that is, + Returns the size of this string view, in UTF-16 code units (that is, surrogate pairs count as two for the purposes of this function, the same as in QString). |