forked from qt-creator/qt-creator
CppEditor: Proliferate FilePath use
Remove SnapShot::{find,contains}(QString) overloads and fix fallout.
Change-Id: I50c415826939e09ac111f33def611c7478fa5d97
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -177,11 +177,11 @@ static bool closeEditorsWithoutGarbageCollectorInvocation(const QList<Core::IEdi
|
||||
return closeEditorsSucceeded;
|
||||
}
|
||||
|
||||
static bool snapshotContains(const CPlusPlus::Snapshot &snapshot, const QSet<QString> &filePaths)
|
||||
static bool snapshotContains(const CPlusPlus::Snapshot &snapshot, const QSet<FilePath> &filePaths)
|
||||
{
|
||||
for (const QString &filePath : filePaths) {
|
||||
for (const FilePath &filePath : filePaths) {
|
||||
if (!snapshot.contains(filePath)) {
|
||||
qWarning() << "Missing file in snapshot:" << qPrintable(filePath);
|
||||
qWarning() << "Missing file in snapshot:" << qPrintable(filePath.toString());
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -291,7 +291,7 @@ bool TestCase::parseFiles(const QSet<FilePath> &filePaths)
|
||||
qWarning("After parsing: snapshot is empty.");
|
||||
return false;
|
||||
}
|
||||
if (!snapshotContains(snapshot, filePaths_)) {
|
||||
if (!snapshotContains(snapshot, filePaths)) {
|
||||
qWarning("After parsing: snapshot does not contain all expected files.");
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user