summaryrefslogtreecommitdiffstats
path: root/src/corelib/global
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@qt.io>2022-04-01 11:29:22 +0200
committerMarc Mutz <marc.mutz@qt.io>2022-04-03 12:20:55 +0200
commitb0e4d53b637e6c34457d14ed3f0be705098bf2f5 (patch)
treee652a5aa27e64839dfa1b0ac20c401d0075ac28c /src/corelib/global
parent168a02d4056efbef5c09d6d5810cf174412147c5 (diff)
QMetaType: don't create a registry just to query its emptiness
The function-call operator of QGlobalStatic creates the payload object unless is has already been deleted. When performing read-only operations on the payload object, it's better to use QGlobalStatic::exists() + the dereference operator instead, because that prevents the creation of the payload just to find it empty. Pick-to: 6.3 Change-Id: I367add516520d076412cbbc542ee7a3b6ea45c14 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Diffstat (limited to 'src/corelib/global')
0 files changed, 0 insertions, 0 deletions