Skip to content

Quick fixes for multiple required arguments could be more useful #49775

@matanlurey

Description

@matanlurey
void example() {
  // https://dart.dev/tools/diagnostic-messages#missing_required_argument
  Listener();
}

class Listener {
  final void Function() onA;
  final void Function(String) onB;
  final void Function(String, String) onC;

  Listener({
    required this.onA,
    required this.onB,
    required this.onC,
  });
}

... produces the following quick-fixes:

I would have assumed Add all required arguments was an available quick fix, but it was not.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3A lower priority bug or feature requestarea-devexpFor issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages.devexp-quick-fixIssues with analysis server (quick) fixestype-enhancementA request for a change that isn't a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions