summaryrefslogtreecommitdiffstats
path: root/tools/dumpcpp/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tools/dumpcpp/main.cpp')
-rw-r--r--tools/dumpcpp/main.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/tools/dumpcpp/main.cpp b/tools/dumpcpp/main.cpp
index 145f248..97915c1 100644
--- a/tools/dumpcpp/main.cpp
+++ b/tools/dumpcpp/main.cpp
@@ -899,7 +899,8 @@ void generateClassImpl(QTextStream &out, const QMetaObject *mo, const QByteArray
static void formatCommentBlockFooter(const QString &typeLibFile, QTextStream &str)
{
str << " generated by dumpcpp v" << QT_VERSION_STR << " using\n**";
- foreach (const QString &arg, QCoreApplication::arguments())
+ const QStringList arguments = QCoreApplication::arguments();
+ for (const QString &arg : arguments)
str << ' ' << arg;
str << "\n** from the type library " << typeLibFile << "\n**\n"
<< "****************************************************************************/\n\n";
@@ -1128,7 +1129,7 @@ bool generateTypeLibrary(QString typeLibFile, QString outname,
declOut << '}' << endl << endl;
}
}
- foreach (const QByteArray &opaquePointerType, opaquePointerTypes)
+ for (const QByteArray &opaquePointerType : qAsConst(opaquePointerTypes))
declOut << "Q_DECLARE_OPAQUE_POINTER(" << opaquePointerType << "*)" << endl;
declOut << endl;
}