logic: reduce access to filesystem while indexing
* use canonical filepath cache in cxx indexer * made constructors of FilePath explicit * use FilePath at more places instead of string * forward declares FilePath wherever possible
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
#include "clang/Tooling/Tooling.h"
|
||||
|
||||
#include "data/parser/cxx/ASTAction.h"
|
||||
#include "data/parser/cxx/cxxCacheTypes.h"
|
||||
#include "utility/file/FileRegister.h"
|
||||
|
||||
class ASTActionFactory
|
||||
@@ -11,7 +12,12 @@ class ASTActionFactory
|
||||
{
|
||||
public:
|
||||
explicit ASTActionFactory(
|
||||
std::shared_ptr<ParserClient> client, std::shared_ptr<FileRegister> fileRegister, bool preprocessorOnly);
|
||||
std::shared_ptr<ParserClient> client,
|
||||
std::shared_ptr<FileRegister> fileRegister,
|
||||
std::shared_ptr<FilePathCache> canonicalFilePathCache,
|
||||
bool preprocessorOnly
|
||||
);
|
||||
|
||||
virtual ~ASTActionFactory();
|
||||
|
||||
virtual clang::FrontendAction* create();
|
||||
@@ -19,6 +25,7 @@ public:
|
||||
private:
|
||||
std::shared_ptr<ParserClient> m_client;
|
||||
std::shared_ptr<FileRegister> m_fileRegister;
|
||||
std::shared_ptr<FilePathCache> m_canonicalFilePathCache;
|
||||
|
||||
bool m_preprocessorOnly;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user