Skip to content

Pattern completions without : could also add it #62077

@FMorschel

Description

@FMorschel

Pattern completions without : could also add : TypeName , so we can simply write down the new variable name. Currently, it simply ends the current word but does nothing. Since we already know the user will need the type or the var/final` keyword, we can handle that to make this easier.

Repro:

void f(C c) {
  if (c case C(gett))
}

abstract class C {
  int get getter;
}
Image

CC @bwilkerson @DanTup @srawlins

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-devexpFor issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions