@@ -420,13 +420,10 @@ impl<'a, 'tcx> Borrows<'a, 'tcx> {
420
420
regioncx : & ' a RegionInferenceContext < ' tcx > ,
421
421
borrow_set : & ' a BorrowSet < ' tcx > ,
422
422
) -> Self {
423
- let mut borrows_out_of_scope_at_location =
424
- calculate_borrows_out_of_scope_at_location ( body, regioncx, borrow_set) ;
425
-
426
- // The in-tree polonius analysis computes loans going out of scope using the set-of-loans
427
- // model, and makes sure they're identical to the existing computation of the set-of-points
428
- // model.
429
- if tcx. sess . opts . unstable_opts . polonius . is_next_enabled ( ) {
423
+ let borrows_out_of_scope_at_location = {
424
+ // The in-tree polonius analysis computes loans going out of scope using the set-of-loans
425
+ // model, and makes sure they're identical to the existing computation of the set-of-points
426
+ // model.
430
427
let mut polonius_prec = PoloniusOutOfScopePrecomputer :: new ( body, regioncx) ;
431
428
for ( loan_idx, loan_data) in borrow_set. iter_enumerated ( ) {
432
429
let issuing_region = loan_data. region ;
@@ -439,13 +436,8 @@ impl<'a, 'tcx> Borrows<'a, 'tcx> {
439
436
) ;
440
437
}
441
438
442
- assert_eq ! (
443
- polonius_prec. loans_out_of_scope_at_location, borrows_out_of_scope_at_location,
444
- "the loans out of scope are different from the borrows out of scope"
445
- ) ;
446
-
447
- borrows_out_of_scope_at_location = polonius_prec. loans_out_of_scope_at_location ;
448
- }
439
+ polonius_prec. loans_out_of_scope_at_location
440
+ } ;
449
441
450
442
Borrows { tcx, body, borrow_set, borrows_out_of_scope_at_location }
451
443
}
0 commit comments