clang-tools 20.0.0git
Public Member Functions | List of all members
clang::clangd::ScanningAllProjectModules Class Reference

TODO: The existing ScanningAllProjectModules is not efficient. More...

Inheritance diagram for clang::clangd::ScanningAllProjectModules:
Inheritance graph
[legend]

Public Member Functions

 ScanningAllProjectModules (std::shared_ptr< const clang::tooling::CompilationDatabase > CDB, const ThreadsafeFS &TFS)
 
 ~ScanningAllProjectModules () override=default
 
std::vector< std::string > getRequiredModules (PathRef File) override
 
PathRef getSourceForModuleName (llvm::StringRef ModuleName, PathRef RequiredSourceFile=PathRef()) override
 RequiredSourceFile is not used intentionally.
 
- Public Member Functions inherited from clang::clangd::ProjectModules
virtual std::vector< std::string > getRequiredModules (PathRef File)=0
 
virtual PathRef getSourceForModuleName (llvm::StringRef ModuleName, PathRef RequiredSrcFile=PathRef())=0
 
virtual ~ProjectModules ()=default
 

Detailed Description

TODO: The existing ScanningAllProjectModules is not efficient.

See the comments in ModuleDependencyScanner for detail.

In the future, we wish the build system can provide a well design compilation database for modules then we can query that new compilation database directly. Or we need to have a global long-live scanner to detect the state of each file.

Definition at line 170 of file ScanningProjectModules.cpp.

Constructor & Destructor Documentation

◆ ScanningAllProjectModules()

clang::clangd::ScanningAllProjectModules::ScanningAllProjectModules ( std::shared_ptr< const clang::tooling::CompilationDatabase >  CDB,
const ThreadsafeFS TFS 
)
inline

Definition at line 172 of file ScanningProjectModules.cpp.

◆ ~ScanningAllProjectModules()

clang::clangd::ScanningAllProjectModules::~ScanningAllProjectModules ( )
overridedefault

Member Function Documentation

◆ getRequiredModules()

std::vector< std::string > clang::clangd::ScanningAllProjectModules::getRequiredModules ( PathRef  File)
inlineoverridevirtual

Implements clang::clangd::ProjectModules.

Definition at line 179 of file ScanningProjectModules.cpp.

References clang::clangd::File.

◆ getSourceForModuleName()

PathRef clang::clangd::ScanningAllProjectModules::getSourceForModuleName ( llvm::StringRef  ModuleName,
PathRef  RequiredSourceFile = PathRef() 
)
inlineoverridevirtual

RequiredSourceFile is not used intentionally.

See the comments of ModuleDependencyScanner for detail.

Implements clang::clangd::ProjectModules.

Definition at line 186 of file ScanningProjectModules.cpp.

References ModuleName.


The documentation for this class was generated from the following file: