diff options
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp')
| -rw-r--r-- | compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp b/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp index 858251ff9c8..545422682f0 100644 --- a/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp +++ b/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp @@ -438,8 +438,7 @@ LLVMRustCreateAttrNoValue(LLVMContextRef C, LLVMRustAttributeKind RustAttr) { #if LLVM_VERSION_GE(21, 0) // LLVM 21 replaced the NoCapture attribute with Captures(none). if (RustAttr == LLVMRustAttributeKind::NoCapture) { - return wrap(Attribute::get(*unwrap(C), Attribute::Captures, - CaptureInfo::none().toIntValue())); + return wrap(Attribute::getWithCaptureInfo(*unwrap(C), CaptureInfo::none())); } #endif return wrap(Attribute::get(*unwrap(C), fromRust(RustAttr))); |
