#include "clang/AST/ASTConsumer.h"
#include "clang/AST/ASTMutationListener.h"
#include "clang/Lex/HeaderSearch.h"
#include "clang/Lex/Preprocessor.h"
#include "clang/Sema/SemaInternal.h"
#include "llvm/ADT/StringExtras.h"
#include <optional>
usingnamespaceclang;
usingnamespacesema;
static void checkModuleImportContext(Sema &S, Module *M,
SourceLocation ImportLoc, DeclContext *DC,
bool FromInclude = false) { … }
static std::string stringFromPath(ModuleIdPath Path) { … }
static bool
isImportingModuleUnitFromSameModule(ASTContext &Ctx, Module *Imported,
Module *CurrentModule,
Module *&FoundPrimaryModuleInterface) { … }
static void
makeTransitiveImportsVisible(ASTContext &Ctx, VisibleModuleSet &VisibleModules,
Module *Imported, Module *CurrentModule,
SourceLocation ImportLoc,
bool IsImportingPrimaryModuleInterface = false) { … }
Sema::DeclGroupPtrTy
Sema::ActOnGlobalModuleFragmentDecl(SourceLocation ModuleLoc) { … }
void Sema::HandleStartOfHeaderUnit() { … }
static bool DiagReservedModuleName(Sema &S, const IdentifierInfo *II,
SourceLocation Loc) { … }
Sema::DeclGroupPtrTy
Sema::ActOnModuleDecl(SourceLocation StartLoc, SourceLocation ModuleLoc,
ModuleDeclKind MDK, ModuleIdPath Path,
ModuleIdPath Partition, ModuleImportState &ImportState) { … }
Sema::DeclGroupPtrTy
Sema::ActOnPrivateModuleFragmentDecl(SourceLocation ModuleLoc,
SourceLocation PrivateLoc) { … }
DeclResult Sema::ActOnModuleImport(SourceLocation StartLoc,
SourceLocation ExportLoc,
SourceLocation ImportLoc, ModuleIdPath Path,
bool IsPartition) { … }
static const ExportDecl *getEnclosingExportDecl(const Decl *D) { … }
DeclResult Sema::ActOnModuleImport(SourceLocation StartLoc,
SourceLocation ExportLoc,
SourceLocation ImportLoc, Module *Mod,
ModuleIdPath Path) { … }
void Sema::ActOnAnnotModuleInclude(SourceLocation DirectiveLoc, Module *Mod) { … }
void Sema::BuildModuleInclude(SourceLocation DirectiveLoc, Module *Mod) { … }
void Sema::ActOnAnnotModuleBegin(SourceLocation DirectiveLoc, Module *Mod) { … }
void Sema::ActOnAnnotModuleEnd(SourceLocation EomLoc, Module *Mod) { … }
void Sema::createImplicitModuleImportForErrorRecovery(SourceLocation Loc,
Module *Mod) { … }
Decl *Sema::ActOnStartExportDecl(Scope *S, SourceLocation ExportLoc,
SourceLocation LBraceLoc) { … }
static bool checkExportedDecl(Sema &, Decl *, SourceLocation);
static bool checkExportedDeclContext(Sema &S, DeclContext *DC,
SourceLocation BlockStart) { … }
static bool checkExportedDecl(Sema &S, Decl *D, SourceLocation BlockStart) { … }
Decl *Sema::ActOnFinishExportDecl(Scope *S, Decl *D, SourceLocation RBraceLoc) { … }
Module *Sema::PushGlobalModuleFragment(SourceLocation BeginLoc) { … }
void Sema::PopGlobalModuleFragment() { … }
Module *Sema::PushImplicitGlobalModuleFragment(SourceLocation BeginLoc) { … }
void Sema::PopImplicitGlobalModuleFragment() { … }
bool Sema::isCurrentModulePurview() const { … }