Skip to content

Commit

Permalink
Load the compiler instance plugins.
Browse files Browse the repository at this point in the history
This patch should resolve an issue in xeus-clang-repl with clad.
  • Loading branch information
vgvassilev committed Oct 14, 2023
1 parent ff578da commit af1256f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions include/clang/Interpreter/Compatibility.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ namespace compat {
#ifdef USE_REPL

#include "clang/AST/Mangle.h"
#include "clang/Frontend/CompilerInstance.h"
#include "clang/Interpreter/DynamicLibraryManager.h"
#include "clang/Interpreter/Interpreter.h"
#include "clang/Interpreter/Value.h"
Expand Down Expand Up @@ -117,6 +118,9 @@ createClangInterpreter(std::vector<const char*>& args) {
#if CLANG_VERSION_MAJOR < 16
auto innerOrErr = clang::Interpreter::create(std::move(*ciOrErr));
#else
(*ciOrErr)->LoadRequestedPlugins();
if (CudaEnabled)
DeviceCI->LoadRequestedPlugins();
auto innerOrErr =
CudaEnabled ? clang::Interpreter::createWithCUDA(std::move(*ciOrErr),
std::move(DeviceCI))
Expand Down

0 comments on commit af1256f

Please sign in to comment.