diff options
author | Simon Hausmann <simon.hausmann@qt.io> | 2018-07-22 17:12:55 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@qt.io> | 2018-07-22 20:10:28 +0000 |
commit | 3c7db705baccdb326e69c00effdae4631ff09ce4 (patch) | |
tree | dc76af685717107b8ebd200015abf7e948df9083 /src/qml/qml/qqmltypeloader.cpp | |
parent | a605cdc3ff84de3a4107f19bc90a5251f6801f6c (diff) |
Use QScopeGuard instead of library local helper template
Change-Id: Ia96accbd0522554aef65839eb12062f4facd2604
Reviewed-by: Sérgio Martins <sergio.martins@kdab.com>
Diffstat (limited to 'src/qml/qml/qqmltypeloader.cpp')
-rw-r--r-- | src/qml/qml/qqmltypeloader.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/qml/qml/qqmltypeloader.cpp b/src/qml/qml/qqmltypeloader.cpp index 8a2462cfa7..3340b96a21 100644 --- a/src/qml/qml/qqmltypeloader.cpp +++ b/src/qml/qml/qqmltypeloader.cpp @@ -51,7 +51,6 @@ #include <private/qqmltypecompiler_p.h> #include <private/qqmlpropertyvalidator_p.h> #include <private/qqmlpropertycachecreator_p.h> -#include <private/qdeferredcleanup_p.h> #include <QtCore/qdir.h> #include <QtCore/qfile.h> @@ -66,6 +65,7 @@ #include <QtCore/qloggingcategory.h> #include <QtQml/qqmlextensioninterface.h> #include <QtCore/qcryptographichash.h> +#include <QtCore/qscopeguard.h> #include <functional> @@ -2214,7 +2214,7 @@ static bool addTypeReferenceChecksumsToHash(const QList<QQmlTypeData::TypeRefere void QQmlTypeData::done() { - QDeferredCleanup cleanup([this]{ + auto cleanup = qScopeGuard([this]{ m_document.reset(); m_typeReferences.clear(); if (isError()) |