diff options
| author | Marc Mutz <marc.mutz@qt.io> | 2022-10-09 11:05:42 +0200 |
|---|---|---|
| committer | Marc Mutz <marc.mutz@qt.io> | 2022-10-11 23:17:17 +0200 |
| commit | e1d21fe813c4c9c3f53e59c08190f80b38e385da (patch) | |
| tree | ada05d1793c4656a5b6e956fdf1bbeaf4e545a69 /src/corelib/text/qstring.cpp | |
| parent | a94731c2ad85f9dd40050a780f67c911bf12668e (diff) | |
| download | qtbase-e1d21fe813c4c9c3f53e59c08190f80b38e385da.tar.gz | |
QString: rename parameter clashing with member function of the same name
The size parameter shadows the size() member function, so rename it to
newSize.
Prepares for a follow-up change that ports from count()/length() to
size().
Change-Id: I0ca8af57d6351f85a568409a8d02b66371bb05e7
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/text/qstring.cpp')
| -rw-r--r-- | src/corelib/text/qstring.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/corelib/text/qstring.cpp b/src/corelib/text/qstring.cpp index 4df29ab52f..12053054ba 100644 --- a/src/corelib/text/qstring.cpp +++ b/src/corelib/text/qstring.cpp @@ -2716,10 +2716,10 @@ void QString::resize(qsizetype size) \snippet qstring/main.cpp 46 */ -void QString::resize(qsizetype size, QChar fillChar) +void QString::resize(qsizetype newSize, QChar fillChar) { const qsizetype oldSize = length(); - resize(size); + resize(newSize); const qsizetype difference = length() - oldSize; if (difference > 0) std::fill_n(d.data() + oldSize, difference, fillChar.unicode()); |
