Skip to content

Commit 634251c

Browse files
committed
Accommodate upstream PassPlugin rename
1 parent 2e854a9 commit 634251c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,11 @@
2323
#include "llvm/MC/TargetRegistry.h"
2424
#include "llvm/Object/ObjectFile.h"
2525
#include "llvm/Passes/PassBuilder.h"
26+
#if LLVM_VERSION_GE(22, 0)
27+
#include "llvm/Plugins/PassPlugin.h"
28+
#else
2629
#include "llvm/Passes/PassPlugin.h"
30+
#endif
2731
#include "llvm/Passes/StandardInstrumentations.h"
2832
#include "llvm/Support/CBindingWrapping.h"
2933
#include "llvm/Support/FileSystem.h"

0 commit comments

Comments
 (0)