mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 06:44:35 +00:00
Don't refcount PlaceholderIndices
.
It's not necessary.
This commit is contained in:
parent
fe3c49fe9a
commit
801b150737
@ -126,7 +126,6 @@ pub(crate) fn compute_regions<'a, 'tcx>(
|
||||
universe_causes,
|
||||
type_tests,
|
||||
} = constraints;
|
||||
let placeholder_indices = Rc::new(placeholder_indices);
|
||||
|
||||
// If requested, emit legacy polonius facts.
|
||||
polonius::emit_facts(
|
||||
|
@ -395,7 +395,7 @@ impl<'tcx> RegionInferenceContext<'tcx> {
|
||||
pub(crate) fn new(
|
||||
infcx: &BorrowckInferCtxt<'tcx>,
|
||||
var_infos: VarInfos,
|
||||
placeholder_indices: Rc<PlaceholderIndices>,
|
||||
placeholder_indices: PlaceholderIndices,
|
||||
universal_region_relations: Frozen<UniversalRegionRelations<'tcx>>,
|
||||
mut outlives_constraints: OutlivesConstraintSet<'tcx>,
|
||||
member_constraints_in: MemberConstraintSet<'tcx, RegionVid>,
|
||||
|
@ -258,10 +258,9 @@ impl PlaceholderIndices {
|
||||
/// Here, the variable `'0` would contain the free region `'a`,
|
||||
/// because (since it is returned) it must live for at least `'a`. But
|
||||
/// it would also contain various points from within the function.
|
||||
#[derive(Clone)]
|
||||
pub(crate) struct RegionValues<N: Idx> {
|
||||
elements: Rc<DenseLocationMap>,
|
||||
placeholder_indices: Rc<PlaceholderIndices>,
|
||||
placeholder_indices: PlaceholderIndices,
|
||||
points: SparseIntervalMatrix<N, PointIndex>,
|
||||
free_regions: SparseBitMatrix<N, RegionVid>,
|
||||
|
||||
@ -277,7 +276,7 @@ impl<N: Idx> RegionValues<N> {
|
||||
pub(crate) fn new(
|
||||
elements: Rc<DenseLocationMap>,
|
||||
num_universal_regions: usize,
|
||||
placeholder_indices: Rc<PlaceholderIndices>,
|
||||
placeholder_indices: PlaceholderIndices,
|
||||
) -> Self {
|
||||
let num_points = elements.num_points();
|
||||
let num_placeholders = placeholder_indices.len();
|
||||
|
Loading…
Reference in New Issue
Block a user