Skip to content

Commit 6596cfd

Browse files
committed
di: Provide safe wrappers for LLVM types
Provide Rust wrappers for LLVM metadata and debug info types and aim to wrap LLVM C API functions as methods of these wrappers, therefore try to make the logic of sanitizing the DI as safe as possible. The wrappers are stored in two separate modules: * `ir` - for general LLVM IR types like `Metadata` or `MDNode`. * `di` - for types representing debug information nodes like `DINode`, `DIType` etc.
1 parent ef91ad8 commit 6596cfd

File tree

4 files changed

+693
-196
lines changed

4 files changed

+693
-196
lines changed

src/linker.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,7 @@ impl Linker {
449449
// programs and maps and remove dead code.
450450

451451
unsafe {
452-
llvm::DIFix::new(self.context, self.module).run();
452+
llvm::DISanitizer::new(self.context, self.module).run();
453453

454454
llvm::optimize(
455455
self.target_machine,

0 commit comments

Comments
 (0)