@@ -139,7 +139,7 @@ class ExternalHeaderFileInfoSource {
139139 // / \returns Header file information for the given file entry, with the
140140 // / \c External bit set. If the file entry is not known, return a
141141 // / default-constructed \c HeaderFileInfo.
142- virtual HeaderFileInfo GetHeaderFileInfo (const FileEntry * FE) = 0;
142+ virtual HeaderFileInfo GetHeaderFileInfo (FileEntryRef FE) = 0;
143143};
144144
145145// / This structure is used to record entries in our framework cache.
@@ -487,7 +487,7 @@ class HeaderSearch {
487487 OptionalFileEntryRef LookupFile (
488488 StringRef Filename, SourceLocation IncludeLoc, bool isAngled,
489489 ConstSearchDirIterator FromDir, ConstSearchDirIterator *CurDir,
490- ArrayRef<std::pair<const FileEntry * , DirectoryEntryRef>> Includers,
490+ ArrayRef<std::pair<OptionalFileEntryRef , DirectoryEntryRef>> Includers,
491491 SmallVectorImpl<char > *SearchPath, SmallVectorImpl<char > *RelativePath,
492492 Module *RequestingModule, ModuleMap::KnownHeader *SuggestedModule,
493493 bool *IsMapped, bool *IsFrameworkFound, bool SkipCache = false ,
@@ -522,33 +522,32 @@ class HeaderSearch {
522522
523523 // / Return whether the specified file is a normal header,
524524 // / a system header, or a C++ friendly system header.
525- SrcMgr::CharacteristicKind getFileDirFlavor (const FileEntry * File) {
525+ SrcMgr::CharacteristicKind getFileDirFlavor (FileEntryRef File) {
526526 return (SrcMgr::CharacteristicKind)getFileInfo (File).DirInfo ;
527527 }
528528
529529 // / Mark the specified file as a "once only" file due to
530530 // / \#pragma once.
531- void MarkFileIncludeOnce (const FileEntry * File) {
531+ void MarkFileIncludeOnce (FileEntryRef File) {
532532 HeaderFileInfo &FI = getFileInfo (File);
533533 FI.isPragmaOnce = true ;
534534 }
535535
536536 // / Mark the specified file as a system header, e.g. due to
537537 // / \#pragma GCC system_header.
538- void MarkFileSystemHeader (const FileEntry * File) {
538+ void MarkFileSystemHeader (FileEntryRef File) {
539539 getFileInfo (File).DirInfo = SrcMgr::C_System;
540540 }
541541
542542 // / Mark the specified file as part of a module.
543- void MarkFileModuleHeader (const FileEntry *FE,
544- ModuleMap::ModuleHeaderRole Role,
543+ void MarkFileModuleHeader (FileEntryRef FE, ModuleMap::ModuleHeaderRole Role,
545544 bool isCompilingModuleHeader);
546545
547546 // / Mark the specified file as having a controlling macro.
548547 // /
549548 // / This is used by the multiple-include optimization to eliminate
550549 // / no-op \#includes.
551- void SetFileControllingMacro (const FileEntry * File,
550+ void SetFileControllingMacro (FileEntryRef File,
552551 const IdentifierInfo *ControllingMacro) {
553552 getFileInfo (File).ControllingMacro = ControllingMacro;
554553 }
@@ -558,10 +557,10 @@ class HeaderSearch {
558557 // / macro.
559558 // /
560559 // / This routine does not consider the effect of \#import
561- bool isFileMultipleIncludeGuarded (const FileEntry * File) const ;
560+ bool isFileMultipleIncludeGuarded (FileEntryRef File) const ;
562561
563562 // / Determine whether the given file is known to have ever been \#imported.
564- bool hasFileBeenImported (const FileEntry * File) const {
563+ bool hasFileBeenImported (FileEntryRef File) const {
565564 const HeaderFileInfo *FI = getExistingFileInfo (File);
566565 return FI && FI->isImport ;
567566 }
@@ -806,13 +805,13 @@ class HeaderSearch {
806805
807806 // / Return the HeaderFileInfo structure for the specified FileEntry,
808807 // / in preparation for updating it in some way.
809- HeaderFileInfo &getFileInfo (const FileEntry * FE);
808+ HeaderFileInfo &getFileInfo (FileEntryRef FE);
810809
811810 // / Return the HeaderFileInfo structure for the specified FileEntry,
812811 // / if it has ever been filled in.
813812 // / \param WantExternal Whether the caller wants purely-external header file
814813 // / info (where \p External is true).
815- const HeaderFileInfo *getExistingFileInfo (const FileEntry * FE,
814+ const HeaderFileInfo *getExistingFileInfo (FileEntryRef FE,
816815 bool WantExternal = true ) const ;
817816
818817 SearchDirIterator search_dir_begin () { return {*this , 0 }; }
0 commit comments