summaryrefslogtreecommitdiffstats
path: root/LICENSE.LGPLv3
diff options
context:
space:
mode:
authorGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2020-01-06 18:16:37 +0100
committerGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2020-01-09 00:01:55 +0100
commit50f3ccd7829b2d98f30d362f017f76509058f0fc (patch)
treec6b6e687a768ff06ccd7f64a205f3f276881218d /LICENSE.LGPLv3
parent5e66ea373a581d7e62b829d0ffa7f84d754c7f8f (diff)
QStringView: add a test for overload resolution versus QString
In the presence of multiple overloads of a function taking either QString or QStringView, QStringView should always be preferred. The rationale is that the QStringView overload may have been added "later" (read: the function was written when QStringView was not available yet, so it took QString), and the fact that a function with the _same name_ offers a QStringView overload implies the function never needed to store/own the string in the first place. Add a (compile-time) test for this preference. This is in preparation for a future QString(char16_t*) constructor (in Qt 5.15 / Qt 6). Change-Id: I60a435e494b653548f8f8d52c5d7e7cac2cc875a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'LICENSE.LGPLv3')
0 files changed, 0 insertions, 0 deletions