summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/kernel/qtooltip/tst_qtooltip.cpp
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2022-10-13 13:48:29 -0700
committerIvan Solovev <ivan.solovev@qt.io>2024-04-26 18:19:36 +0200
commitf7e9bb77839722a91aa2c6b794b0c7b2e18c66cb (patch)
treeabda008c6f1b988b6f5e9e2e3b7f714954fad169 /tests/auto/widgets/kernel/qtooltip/tst_qtooltip.cpp
parent0756cc1eae5fd8981983319fef1d084762a67b8d (diff)
QTest: replace the majority of the ugly QCOMPARE_xx macro
Using templates to make the code look nicer and be more debuggable. Previously, if you tried to step into the QCOMPARE_xx, you'd have the creations of qxp::function_ref from the lambdas before you got to the actual comparison. And all of this was in-place from macro expansion, so you couldn't tell what was happening. Now, if you step into QCOMPARE_xx, you go to qCompareOp. There are 5 frames between that point and the actual comparison (four std::forward() and the Compare::compare()) and debuggers could step over std::forward. Even if they can't, both libstdc++ and libc++ implementations are simple casts, so there's nothing more to step into. Change-Id: I12a088d1ae424825abd3fffd171dbbf7adb7e7e2 Reviewed-by: Ivan Solovev <ivan.solovev@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'tests/auto/widgets/kernel/qtooltip/tst_qtooltip.cpp')
0 files changed, 0 insertions, 0 deletions