[all-commits] [llvm/llvm-project] 8615ea: [clang] NFCI: Make `ModuleFile::File` non-optional...
Jan Svoboda via All-commits
all-commits at lists.llvm.org
Fri Dec 8 15:43:14 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 8615ead9a6d37e6353df1b652aadebe71ec6c242
https://github.com/llvm/llvm-project/commit/8615ead9a6d37e6353df1b652aadebe71ec6c242
Author: Jan Svoboda <jan_svoboda at apple.com>
Date: 2023-12-08 (Fri, 08 Dec 2023)
Changed paths:
M clang/include/clang/Serialization/ModuleFile.h
M clang/lib/Serialization/ASTReader.cpp
M clang/lib/Serialization/ASTWriter.cpp
M clang/lib/Serialization/GlobalModuleIndex.cpp
M clang/lib/Serialization/ModuleManager.cpp
Log Message:
-----------
[clang] NFCI: Make `ModuleFile::File` non-optional (#74892)
AFAICT, `ModuleFile::File` can be `std::nullopt` only for PCM files
loaded from the standard input. This patch starts setting that variable
to `FileManager::getSTDIN()` in that case, which makes it possible to
remove the optionality, and also simplifies code that actually reads the
file.
This is part of an effort to get rid of
`Optional{File,Directory}EntryRefDegradesTo{File,Directory}EntryPtr`.
More information about the All-commits
mailing list