about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src/asm.rs
diff options
context:
space:
mode:
authorZalathar <Zalathar@users.noreply.github.com>2025-05-11 14:09:50 +1000
committerZalathar <Zalathar@users.noreply.github.com>2025-05-11 14:38:42 +1000
commitb6300294a852f9a14ab9eb1f706d4a966aeb18ed (patch)
treec9082b787e187de9fa1a45237a9b9c3ba0bc40b0 /compiler/rustc_codegen_llvm/src/asm.rs
parentb1094f6a0a489bb1bc2be6ca17d2bec269bd9364 (diff)
downloadrust-b6300294a852f9a14ab9eb1f706d4a966aeb18ed.tar.gz
rust-b6300294a852f9a14ab9eb1f706d4a966aeb18ed.zip
Make `LLVMRustInlineAsmVerify` take `*const c_uchar`
This avoids the need for an explicit `as_c_char_ptr` conversion.
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/asm.rs')
-rw-r--r--compiler/rustc_codegen_llvm/src/asm.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/compiler/rustc_codegen_llvm/src/asm.rs b/compiler/rustc_codegen_llvm/src/asm.rs
index 15bd1f6901d..c0b75fa43b7 100644
--- a/compiler/rustc_codegen_llvm/src/asm.rs
+++ b/compiler/rustc_codegen_llvm/src/asm.rs
@@ -14,7 +14,7 @@ use smallvec::SmallVec;
 use tracing::debug;
 
 use crate::builder::Builder;
-use crate::common::{AsCCharPtr, Funclet};
+use crate::common::Funclet;
 use crate::context::CodegenCx;
 use crate::type_::Type;
 use crate::type_of::LayoutLlvmExt;
@@ -477,8 +477,7 @@ pub(crate) fn inline_asm_call<'ll>(
     debug!("Asm Output Type: {:?}", output);
     let fty = bx.cx.type_func(&argtys, output);
     // Ask LLVM to verify that the constraints are well-formed.
-    let constraints_ok =
-        unsafe { llvm::LLVMRustInlineAsmVerify(fty, cons.as_c_char_ptr(), cons.len()) };
+    let constraints_ok = unsafe { llvm::LLVMRustInlineAsmVerify(fty, cons.as_ptr(), cons.len()) };
     debug!("constraint verification result: {:?}", constraints_ok);
     if constraints_ok {
         let v = unsafe {