From 38b51667b5ba74fc5a28172e251c9ba4c0398e32 Mon Sep 17 00:00:00 2001 From: Laurent Montel Date: Tue, 26 Feb 2019 07:04:22 +0100 Subject: [Kconfig] Compile without foreach Summary: compile without foreach Test Plan: Unittest Ok as previously Reviewers: dfaure Reviewed By: dfaure Subscribers: kde-frameworks-devel Tags: #frameworks Differential Revision: https://phabricator.kde.org/D19326 --- src/core/ksharedconfig.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/core/ksharedconfig.cpp') diff --git a/src/core/ksharedconfig.cpp b/src/core/ksharedconfig.cpp index 52a2d23d..0b2b9c35 100644 --- a/src/core/ksharedconfig.cpp +++ b/src/core/ksharedconfig.cpp @@ -90,7 +90,7 @@ KSharedConfigPtr KSharedConfig::openConfig(const QString &_fileName, list->mainConfig = nullptr; } - foreach (auto cfg, *static_cast(list)) { + for (auto cfg : qAsConst(*list)) { if (cfg->name() == fileName && cfg->d_ptr->openFlags == flags && cfg->locationType() == resType -- cgit v1.2.1