Skip to content
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

cascade_invocations #59807

Closed
amrgetment opened this issue Dec 26, 2024 · 4 comments
Closed

cascade_invocations #59807

amrgetment opened this issue Dec 26, 2024 · 4 comments
Labels
analyzer-linter Issues with the analyzer's support for the linter package area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. type-question A question about expected behavior or functionality

Comments

@amrgetment
Copy link

I wonder if you can add fix all cascades in the file not one by one fix
image

  • The Dart version and tooling diagnostic info (dart info)
#### General info

- Dart 3.5.4 (stable) (Wed Oct 16 16:18:51 2024 +0000) on "macos_x64"
- on macos / Version 15.0.1 (Build 24A348)
- locale is en-EG

#### Process info

|  Memory |  CPU | Elapsed time | Command line                                                                     |
| ------: | ---: | -----------: | -------------------------------------------------------------------------------- |
|   62 MB | 0.0% |        28:07 | dart devtools --machine --allow-embedding --dtd-uri ws:<path>/uuKV8DUxYL3eCfsu   |
| 1285 MB | 0.0% |        28:07 | dart language-server --protocol=lsp --client-id=VS-Code --client-version=3.102.0 |
|   76 MB | 0.0% |        28:08 | dart tooling-daemon --machine                                                    |
|   91 MB | 0.0% |        28:08 | flutter_tools.snapshot daemon                                                    |
  • Whether you are using Windows, macOS, or Linux (if applicable)
    macOS
@dart-github-bot
Copy link
Collaborator

Summary: User requests a "fix all cascades" feature in Dart's IDE to refactor multiple cascade invocations simultaneously, instead of fixing them one by one. This would improve code refactoring efficiency.

@dart-github-bot dart-github-bot added area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. type-question A question about expected behavior or functionality labels Dec 26, 2024
@srawlins srawlins added the analyzer-linter Issues with the analyzer's support for the linter package label Dec 27, 2024
@FMorschel
Copy link
Contributor

Do you mean something like #52476? If so, that has been added and will be available after 3.7

@FMorschel
Copy link
Contributor

FMorschel commented Dec 29, 2024

It was mentioned there at #52476 but as a note:

Since we still have #58662 (false positive/negatives) and possibly similar issues open, we decided not to add a "Fix all in file" option as it may result in possibly wrong code. What we added instead was an option to fix multiple lint triggers that are together and are related. So it will help a bit more but not fix all in the file. For that (I think this screenshot you took is from VS Code) you can open the problems tab and fix with right click there (also see microsoft/vscode#236364).

@amrgetment
Copy link
Author

thanks a lot, I will wait next release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
analyzer-linter Issues with the analyzer's support for the linter package area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. triage-automation See https://github.com/dart-lang/ecosystem/tree/main/pkgs/sdk_triage_bot. type-question A question about expected behavior or functionality
Projects
None yet
Development

No branches or pull requests

4 participants