forked from qt-creator/qt-creator
ClangCodeModel: Fix re-parsing with new options
If the command line options changed unload the unit so the next SemanticMarker::reparse() will call clang_parseTranslationUnit() with the new options. Task-number: QTCREATORBUG-11606 Change-Id: I44e3da97850abd875a88abde0b406b14198b5be8 Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com> Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
This commit is contained in:
@@ -83,6 +83,7 @@ void SemanticMarker::setCompilationOptions(const QStringList &options)
|
||||
return;
|
||||
|
||||
m_unit->setCompilationOptions(options);
|
||||
m_unit->unload();
|
||||
}
|
||||
|
||||
void SemanticMarker::reparse(const UnsavedFiles &unsavedFiles)
|
||||
|
||||
Reference in New Issue
Block a user