rename LocationTable to PoloniusLocationTable

Its original naming hides the fact that it's related to datalog
polonius, and bound to be deleted in the near future.

It also conflicts with the expected name for the actual NLL location
map, and prefixing it with its use will make the differentiation
possible.
This commit is contained in:
Rémy Rakic
2025-01-08 11:22:03 +00:00
parent 6f1c4177e7
commit 3a1a621115
10 changed files with 47 additions and 46 deletions

View File

@@ -56,7 +56,7 @@ use crate::diagnostics::{
use crate::path_utils::*;
use crate::place_ext::PlaceExt;
use crate::places_conflict::{PlaceConflictBias, places_conflict};
use crate::polonius::legacy::{LocationTable, PoloniusOutput};
use crate::polonius::legacy::{PoloniusLocationTable, PoloniusOutput};
use crate::prefixes::PrefixSet;
use crate::region_infer::RegionInferenceContext;
use crate::renumber::RegionCtxt;
@@ -175,7 +175,7 @@ fn do_mir_borrowck<'tcx>(
infcx.register_predefined_opaques_for_next_solver(def);
}
let location_table = LocationTable::new(body);
let location_table = PoloniusLocationTable::new(body);
let move_data = MoveData::gather_moves(body, tcx, |_| true);
let promoted_move_data = promoted
@@ -246,7 +246,8 @@ fn do_mir_borrowck<'tcx>(
infcx: &infcx,
body: promoted_body,
move_data: &move_data,
location_table: &location_table, // no need to create a real one for the promoted, it is not used
// no need to create a real location table for the promoted, it is not used
location_table: &location_table,
movable_coroutine,
fn_self_span_reported: Default::default(),
locals_are_invalidated_at_exit,
@@ -512,7 +513,7 @@ struct MirBorrowckCtxt<'a, 'infcx, 'tcx> {
/// Map from MIR `Location` to `LocationIndex`; created
/// when MIR borrowck begins.
location_table: &'a LocationTable,
location_table: &'a PoloniusLocationTable,
movable_coroutine: bool,
/// This keeps track of whether local variables are free-ed when the function