Clang: Remove pointless function

Change-Id: Ia4239f5b2aa1cfdd515ec0ff43fc10cb49c6f335
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
Nikolai Kosjar
2018-10-18 14:43:53 +02:00
parent f1290da3cd
commit 110fb7943e
2 changed files with 1 additions and 18 deletions

View File

@@ -84,14 +84,6 @@ void ClangCodeModelServer::end()
QCoreApplication::exit(); QCoreApplication::exit();
} }
static std::vector<Document> operator+(const std::vector<Document> &a,
const std::vector<Document> &b)
{
std::vector<Document> result = a;
result.insert(result.end(), b.begin(), b.end());
return result;
}
void ClangCodeModelServer::documentsOpened(const ClangBackEnd::DocumentsOpenedMessage &message) void ClangCodeModelServer::documentsOpened(const ClangBackEnd::DocumentsOpenedMessage &message)
{ {
qCDebug(serverLog) << "########## documentsOpened"; qCDebug(serverLog) << "########## documentsOpened";
@@ -114,7 +106,7 @@ void ClangCodeModelServer::documentsOpened(const ClangBackEnd::DocumentsOpenedMe
documents.setVisibleInEditors(message.visibleEditorFilePaths); documents.setVisibleInEditors(message.visibleEditorFilePaths);
processSuspendResumeJobs(documents.documents()); processSuspendResumeJobs(documents.documents());
processInitialJobsForDocuments(createdDocuments + resetDocuments_); processJobsForVisibleDocuments();
} catch (const std::exception &exception) { } catch (const std::exception &exception) {
qWarning() << "Error in ClangCodeModelServer::documentsOpened:" << exception.what(); qWarning() << "Error in ClangCodeModelServer::documentsOpened:" << exception.what();
} }
@@ -440,14 +432,6 @@ std::vector<Document> ClangCodeModelServer::resetDocuments(const DocumentResetIn
return newDocuments; return newDocuments;
} }
void ClangCodeModelServer::processInitialJobsForDocuments(const std::vector<Document> &documents)
{
for (const auto &document : documents) {
DocumentProcessor processor = documentProcessors().processor(document);
addUpdateAnnotationsJobsAndProcess(processor);
}
}
void ClangCodeModelServer::setUpdateAnnotationsTimeOutInMsForTestsOnly(int value) void ClangCodeModelServer::setUpdateAnnotationsTimeOutInMsForTestsOnly(int value)
{ {
updateAnnotationsTimeOutInMs = value; updateAnnotationsTimeOutInMs = value;

View File

@@ -78,7 +78,6 @@ public: // for tests
DocumentProcessors &documentProcessors(); DocumentProcessors &documentProcessors();
private: private:
void processInitialJobsForDocuments(const std::vector<Document> &documents);
void processJobsForVisibleDocuments(); void processJobsForVisibleDocuments();
void processJobsForCurrentDocument(); void processJobsForCurrentDocument();
void processTimerForVisibleButNotCurrentDocuments(); void processTimerForVisibleButNotCurrentDocuments();