diff options
| author | Christian Kandeler <christian.kandeler@qt.io> | 2021-08-20 11:21:06 +0200 |
|---|---|---|
| committer | Christian Kandeler <christian.kandeler@qt.io> | 2021-08-27 10:53:54 +0000 |
| commit | a952500e902eb0a0fe5b5dbcdafb6cb66fb88141 (patch) | |
| tree | 744dfbbf969359a3cb147b6bbc8ee47fe361a7ab /src/plugins/cpptools/cpptoolsplugin.cpp | |
| parent | 5d8551559af2300a67815582198b4ce580a7bba2 (diff) | |
| download | qt-creator-a952500e902eb0a0fe5b5dbcdafb6cb66fb88141.tar.gz | |
CppTools: Use only const pointers for ProjectInfo and ProjectPart
All members were already const, but this makes it clear at all points of
use that these data structures are immutable.
Change-Id: Iea615c090bde462c445d15223caccc561b0c713d
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Diffstat (limited to 'src/plugins/cpptools/cpptoolsplugin.cpp')
| -rw-r--r-- | src/plugins/cpptools/cpptoolsplugin.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/cpptools/cpptoolsplugin.cpp b/src/plugins/cpptools/cpptoolsplugin.cpp index 7eb0c916ee..7418f946fe 100644 --- a/src/plugins/cpptools/cpptoolsplugin.cpp +++ b/src/plugins/cpptools/cpptoolsplugin.cpp @@ -514,8 +514,8 @@ QString correspondingHeaderOrSource(const QString &fileName, bool *wasHeader, Ca // Find files in other projects } else { CppModelManager *modelManager = CppModelManager::instance(); - const QList<ProjectInfo::Ptr> projectInfos = modelManager->projectInfos(); - for (const ProjectInfo::Ptr &projectInfo : projectInfos) { + const QList<ProjectInfo::ConstPtr> projectInfos = modelManager->projectInfos(); + for (const ProjectInfo::ConstPtr &projectInfo : projectInfos) { const Project *project = projectForProjectInfo(*projectInfo); if (project == currentProject) continue; // We have already checked the current project. |
