Skip to content

Commit 871b4fe

Browse files
authored
Add a comment about drop(start_bx)
1 parent de2e16c commit 871b4fe

File tree

1 file changed

+2
-0
lines changed
  • compiler/rustc_codegen_ssa/src/mir

1 file changed

+2
-0
lines changed

compiler/rustc_codegen_ssa/src/mir/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -258,6 +258,8 @@ pub fn codegen_mir<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>>(
258258
// Apply debuginfo to the newly allocated locals.
259259
fx.debug_introduce_locals(&mut start_bx);
260260

261+
// The builders will be created separately for each basic block at `codegen_block`.
262+
// So drop the builder of `start_llbb` to avoid having two at the same time.
261263
drop(start_bx);
262264

263265
// Codegen the body of each block using reverse postorder

0 commit comments

Comments
 (0)