forked from qt-creator/qt-creator
Clang: Ensure to clear all affected translation units on project part change
The ones that were already dirty were not taken into the account and used the old project configuration. Change-Id: I949d1ca8c23bbdb18eec78e5a708199beff6f735 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
@@ -188,14 +188,14 @@ void Documents::updateDocumentsWithChangedDependencies(const QVector<FileContain
|
||||
|
||||
std::vector<Document> Documents::setDocumentsDirtyIfProjectPartChanged()
|
||||
{
|
||||
std::vector<Document> notDirtyBefore;
|
||||
std::vector<Document> affectedDocuments;
|
||||
|
||||
for (auto &document : documents_) {
|
||||
if (!document.isDirty() && document.setDirtyIfProjectPartIsOutdated())
|
||||
notDirtyBefore.push_back(document);
|
||||
if (document.setDirtyIfProjectPartIsOutdated())
|
||||
affectedDocuments.push_back(document);
|
||||
}
|
||||
|
||||
return notDirtyBefore;
|
||||
return affectedDocuments;
|
||||
}
|
||||
|
||||
QVector<FileContainer> Documents::newerFileContainers(const QVector<FileContainer> &fileContainers) const
|
||||
|
||||
Reference in New Issue
Block a user