Skip to content

Use ";" instead of "{}" for empty constructor bodies #57150

Closed
@pq

Description

@pq

Migrated from dartbug.com/22004:

Instead of:

class Point {
  int x, y;
  Point(this.x, this.y) {}
}

prefer:

class Point {
  int x, y;
  Point(this.x, this.y);
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    devexp-linterIssues with the analyzer's support for the linter packagelegacy-area-analyzerUse area-devexp instead.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