Changeset View
Changeset View
Standalone View
Standalone View
clang/include/clang/Sema/Sema.h
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
Show First 20 Lines • Show All 2,209 Lines • ▼ Show 20 Lines | private: | ||||
VisibleModuleSet VisibleModules; | VisibleModuleSet VisibleModules; | ||||
public: | public: | ||||
/// Get the module owning an entity. | /// Get the module owning an entity. | ||||
Module *getOwningModule(const Decl *Entity) { | Module *getOwningModule(const Decl *Entity) { | ||||
return Entity->getOwningModule(); | return Entity->getOwningModule(); | ||||
} | } | ||||
StringRef getCurrentModuleName() const; | |||||
bool IsCurrentModulePartition() const; | |||||
/// Make a merged definition of an existing hidden definition \p ND | /// Make a merged definition of an existing hidden definition \p ND | ||||
/// visible at the specified location. | /// visible at the specified location. | ||||
void makeMergedDefinitionVisible(NamedDecl *ND); | void makeMergedDefinitionVisible(NamedDecl *ND); | ||||
bool isModuleVisible(const Module *M, bool ModulePrivate = false); | bool isModuleVisible(const Module *M, bool ModulePrivate = false); | ||||
// When loading a non-modular PCH files, this is used to restore module | // When loading a non-modular PCH files, this is used to restore module | ||||
▲ Show 20 Lines • Show All 684 Lines • ▼ Show 20 Lines | public: | ||||
/// Handle a C++11 empty-declaration and attribute-declaration. | /// Handle a C++11 empty-declaration and attribute-declaration. | ||||
Decl *ActOnEmptyDeclaration(Scope *S, const ParsedAttributesView &AttrList, | Decl *ActOnEmptyDeclaration(Scope *S, const ParsedAttributesView &AttrList, | ||||
SourceLocation SemiLoc); | SourceLocation SemiLoc); | ||||
enum class ModuleDeclKind { | enum class ModuleDeclKind { | ||||
Interface, ///< 'export module X;' | Interface, ///< 'export module X;' | ||||
Implementation, ///< 'module X;' | Implementation, ///< 'module X;' | ||||
Partition, ///< 'export module X:Y;' | |||||
///< 'module X:Y;' | |||||
}; | }; | ||||
/// The parser has processed a module-declaration that begins the definition | /// The parser has processed a module-declaration that begins the definition | ||||
/// of a module interface or implementation. | /// of a module interface or implementation. | ||||
DeclGroupPtrTy ActOnModuleDecl(SourceLocation StartLoc, | DeclGroupPtrTy ActOnModuleDecl(SourceLocation StartLoc, | ||||
SourceLocation ModuleLoc, ModuleDeclKind MDK, | SourceLocation ModuleLoc, ModuleDeclKind MDK, | ||||
ModuleIdPath Path, bool IsFirstDecl); | ModuleIdPath Path, ModuleIdPath PartitionPath, | ||||
bool IsFirstDecl); | |||||
/// The parser has processed a global-module-fragment declaration that begins | /// The parser has processed a global-module-fragment declaration that begins | ||||
/// the definition of the global module fragment of the current module unit. | /// the definition of the global module fragment of the current module unit. | ||||
/// \param ModuleLoc The location of the 'module' keyword. | /// \param ModuleLoc The location of the 'module' keyword. | ||||
DeclGroupPtrTy ActOnGlobalModuleFragmentDecl(SourceLocation ModuleLoc); | DeclGroupPtrTy ActOnGlobalModuleFragmentDecl(SourceLocation ModuleLoc); | ||||
/// The parser has processed a private-module-fragment declaration that begins | /// The parser has processed a private-module-fragment declaration that begins | ||||
/// the definition of the private module fragment of the current module unit. | /// the definition of the private module fragment of the current module unit. | ||||
/// \param ModuleLoc The location of the 'module' keyword. | /// \param ModuleLoc The location of the 'module' keyword. | ||||
/// \param PrivateLoc The location of the 'private' keyword. | /// \param PrivateLoc The location of the 'private' keyword. | ||||
DeclGroupPtrTy ActOnPrivateModuleFragmentDecl(SourceLocation ModuleLoc, | DeclGroupPtrTy ActOnPrivateModuleFragmentDecl(SourceLocation ModuleLoc, | ||||
SourceLocation PrivateLoc); | SourceLocation PrivateLoc); | ||||
/// The parser has processed a module import declaration. | /// The parser has processed a module import declaration. | ||||
/// | /// | ||||
/// \param StartLoc The location of the first token in the declaration. This | /// \param StartLoc The location of the first token in the declaration. This | ||||
/// could be the location of an '@', 'export', or 'import'. | /// could be the location of an '@', 'export', or 'import'. | ||||
/// \param ExportLoc The location of the 'export' keyword, if any. | /// \param ExportLoc The location of the 'export' keyword, if any. | ||||
/// \param ImportLoc The location of the 'import' keyword. | /// \param ImportLoc The location of the 'import' keyword. | ||||
/// \param Path The module access path. | /// \param Path The module access path. | ||||
DeclResult ActOnModuleImport(SourceLocation StartLoc, | DeclResult ActOnModuleImport(SourceLocation StartLoc, | ||||
SourceLocation ExportLoc, | SourceLocation ExportLoc, | ||||
SourceLocation ImportLoc, ModuleIdPath Path); | SourceLocation ImportLoc, ModuleIdPath Path, | ||||
bool IsPartition = false); | |||||
DeclResult ActOnModuleImport(SourceLocation StartLoc, | DeclResult ActOnModuleImport(SourceLocation StartLoc, | ||||
SourceLocation ExportLoc, | SourceLocation ExportLoc, | ||||
SourceLocation ImportLoc, Module *M, | SourceLocation ImportLoc, Module *M, | ||||
ModuleIdPath Path = {}); | ModuleIdPath Path = {}, | ||||
bool IsPartition = false); | |||||
/// The parser has processed a module import translated from a | /// The parser has processed a module import translated from a | ||||
/// #include or similar preprocessing directive. | /// #include or similar preprocessing directive. | ||||
void ActOnModuleInclude(SourceLocation DirectiveLoc, Module *Mod); | void ActOnModuleInclude(SourceLocation DirectiveLoc, Module *Mod); | ||||
void BuildModuleInclude(SourceLocation DirectiveLoc, Module *Mod); | void BuildModuleInclude(SourceLocation DirectiveLoc, Module *Mod); | ||||
/// The parsed has entered a submodule. | /// The parsed has entered a submodule. | ||||
void ActOnModuleBegin(SourceLocation DirectiveLoc, Module *Mod); | void ActOnModuleBegin(SourceLocation DirectiveLoc, Module *Mod); | ||||
▲ Show 20 Lines • Show All 9,991 Lines • Show Last 20 Lines |