@@ -247,7 +247,7 @@ trait DropTreeBuilder<'tcx> {
247
247
248
248
/// Links a block outside the drop tree, `from`, to the block `to` inside
249
249
/// the drop tree.
250
- fn add_entry ( cfg : & mut CFG < ' tcx > , from : BasicBlock , to : BasicBlock ) ;
250
+ fn link_entry_point ( cfg : & mut CFG < ' tcx > , from : BasicBlock , to : BasicBlock ) ;
251
251
}
252
252
253
253
impl DropTree {
@@ -332,7 +332,7 @@ impl DropTree {
332
332
needs_block[ drop_idx] = Block :: Own ;
333
333
while entry_points. last ( ) . is_some_and ( |entry_point| entry_point. 0 == drop_idx) {
334
334
let entry_block = entry_points. pop ( ) . unwrap ( ) . 1 ;
335
- T :: add_entry ( cfg, entry_block, block) ;
335
+ T :: link_entry_point ( cfg, entry_block, block) ;
336
336
}
337
337
}
338
338
match needs_block[ drop_idx] {
@@ -1439,7 +1439,7 @@ impl<'tcx> DropTreeBuilder<'tcx> for ExitScopes {
1439
1439
fn make_block ( cfg : & mut CFG < ' tcx > ) -> BasicBlock {
1440
1440
cfg. start_new_block ( )
1441
1441
}
1442
- fn add_entry ( cfg : & mut CFG < ' tcx > , from : BasicBlock , to : BasicBlock ) {
1442
+ fn link_entry_point ( cfg : & mut CFG < ' tcx > , from : BasicBlock , to : BasicBlock ) {
1443
1443
cfg. block_data_mut ( from) . terminator_mut ( ) . kind = TerminatorKind :: Goto { target : to } ;
1444
1444
}
1445
1445
}
@@ -1450,7 +1450,7 @@ impl<'tcx> DropTreeBuilder<'tcx> for CoroutineDrop {
1450
1450
fn make_block ( cfg : & mut CFG < ' tcx > ) -> BasicBlock {
1451
1451
cfg. start_new_block ( )
1452
1452
}
1453
- fn add_entry ( cfg : & mut CFG < ' tcx > , from : BasicBlock , to : BasicBlock ) {
1453
+ fn link_entry_point ( cfg : & mut CFG < ' tcx > , from : BasicBlock , to : BasicBlock ) {
1454
1454
let term = cfg. block_data_mut ( from) . terminator_mut ( ) ;
1455
1455
if let TerminatorKind :: Yield { ref mut drop, .. } = term. kind {
1456
1456
* drop = Some ( to) ;
@@ -1470,7 +1470,7 @@ impl<'tcx> DropTreeBuilder<'tcx> for Unwind {
1470
1470
fn make_block ( cfg : & mut CFG < ' tcx > ) -> BasicBlock {
1471
1471
cfg. start_new_cleanup_block ( )
1472
1472
}
1473
- fn add_entry ( cfg : & mut CFG < ' tcx > , from : BasicBlock , to : BasicBlock ) {
1473
+ fn link_entry_point ( cfg : & mut CFG < ' tcx > , from : BasicBlock , to : BasicBlock ) {
1474
1474
let term = & mut cfg. block_data_mut ( from) . terminator_mut ( ) ;
1475
1475
match & mut term. kind {
1476
1476
TerminatorKind :: Drop { unwind, .. } => {
0 commit comments