diff options
author | Jan Svoboda <jan_svoboda@apple.com> | 2023-09-06 11:58:59 -0700 |
---|---|---|
committer | Jan Svoboda <jan_svoboda@apple.com> | 2023-09-06 11:59:40 -0700 |
commit | 65331da0032ab4253a4bc0ddcb2da67664bd86a9 (patch) | |
tree | 4b05b238451d25e130f6ca9b582fff51c323930c /clang/lib/Rewrite/Rewriter.cpp | |
parent | 24a08592bcb027dfd84d5672f7b5c2c67a4fbbc5 (diff) | |
download | llvm-65331da0032ab4253a4bc0ddcb2da67664bd86a9.zip llvm-65331da0032ab4253a4bc0ddcb2da67664bd86a9.tar.gz llvm-65331da0032ab4253a4bc0ddcb2da67664bd86a9.tar.bz2 |
Partially revert "[clang] NFCI: Adopt `SourceManager::getFileEntryRefForID()`"
This commit partially reverts ddbcc10b to fix `clang-tools-extra/test/clang-tidy/infrastructure/clang-tidy-run-with-database.cpp`.
Diffstat (limited to 'clang/lib/Rewrite/Rewriter.cpp')
-rw-r--r-- | clang/lib/Rewrite/Rewriter.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Rewrite/Rewriter.cpp b/clang/lib/Rewrite/Rewriter.cpp index ae04b51..ef28589 100644 --- a/clang/lib/Rewrite/Rewriter.cpp +++ b/clang/lib/Rewrite/Rewriter.cpp @@ -412,7 +412,7 @@ bool Rewriter::overwriteChangedFiles() { unsigned OverwriteFailure = Diag.getCustomDiagID( DiagnosticsEngine::Error, "unable to overwrite file %0: %1"); for (buffer_iterator I = buffer_begin(), E = buffer_end(); I != E; ++I) { - OptionalFileEntryRef Entry = getSourceMgr().getFileEntryRefForID(I->first); + const FileEntry *Entry = getSourceMgr().getFileEntryForID(I->first); if (auto Error = llvm::writeToOutput(Entry->getName(), [&](llvm::raw_ostream &OS) { I->second.write(OS); |