Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
9abcfa5
Don't link with --export-dynamic on wasm32-wasi
sunfishcode Jan 21, 2021
77a9e3e
combine: stop eagerly evaluating consts
lcnr Jan 24, 2021
fe39653
Check that value is explicitly none
JulianKnodt Dec 27, 2020
d1727ed
Add lint for 2229 migrations
arora-aman Dec 28, 2020
2c651eb
Process mentioned upvars for analysis first pass after ExprUseVisitor
arora-aman Nov 21, 2020
36352d2
Migrations first pass
arora-aman Dec 15, 2020
d30a5bf
Tests for 2229 lint
arora-aman Dec 30, 2020
9ac023d
Mark the lint doc as compile_fail
arora-aman Jan 3, 2021
f106e18
PR fixup
arora-aman Jan 19, 2021
11abaa1
New migration
arora-aman Jan 26, 2021
b421cd5
Restrict precision of captures with `capture_disjoint_fields` set
arora-aman Dec 4, 2020
3488082
Compute mutability of closure captures
arora-aman Dec 2, 2020
1373f98
Test cases for handling mutable references
arora-aman Dec 13, 2020
0897db5
Test for restricting capture precision
arora-aman Dec 14, 2020
604cbdc
Fix unused 'mut' warning for capture's root variable
arora-aman Dec 16, 2020
c748f32
Fix incorrect use mut diagnostics
arora-aman Dec 13, 2020
ffd5327
Add fixme for precise path diagnostics
arora-aman Jan 12, 2021
fadf03e
Fix typos
arora-aman Jan 29, 2021
0f4bab2
Fixme for closure origin when reborrow is implemented
arora-aman Jan 29, 2021
5a3b85c
Remove changes to Cargo.lock
arora-aman Jan 30, 2021
9946b54
add suggestion for nested fields
b-naber Jan 28, 2021
6946534
Remove const_in_array_rep_expr
JulianKnodt Jan 26, 2021
6695690
Fix small typo
Seppel3210 Jan 31, 2021
8940a26
stabilize int_bits_const
KodrAus Jan 31, 2021
cd9a250
Rollup merge of #80092 - sexxi-goose:restrict_precision, r=nikomatsakis
jonas-schievink Jan 31, 2021
0155051
Rollup merge of #80404 - JulianKnodt:arr_ref, r=oli-obk
jonas-schievink Jan 31, 2021
61ab140
Rollup merge of #80629 - sexxi-goose:migrations_1, r=nikomatsakis
jonas-schievink Jan 31, 2021
666d2ad
Rollup merge of #81255 - sunfishcode:wasi-no-export-dynamic, r=alexcr…
jonas-schievink Jan 31, 2021
9fc2952
Rollup merge of #81351 - lcnr:big-money-big-prices, r=oli-obk
jonas-schievink Jan 31, 2021
6443825
Rollup merge of #81480 - b-naber:nested_fields_suggestion, r=estebank
jonas-schievink Jan 31, 2021
2b9fec7
Rollup merge of #81589 - Seppel3210:master, r=jonas-schievink
jonas-schievink Jan 31, 2021
bd990cc
Rollup merge of #81590 - KodrAus:stabilize/int_bits_const, r=m-ou-se
jonas-schievink Jan 31, 2021
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
Prev Previous commit
Next Next commit
Fix typos
  • Loading branch information
arora-aman committed Jan 29, 2021
commit fadf03ee1bbe238ff5a46e60550a70470da492af
2 changes: 2 additions & 0 deletions compiler/rustc_middle/src/ty/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -675,6 +675,8 @@ pub struct CapturedPlace<'tcx> {
}

impl CapturedPlace<'tcx> {
/// Returns the hir-id of the root variable for the captured place.
/// e.g., if `a.b.c` was captured, would return the hir-id for `a`.
pub fn get_root_variable(&self) -> hir::HirId {
match self.place.base {
HirPlaceBase::Upvar(upvar_id) => upvar_id.var_path.hir_id,
Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_mir/src/borrow_check/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1358,10 +1358,10 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {

fn propagate_closure_used_mut_upvar(&mut self, operand: &Operand<'tcx>) {
let propagate_closure_used_mut_place = |this: &mut Self, place: Place<'tcx>| {
// We have three possiblities here:
// We have three possibilities here:
// a. We are modifying something through a mut-ref
// b. We are modifying something that is local to our parent
// c. Current body is a nested clsoure, and we are modifying path starting from
// c. Current body is a nested closure, and we are modifying path starting from
// a Place captured by our parent closure.

// Handle (c), the path being modified is exactly the path captured by our parent
Expand Down