Skip to content

NLL doesn't respect user types in closure signatures #54692

Closed
@matthewjasper

Description

@matthewjasper

For example, the following code compiles

#![feature(nll)]
fn foo<'a>() {
    |x: &'a i32| -> &'static i32 {
        return &x;
    };
}

cc #47184

Metadata

Metadata

Assignees

Labels

A-NLLArea: Non-lexical lifetimes (NLL)E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.NLL-soundWorking towards the "invalid code does not compile" goal

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions