aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Interpreter/Interpreter.cpp
diff options
context:
space:
mode:
authorKadir Cetinkaya <kadircet@google.com>2024-11-21 13:04:30 +0100
committerKadir Cetinkaya <kadircet@google.com>2024-11-21 14:55:30 +0100
commitdf9a14d7bbf1180e4f1474254c9d7ed6bcb4ce55 (patch)
tree4f440ad02ebb7990fda10120328a833459b1ab89 /clang/lib/Interpreter/Interpreter.cpp
parentd800ea7cb12245f65f886e18545ba83355825246 (diff)
downloadllvm-df9a14d7bbf1180e4f1474254c9d7ed6bcb4ce55.zip
llvm-df9a14d7bbf1180e4f1474254c9d7ed6bcb4ce55.tar.gz
llvm-df9a14d7bbf1180e4f1474254c9d7ed6bcb4ce55.tar.bz2
Reapply "[NFC] Explicitly pass a VFS when creating DiagnosticsEngine (#115852)"
This reverts commit a1153cd6fedd4c906a9840987934ca4712e34cb2 with fixes to lldb breakages. Fixes https://github.com/llvm/llvm-project/issues/117145.
Diffstat (limited to 'clang/lib/Interpreter/Interpreter.cpp')
-rw-r--r--clang/lib/Interpreter/Interpreter.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Interpreter/Interpreter.cpp b/clang/lib/Interpreter/Interpreter.cpp
index 94f0156..5dc67f6 100644
--- a/clang/lib/Interpreter/Interpreter.cpp
+++ b/clang/lib/Interpreter/Interpreter.cpp
@@ -15,6 +15,7 @@
#include "IncrementalExecutor.h"
#include "IncrementalParser.h"
#include "InterpreterUtils.h"
+#include "llvm/Support/VirtualFileSystem.h"
#ifdef __EMSCRIPTEN__
#include "Wasm.h"
#endif // __EMSCRIPTEN__
@@ -106,7 +107,7 @@ CreateCI(const llvm::opt::ArgStringList &Argv) {
CompilerInvocation::GetResourcesPath(Argv[0], nullptr);
// Create the actual diagnostics engine.
- Clang->createDiagnostics();
+ Clang->createDiagnostics(*llvm::vfs::getRealFileSystem());
if (!Clang->hasDiagnostics())
return llvm::createStringError(llvm::errc::not_supported,
"Initialization failed. "