Skip to content

Create missing overrides uses wrong tab ident when : super constructor is on new line #60636

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
FMorschel opened this issue Apr 29, 2025 · 1 comment
Labels
area-devexp For issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages. devexp-assist Issues with analysis server assists P4

Comments

@FMorschel
Copy link
Contributor

Repro:

abstract class A {
  A({int? myParameterName});

  int get myGetter;
}

class MyClassWithReallyReallyGiganticNameAndNoParametersButSuperHasSome
    extends A {
  MyClassWithReallyReallyGiganticNameAndNoParametersButSuperHasSome()
    : super(myParameterName: 0);
}

Creates:

abstract class A {
  A({int? myParameterName});

  int get myGetter;
}

class MyClassWithReallyReallyGiganticNameAndNoParametersButSuperHasSome
    extends A {
  MyClassWithReallyReallyGiganticNameAndNoParametersButSuperHasSome()
    : super(myParameterName: 0);
    
      @override
      // TODO: implement myGetter
      int get myGetter => throw UnimplementedError();
}
@FMorschel FMorschel added the area-devexp For issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages. label Apr 29, 2025
@bwilkerson
Copy link
Member

Definitely not great, but our tools only aspire to do a best-effort at producing well formatted code and depend on the formatter to do the actual formatting. We've talked about having a way for users to request formatting, but that's an effort that we don't have the resources for at the moment.

@bwilkerson bwilkerson added P4 devexp-assist Issues with analysis server assists labels Apr 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-devexp For issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages. devexp-assist Issues with analysis server assists P4
Projects
None yet
Development

No branches or pull requests

2 participants