forked from qt-creator/qt-creator
Clang: Make file ids unique
Clang file ids are only unique for one query. Because we query in parallel we have to manage our own unique ids. Change-Id: I67d57d8b1766cab75ad252a14e57bbf9dc5fdb79 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
#include <QCoreApplication>
|
||||
|
||||
#include <functional>
|
||||
#include <atomic>
|
||||
|
||||
namespace ClangBackEnd {
|
||||
|
||||
@@ -125,7 +126,7 @@ void RefactoringServer::gatherSourceRangesAndDiagnosticsForQueryMessages(
|
||||
uint freeProcessors = std::thread::hardware_concurrency();
|
||||
#endif
|
||||
|
||||
m_gatherer = ClangQueryGatherer(std::move(sources), std::move(unsaved), std::move(query));
|
||||
m_gatherer = ClangQueryGatherer(&m_filePathCache, std::move(sources), std::move(unsaved), std::move(query));
|
||||
m_gatherer.setProcessingSlotCount(freeProcessors);
|
||||
|
||||
m_pollTimer.start();
|
||||
|
Reference in New Issue
Block a user