Auto merge of #53314 - nikomatsakis:nll-invert-liveness, r=pnkfelix
NLL: experiment with inverting liveness I got inspired to see what would happen here. Fixes #52460 r? @pnkfelix
This commit is contained in:
commit
83ddc33347
21 changed files with 999 additions and 606 deletions
|
|
@ -34,15 +34,15 @@ fn main() {
|
|||
// | '_#4r | Local | ['_#4r]
|
||||
// |
|
||||
// | Inferred Region Values
|
||||
// | '_#0r | U0 | {bb0[0..=127], '_#0r}
|
||||
// | '_#1r | U0 | {bb0[0..=127], '_#1r}
|
||||
// | '_#2r | U0 | {bb0[0..=127], '_#2r}
|
||||
// | '_#3r | U0 | {bb0[0..=127], '_#3r}
|
||||
// | '_#4r | U0 | {bb0[0..=127], '_#4r}
|
||||
// | '_#5r | U0 | {bb0[0..=127], '_#1r}
|
||||
// | '_#6r | U0 | {bb0[0..=127], '_#2r}
|
||||
// | '_#7r | U0 | {bb0[0..=127], '_#1r}
|
||||
// | '_#8r | U0 | {bb0[0..=127], '_#3r}
|
||||
// | '_#0r | U0 | {bb0[0..=1], '_#0r}
|
||||
// | '_#1r | U0 | {bb0[0..=1], '_#1r}
|
||||
// | '_#2r | U0 | {bb0[0..=1], '_#2r}
|
||||
// | '_#3r | U0 | {bb0[0..=1], '_#3r}
|
||||
// | '_#4r | U0 | {bb0[0..=1], '_#4r}
|
||||
// | '_#5r | U0 | {bb0[0..=1], '_#1r}
|
||||
// | '_#6r | U0 | {bb0[0..=1], '_#2r}
|
||||
// | '_#7r | U0 | {bb0[0..=1], '_#1r}
|
||||
// | '_#8r | U0 | {bb0[0..=1], '_#3r}
|
||||
// |
|
||||
// ...
|
||||
// fn use_x(_1: &'_#5r mut i32, _2: &'_#6r u32, _3: &'_#7r u32, _4: &'_#8r u32) -> bool {
|
||||
|
|
|
|||
|
|
@ -8,10 +8,8 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
//compile-flags: -Z emit-end-regions -Zborrowck=mir
|
||||
|
||||
|
||||
#![allow(warnings)]
|
||||
#![feature(nll)]
|
||||
|
||||
struct Wrap<'p> { p: &'p mut i32 }
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
error[E0506]: cannot assign to `x` because it is borrowed
|
||||
--> $DIR/maybe-initialized-drop-implicit-fragment-drop.rs:32:5
|
||||
--> $DIR/maybe-initialized-drop-implicit-fragment-drop.rs:30:5
|
||||
|
|
||||
LL | let wrap = Wrap { p: &mut x };
|
||||
| ------ borrow of `x` occurs here
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue