ClangCodeModel: Prevent outdated fix-its from getting applied

The code locations might no longer be correct.

Fixes: QTCREATORBUG-21818
Change-Id: I866a29d2fd63ff65cf33168024f7788c5f6e3547
Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
Christian Kandeler
2020-11-20 17:26:26 +01:00
parent 0d12c8cba8
commit bcf900e29b
6 changed files with 37 additions and 19 deletions

View File

@@ -455,7 +455,8 @@ void ClangDiagnosticManager::addClangTextMarks(
auto textMark = new ClangTextMark(::Utils::FilePath::fromString(filePath()),
diagnostic,
onMarkRemoved,
m_fullVisualization);
m_fullVisualization,
this);
m_clangTextMarks.push_back(textMark);
m_textDocument->addMark(textMark);
}