Skip to content

Allow usage of constructor field parameters in constructor initializer list #26210

@BlackHC

Description

@BlackHC
class A {
 final x;
 final y;

 A(this.x) : y = x;
}

does not work (with "Only static members can be accessed in initializers"). It should...

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-languageDart language related items (some items might be better tracked at github.com/dart-lang/language).type-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