Skip to content

Assist: Extract struct from function signature #20331

@mendelsshop

Description

@mendelsshop

When you select the signature of a function, you should have the ability to extract all or part of the function's parameters to a struct.

fn foo(bar: u32, baz: u32) { ... }

->

struct FooStruct {
     bar: u32,
     baz: u32,
}

fn foo(FooStruct) { ... }

This is something I would like to work on. Is the something that the rust-analyzer team would be interested in?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions