Skip to content

Should prefer_final_parameters fire on a super-parameter? #58645

@srawlins

Description

@srawlins

The prefer_final_parameters rule has tests indicating that it should report constructor parameters:

class C {
  C.badValue(String value): this.value = value; // LINT
}

but not for field formal parameters:

class C {
  C.goodValue(this.value); // OK
}

So, what about super-parameters? Whether it should or shouldn't, there should be a test.

Metadata

Metadata

Assignees

No one assigned

    Labels

    devexp-linterIssues with the analyzer's support for the linter packagelegacy-area-analyzerUse area-devexp instead.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions