From e9e076df55ce1537b62f9b13cad0f9781935beb0 Mon Sep 17 00:00:00 2001 From: Anton Kudryavtsev Date: Thu, 5 Oct 2023 13:46:31 +0300 Subject: [PATCH] QString: use qsizetype more It's last legacy int Pick-to: 6.6 6.5 6.2 Change-Id: I691f7b15dead91166831cdf6c33a9f4d2d58b62e Reviewed-by: Thiago Macieira --- src/corelib/text/qstring.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/corelib/text/qstring.cpp b/src/corelib/text/qstring.cpp index 064e2983c9..b85fc4fa62 100644 --- a/src/corelib/text/qstring.cpp +++ b/src/corelib/text/qstring.cpp @@ -3673,7 +3673,7 @@ static void replace_with_copy(QString &str, size_t *indices, qsizetype nIndices, QString copy{ newSize, Qt::Uninitialized }; QString::DataPointer ©_d = copy.data_ptr(); auto dst = copy_d.begin(); - for (int i = 0; i < nIndices; ++i) { + for (qsizetype i = 0; i < nIndices; ++i) { auto hit = str_d.begin() + indices[i]; dst = std::copy(src_start, hit, dst); dst = std::copy_n(after_b, alen, dst);