Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 6 pull requests #69759

Closed
wants to merge 32 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
7859f0e
Make PlaceRef lifetimes of Place::as_ref be both 'tcx
spastorino Mar 3, 2020
812e62f
Make PlaceRef lifetimes of LocalAnalyzer::process_place be both 'tcx
spastorino Mar 3, 2020
d3e5177
Use .next() instead of .nth(0) on iterators.
matthiaskrgr Mar 3, 2020
98c7ed6
DefKind::Method -> DefKind::AssocFn
mark-i-m Mar 3, 2020
3aeb9f0
rename TraitItemKind::Method -> Fn
mark-i-m Mar 3, 2020
e82ec23
Use correct place for `enum_place`
ecstatic-morse Mar 3, 2020
1a1dcfa
Make PlaceRef lifetimes of codegen_place be both 'tcx
spastorino Mar 3, 2020
2af5e87
Make PlaceRef lifetimes of monomorphized_place_ty be both 'tcx
spastorino Mar 3, 2020
a20d54f
Make PlaceRef lifetimes of RootPlace be both 'tcx
spastorino Mar 3, 2020
842af36
Make PlaceRef lifetimes of borrow_conflict_place be both 'tcx
spastorino Mar 4, 2020
f54e863
Make PlaceRef lifetimes of move_error_reported be both 'tcx
spastorino Mar 4, 2020
6200f5c
Make PlaceRef lifetimes of uninitialized_error_reported be both 'tcx
spastorino Mar 4, 2020
e32ee55
Make PlaceRef lifetimes of move_path_closest_to be both 'tcx
spastorino Mar 4, 2020
634a167
Make PlaceRef lifetimes of move_path_for_place be both 'tcx
spastorino Mar 4, 2020
53be0cc
Use subslice patterns in slice methods
cuviper Mar 4, 2020
c6f1244
Make PlaceRef lifetimes of is_upvar_field_projection be both 'tcx
spastorino Mar 4, 2020
6f23650
Make PlaceRef lifetimes of add_moved_or_invoked_closure_note be both …
spastorino Mar 4, 2020
eb67eca
Make PlaceRef lifetimes of describe_field be both 'tcx
spastorino Mar 4, 2020
a30f55f
Make PlaceRef lifetimes of borrowed_content_source be both 'tcx
spastorino Mar 4, 2020
bd4dad4
Make PlaceRef lifetimes of move_spans be both 'tcx
spastorino Mar 4, 2020
46d85e5
Make PlaceRef lifetimes of closure_span be both 'tcx
spastorino Mar 4, 2020
a32afa3
Make PlaceRef lifetimes of classify_drop_access_kind be both 'tcx
spastorino Mar 4, 2020
a5d1e18
Make PlaceRef lifetimes of is_prefix_of be both 'tcx
spastorino Mar 4, 2020
2cb2559
Make PlaceRef lifetimes of in_projection be both 'tcx
spastorino Mar 4, 2020
b11cd0b
PlaceRef<'a, 'tcx> -> PlaceRef<'tcx>
spastorino Mar 4, 2020
8efb9eb
Avoid using `unwrap()` in suggestions
JohnTitor Mar 5, 2020
f64c639
Rollup merge of #69656 - matthiaskrgr:iter_nth_zero, r=oli-obk
Centril Mar 6, 2020
19272a0
Rollup merge of #69674 - mark-i-m:assoc-fn, r=Centril
Centril Mar 6, 2020
9fd88a9
Rollup merge of #69676 - ecstatic-morse:fix-enum-discr-effect, r=oli-obk
Centril Mar 6, 2020
cc35ba6
Rollup merge of #69706 - cuviper:subslice-methods, r=Centril
Centril Mar 6, 2020
b059d02
Rollup merge of #69714 - spastorino:place-ref-lifetime, r=oli-obk
Centril Mar 6, 2020
7f53c32
Rollup merge of #69727 - JohnTitor:sugg-unwrap, r=estebank
Centril Mar 6, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/librustc_mir/dataflow/move_paths/builder.rs
Original file line number Diff line number Diff line change
@@ -483,7 +483,7 @@ impl<'b, 'a, 'tcx> Gatherer<'b, 'a, 'tcx> {
self.builder.data.loc_map[self.loc].push(move_out);
}

fn gather_init(&mut self, place: PlaceRef<'cx, 'tcx>, kind: InitKind) {
fn gather_init(&mut self, place: PlaceRef<'tcx, 'tcx>, kind: InitKind) {
debug!("gather_init({:?}, {:?})", self.loc, place);

let mut place = place;
6 changes: 3 additions & 3 deletions src/librustc_mir/transform/check_consts/qualifs.rs
Original file line number Diff line number Diff line change
@@ -35,7 +35,7 @@ pub trait Qualif {
fn in_projection_structurally(
cx: &ConstCx<'_, 'tcx>,
per_local: &mut impl FnMut(Local) -> bool,
place: PlaceRef<'_, 'tcx>,
place: PlaceRef<'tcx, 'tcx>,
) -> bool {
if let [proj_base @ .., elem] = place.projection {
let base_qualif = Self::in_place(
@@ -67,15 +67,15 @@ pub trait Qualif {
fn in_projection(
cx: &ConstCx<'_, 'tcx>,
per_local: &mut impl FnMut(Local) -> bool,
place: PlaceRef<'_, 'tcx>,
place: PlaceRef<'tcx, 'tcx>,
) -> bool {
Self::in_projection_structurally(cx, per_local, place)
}

fn in_place(
cx: &ConstCx<'_, 'tcx>,
per_local: &mut impl FnMut(Local) -> bool,
place: PlaceRef<'_, 'tcx>,
place: PlaceRef<'tcx, 'tcx>,
) -> bool {
match place {
PlaceRef { local, projection: [] } => per_local(local),