-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-NLLArea: Non-lexical lifetimes (NLL)Area: Non-lexical lifetimes (NLL)E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.NLL-soundWorking towards the "invalid code does not compile" goalWorking towards the "invalid code does not compile" goal
Milestone
Description
For example, this code is accepted with NLL enabled:
rust/src/test/ui/regions/regions-free-region-ordering-caller.rs
Lines 19 to 30 in f1694ea
fn call2<'a, 'b>(a: &'a usize, b: &'b usize) { | |
let z: Option<&'b &'a usize> = None;//~ ERROR E0623 | |
} | |
fn call3<'a, 'b>(a: &'a usize, b: &'b usize) { | |
let y: Paramd<'a> = Paramd { x: a }; | |
let z: Option<&'b Paramd<'a>> = None;//~ ERROR E0623 | |
} | |
fn call4<'a, 'b>(a: &'a usize, b: &'b usize) { | |
let z: Option<&'a &'b usize> = None;//~ ERROR E0623 | |
} |
cc #47184
Metadata
Metadata
Assignees
Labels
A-NLLArea: Non-lexical lifetimes (NLL)Area: Non-lexical lifetimes (NLL)E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.NLL-soundWorking towards the "invalid code does not compile" goalWorking towards the "invalid code does not compile" goal