-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
Compiler gets lifetime scope wrong #28970
Copy link
Copy link
Closed
Labels
A-borrow-checkerArea: The borrow checkerArea: The borrow checkerA-lifetimesArea: Lifetimes / regionsArea: Lifetimes / regionsC-bugCategory: This is a bug.Category: This is a bug.fixed-by-NLLBugs fixed, but only when NLL is enabled.Bugs fixed, but only when NLL is enabled.
Metadata
Metadata
Assignees
Labels
A-borrow-checkerArea: The borrow checkerArea: The borrow checkerA-lifetimesArea: Lifetimes / regionsArea: Lifetimes / regionsC-bugCategory: This is a bug.Category: This is a bug.fixed-by-NLLBugs fixed, but only when NLL is enabled.Bugs fixed, but only when NLL is enabled.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Please check the code bellow
https://play.rust-lang.org/?gist=c0dd3d93bde346c4bd4d&version=nightly
I suppose all of them should compile as they do the same thing, but only the last one does.