aboutsummaryrefslogtreecommitdiffstats
path: root/src/libs/qmljs/persistenttrie.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/qmljs/persistenttrie.cpp')
-rw-r--r--src/libs/qmljs/persistenttrie.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/libs/qmljs/persistenttrie.cpp b/src/libs/qmljs/persistenttrie.cpp
index 08c17dd164..edc3015099 100644
--- a/src/libs/qmljs/persistenttrie.cpp
+++ b/src/libs/qmljs/persistenttrie.cpp
@@ -286,12 +286,9 @@ public:
ReplaceInTrie() { }
void operator()(QString s)
{
- QHashIterator<QString, QString> i(replacements);
QString res = s;
- while (i.hasNext()) {
- i.next();
+ for (auto i = replacements.cbegin(), end = replacements.cend(); i != end; ++i)
res.replace(i.key(), i.value());
- }
trie = TrieNode::insertF(trie,res);
}
};