about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src
diff options
context:
space:
mode:
authorThe Miri Cronjob Bot <miri@cron.bot>2024-12-13 05:12:21 +0000
committerThe Miri Cronjob Bot <miri@cron.bot>2024-12-13 05:12:21 +0000
commit8652177c6328fb67981ec74cfe93dd1f3399e4fa (patch)
tree5805c74a884bf2d344c0db89dfef759a8435d0d2 /compiler/rustc_codegen_llvm/src
parent70628f8b8d58e720ca91ec558e9d80797bfa6387 (diff)
parentf4f0fafd0c7849e162eddbc69fa5fe82dbec28c7 (diff)
downloadrust-8652177c6328fb67981ec74cfe93dd1f3399e4fa.tar.gz
rust-8652177c6328fb67981ec74cfe93dd1f3399e4fa.zip
Merge from rustc
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
-rw-r--r--compiler/rustc_codegen_llvm/src/llvm/ffi.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_llvm/src/llvm/ffi.rs b/compiler/rustc_codegen_llvm/src/llvm/ffi.rs
index 8b4523bd252..d62632d1431 100644
--- a/compiler/rustc_codegen_llvm/src/llvm/ffi.rs
+++ b/compiler/rustc_codegen_llvm/src/llvm/ffi.rs
@@ -17,7 +17,9 @@ use super::debuginfo::{
     DebugEmissionKind, DebugNameTableKind,
 };
 
-pub type Bool = c_uint;
+/// In the LLVM-C API, boolean values are passed as `typedef int LLVMBool`,
+/// which has a different ABI from Rust or C++ `bool`.
+pub type Bool = c_int;
 
 pub const True: Bool = 1 as Bool;
 pub const False: Bool = 0 as Bool;