diff options
Diffstat (limited to 'clang/lib/Frontend/CompilerInstance.cpp')
-rw-r--r-- | clang/lib/Frontend/CompilerInstance.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/Frontend/CompilerInstance.cpp b/clang/lib/Frontend/CompilerInstance.cpp index ecc1c4c..9c79e85 100644 --- a/clang/lib/Frontend/CompilerInstance.cpp +++ b/clang/lib/Frontend/CompilerInstance.cpp @@ -851,6 +851,9 @@ CompilerInstance::createOutputFileImpl(StringRef OutputPath, bool Binary, // relative to that. std::optional<SmallString<128>> AbsPath; if (OutputPath != "-" && !llvm::sys::path::is_absolute(OutputPath)) { + assert(hasFileManager() && + "File Manager is required to fix up relative path.\n"); + AbsPath.emplace(OutputPath); FileMgr->FixupRelativePath(*AbsPath); OutputPath = *AbsPath; |