diff options
author | Kari Oikarinen <kari.oikarinen@qt.io> | 2019-11-11 13:35:53 +0200 |
---|---|---|
committer | Kari Oikarinen <kari.oikarinen@qt.io> | 2020-01-30 07:30:17 +0200 |
commit | 4f077b7e5ff1081afc0e362bdab6522c2b7ee43b (patch) | |
tree | 84539da88bb36b09417fbbfb30c1175a21d18813 /tests/auto/corelib/tools/qscopeguard/qscopeguard.pro | |
parent | 601ce9e08aa92b273f1a6daf0bdbc67dbf9b4e5f (diff) |
QScopeGuard: Make constructor public
With Class Template Argument Deduction users might want to use the constructor
itself instead of a separate helper function. In both cases it's possible to let
the compiler deduce the template arguments.
Try to make the usefulness of the helper function in the absence of CTAD still
clear in the documentation.
Change-Id: I9b07983c1fb276a6dd9e7ed4c3e606764e9b68ca
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
Diffstat (limited to 'tests/auto/corelib/tools/qscopeguard/qscopeguard.pro')
-rw-r--r-- | tests/auto/corelib/tools/qscopeguard/qscopeguard.pro | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/auto/corelib/tools/qscopeguard/qscopeguard.pro b/tests/auto/corelib/tools/qscopeguard/qscopeguard.pro index 070d4b077c..e3645befcf 100644 --- a/tests/auto/corelib/tools/qscopeguard/qscopeguard.pro +++ b/tests/auto/corelib/tools/qscopeguard/qscopeguard.pro @@ -2,3 +2,6 @@ CONFIG += testcase TARGET = tst_qscopeguard QT = core testlib SOURCES = tst_qscopeguard.cpp + +# Force C++17 if available +contains(QT_CONFIG, c++1z): CONFIG += c++1z |