forked from qt-creator/qt-creator
ClangRefactoring: Don't update the database if something went wrong
We can get an compile error. In that case we should not update the database. In the future we should have a mechanism to report about the database state. Task-number: QTCREATORBUG-21949 Change-Id: I203346d536b007171f7bf255047409431c44a85a Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
@@ -121,12 +121,14 @@ newFrontendActionFactory(Factory *consumerFactory,
|
||||
new FrontendActionFactoryAdapter(consumerFactory, sourceFileCallbacks));
|
||||
}
|
||||
|
||||
void SymbolsCollector::collectSymbols()
|
||||
bool SymbolsCollector::collectSymbols()
|
||||
{
|
||||
auto tool = m_clangTool.createTool();
|
||||
|
||||
tool.run(ClangBackEnd::newFrontendActionFactory(&m_collectSymbolsAction,
|
||||
&m_collectMacrosSourceFileCallbacks).get());
|
||||
auto actionFactory = ClangBackEnd::newFrontendActionFactory(&m_collectSymbolsAction,
|
||||
&m_collectMacrosSourceFileCallbacks);
|
||||
|
||||
return tool.run(actionFactory.get()) != 1;
|
||||
}
|
||||
|
||||
void SymbolsCollector::doInMainThreadAfterFinished()
|
||||
|
||||
Reference in New Issue
Block a user