Skip to content

Commit 7ad5b18

Browse files
committed
[clang] NFCI: Use FileEntryRef in ASTWriter
1 parent 45bf8e4 commit 7ad5b18

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clang/lib/Serialization/ASTWriter.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1550,7 +1550,7 @@ void ASTWriter::WriteControlBlock(Preprocessor &PP, ASTContext &Context,
15501550

15511551
// Original file name and file ID
15521552
SourceManager &SM = Context.getSourceManager();
1553-
if (const FileEntry *MainFile = SM.getFileEntryForID(SM.getMainFileID())) {
1553+
if (auto MainFile = SM.getFileEntryRefForID(SM.getMainFileID())) {
15541554
auto FileAbbrev = std::make_shared<BitCodeAbbrev>();
15551555
FileAbbrev->Add(BitCodeAbbrevOp(ORIGINAL_FILE));
15561556
FileAbbrev->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // File ID

0 commit comments

Comments
 (0)