summaryrefslogtreecommitdiffstats
path: root/tests/auto/guiapplauncher
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@qt.io>2023-03-01 14:24:22 +0100
committerMarc Mutz <marc.mutz@qt.io>2023-03-02 04:49:48 +0000
commitc6dbae9550e3819a3e1ade1bf06f5d9cb030d561 (patch)
treea7a21b50403e93ecbd8537bcab141a57c4ab465d /tests/auto/guiapplauncher
parent5573e2d6ac09ff8b8f23edca93f601ff7679fa3c (diff)
qobjectdefs.h: properly disable rvalue qReturnArg()
template <typename T> qReturnArg(T&&) is an unconstrained perfect forwarder, and will "win" for everything for which `T&` is not an equal match. e.g. a volatile T. Restrict the deleted overload to actual rvalues. We don't need to use `const volatile T&&`, because rvalues never bind to `T&`, we just need to get off using a universal reference, and adding const does that. As a drive-by, change the deleted overload's return type to void, to mimic std::as_const(), the prototype for rvalue-deleted function overloads. Pick-to: 6.5 Change-Id: If4fbc311677b993488859b2c4e226b94daed71fe Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'tests/auto/guiapplauncher')
0 files changed, 0 insertions, 0 deletions