diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2016-01-26 14:38:54 +0100 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2016-01-28 20:25:11 +0000 |
commit | 3f3140d38a75b8fdef8742d5fe9345cc3fe359cc (patch) | |
tree | a04eab25759c6340cdda99b13ab0cf89f6fd6eba /qmake/project.cpp | |
parent | c9cb20c01a0f3fa93ff9f79fd7ea3f53939497c4 (diff) | |
download | qtbase-3f3140d38a75b8fdef8742d5fe9345cc3fe359cc.tar.gz |
qmake: eradicate Q_FOREACH loops [const-& returns]
... by replacing them with C++11 range-for loops.
The functions QMakeProject::values(), QMakeMetaInfo::values()
and QHashIterator::value() all return by const-reference,
so they can be passed to range-for without further changes.
Change-Id: Ic3b39ed8ff8cd7a6f287f1aa9d61a1acd67d7aaa
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Diffstat (limited to 'qmake/project.cpp')
-rw-r--r-- | qmake/project.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/qmake/project.cpp b/qmake/project.cpp index 888669d368..3b7f28edbc 100644 --- a/qmake/project.cpp +++ b/qmake/project.cpp @@ -146,7 +146,7 @@ void QMakeProject::dump() const it != m_valuemapStack.first().end(); ++it) { if (!it.key().startsWith('.')) { QString str = it.key() + " ="; - foreach (const ProString &v, it.value()) + for (const ProString &v : it.value()) str += ' ' + formatValue(v); out << str; } |