Lines Matching refs:Path
62 static std::string stringFromPath(ModuleIdPath Path) { in stringFromPath() argument
64 if (Path.empty()) in stringFromPath()
67 for (auto &Piece : Path) { in stringFromPath()
180 ModuleDeclKind MDK, ModuleIdPath Path, in ActOnModuleDecl() argument
274 StringRef FirstComponentName = Path[0].first->getName(); in ActOnModuleDecl()
275 if (!getSourceManager().isInSystemHeader(Path[0].second) && in ActOnModuleDecl()
279 Diag(Path[0].second, diag::err_invalid_module_name) in ActOnModuleDecl()
280 << Path[0].first << /*reserved*/ 1; in ActOnModuleDecl()
286 for (auto Part : Path) { in ActOnModuleDecl()
294 std::string ModuleName = stringFromPath(Path); in ActOnModuleDecl()
303 Diag(Path.front().second, diag::err_current_module_name_mismatch) in ActOnModuleDecl()
304 << SourceRange(Path.front().second, IsPartition in ActOnModuleDecl()
306 : Path.back().second) in ActOnModuleDecl()
321 Diag(Path[0].second, diag::err_module_redefinition) << ModuleName; in ActOnModuleDecl()
345 PP.getIdentifierInfo(ModuleName), Path[0].second); in ActOnModuleDecl()
407 ImportDecl::Create(Context, CurContext, ModuleLoc, Mod, Path[0].second); in ActOnModuleDecl()
483 SourceLocation ImportLoc, ModuleIdPath Path, in ActOnModuleImport() argument
502 ModuleName += stringFromPath(Path); in ActOnModuleImport()
503 ModuleNameLoc = {PP.getIdentifierInfo(ModuleName), Path[0].second}; in ActOnModuleImport()
504 Path = ModuleIdPath(ModuleNameLoc); in ActOnModuleImport()
506 ModuleName = stringFromPath(Path); in ActOnModuleImport()
507 ModuleNameLoc = {PP.getIdentifierInfo(ModuleName), Path[0].second}; in ActOnModuleImport()
508 Path = ModuleIdPath(ModuleNameLoc); in ActOnModuleImport()
526 ImportLoc, Path, Module::AllVisible, /*IsInclusionDirective=*/false); in ActOnModuleImport()
530 return ActOnModuleImport(StartLoc, ExportLoc, ImportLoc, Mod, Path); in ActOnModuleImport()
544 ModuleIdPath Path) { in ActOnModuleImport() argument
563 if (Path.empty()) { in ActOnModuleImport()
571 IdentifierLocs.push_back(Path[0].second); in ActOnModuleImport()
574 for (unsigned I = 0, N = Path.size(); I != N; ++I) { in ActOnModuleImport()
581 IdentifierLocs.push_back(Path[I].second); in ActOnModuleImport()
598 << SourceRange(ExportLoc, Path.back().second); in ActOnModuleImport()