use declarative macro for #[derive(TryFromU32)]

This commit is contained in:
Deadbeef
2025-08-16 22:08:41 +08:00
parent d2acb427e4
commit 696b6ac14d
10 changed files with 28 additions and 192 deletions

View File

@@ -19,7 +19,6 @@ use std::ptr;
use bitflags::bitflags;
use libc::{c_char, c_int, c_uchar, c_uint, c_ulonglong, c_void, size_t};
use rustc_macros::TryFromU32;
use super::RustString;
use super::debuginfo::{
@@ -27,8 +26,8 @@ use super::debuginfo::{
DIGlobalVariableExpression, DILocation, DISPFlags, DIScope, DISubprogram,
DITemplateTypeParameter, DIType, DebugEmissionKind, DebugNameTableKind,
};
use crate::llvm;
use crate::llvm::MetadataKindId;
use crate::{TryFromU32, llvm};
/// In the LLVM-C API, boolean values are passed as `typedef int LLVMBool`,
/// which has a different ABI from Rust or C++ `bool`.