[eddyb] rustc_codegen_ssa: handle LLVM unsafety correctly.
This commit is contained in:
parent
bf7f8cd3fc
commit
9bb6663431
7 changed files with 29 additions and 22 deletions
|
@ -194,7 +194,9 @@ pub fn compile_codegen_unit<'ll, 'tcx>(tcx: TyCtxt<'ll, 'tcx, 'tcx>,
|
|||
|
||||
// Run replace-all-uses-with for statics that need it
|
||||
for &(old_g, new_g) in cx.statics_to_rauw().borrow().iter() {
|
||||
cx.static_replace_all_uses(old_g, new_g)
|
||||
unsafe {
|
||||
cx.static_replace_all_uses(old_g, new_g)
|
||||
}
|
||||
}
|
||||
|
||||
// Create the llvm.used variable
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue