forked from qt-creator/qt-creator
ClangPchManager: Add build dependencies to include collector
It's a first step but we have to refactor the interface later. Task-number: QTCREATORBUG-21379 Change-Id: Idda666bcaec950203f001c993c54a926779527e0 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
@@ -25,6 +25,8 @@
|
||||
|
||||
#include "clangtool.h"
|
||||
|
||||
#include <iostream>
|
||||
|
||||
namespace ClangBackEnd {
|
||||
|
||||
namespace {
|
||||
|
||||
@@ -44,7 +44,7 @@ namespace ClangBackEnd {
|
||||
class SymbolsVisitorBase
|
||||
{
|
||||
public:
|
||||
SymbolsVisitorBase(FilePathCachingInterface &filePathCache,
|
||||
SymbolsVisitorBase(const FilePathCachingInterface &filePathCache,
|
||||
const clang::SourceManager *sourceManager,
|
||||
SourcesManager &sourcesManager)
|
||||
: m_filePathCache(filePathCache),
|
||||
@@ -152,8 +152,13 @@ public:
|
||||
|
||||
bool isInSystemHeader(clang::FileID fileId) const
|
||||
{
|
||||
return clang::SrcMgr::isSystem(
|
||||
m_sourceManager->getSLocEntry(fileId).getFile().getFileCharacteristic());
|
||||
return isSystem(m_sourceManager->getSLocEntry(fileId).getFile().getFileCharacteristic());
|
||||
}
|
||||
|
||||
static
|
||||
bool isSystem(clang::SrcMgr::CharacteristicKind kind)
|
||||
{
|
||||
return clang::SrcMgr::isSystem(kind);
|
||||
}
|
||||
|
||||
void clear()
|
||||
@@ -163,7 +168,7 @@ public:
|
||||
|
||||
protected:
|
||||
std::vector<FilePathId> m_filePathIndices;
|
||||
FilePathCachingInterface &m_filePathCache;
|
||||
const FilePathCachingInterface &m_filePathCache;
|
||||
const clang::SourceManager *m_sourceManager = nullptr;
|
||||
SourcesManager &m_sourcesManager;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user