@@ -41,6 +41,7 @@ pub(crate) fn emit_facts<'tcx>(
41
41
borrow_set : & BorrowSet < ' tcx > ,
42
42
move_data : & MoveData < ' tcx > ,
43
43
universal_region_relations : & UniversalRegionRelations < ' tcx > ,
44
+ constraints : & MirTypeckRegionConstraints < ' tcx > ,
44
45
) {
45
46
let Some ( all_facts) = all_facts else {
46
47
// We don't do anything if there are no facts to fill.
@@ -59,6 +60,7 @@ pub(crate) fn emit_facts<'tcx>(
59
60
& universal_region_relations. universal_regions ,
60
61
location_table,
61
62
) ;
63
+ emit_outlives_facts ( all_facts, location_table, constraints) ;
62
64
}
63
65
64
66
/// Emit facts needed for move/init analysis: moves and assignments.
@@ -198,14 +200,11 @@ pub(crate) fn emit_drop_facts<'tcx>(
198
200
199
201
/// Emit facts about the outlives constraints: the `subset` base relation, i.e. not a transitive
200
202
/// closure.
201
- pub ( crate ) fn emit_outlives_facts < ' tcx > (
202
- tcx : TyCtxt < ' tcx > ,
203
- constraints : & MirTypeckRegionConstraints < ' tcx > ,
203
+ fn emit_outlives_facts < ' tcx > (
204
+ facts : & mut AllFacts ,
204
205
location_table : & LocationTable ,
205
- all_facts : & mut Option < AllFacts > ,
206
+ constraints : & MirTypeckRegionConstraints < ' tcx > ,
206
207
) {
207
- let Some ( facts) = all_facts else { return } ;
208
- let _prof_timer = tcx. prof . generic_activity ( "polonius_fact_generation" ) ;
209
208
facts. subset_base . extend ( constraints. outlives_constraints . outlives ( ) . iter ( ) . flat_map (
210
209
|constraint : & OutlivesConstraint < ' _ > | {
211
210
if let Some ( from_location) = constraint. locations . from_location ( ) {
0 commit comments