Skip to content

Struct literal completion should also suggest Self { ... } when in an impl #12106

Closed
@jonas-schievink

Description

@jonas-schievink

This suggests Strukt {...}:

struct Strukt {
    a: u8,
}

impl Strukt {
    fn new() -> Strukt {
        Strukt$0
    }
}

This does not suggest Self {...}:

struct Strukt {
    a: u8,
}

impl Strukt {
    fn new() -> Strukt {
        Self$0
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-completionautocompletionC-featureCategory: feature requestS-actionableSomeone could pick this issue up and work on it right now

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions