Skip to content

Suboptimal Extract Local Variable behavior #22038

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
Tracked by #55825
bwilkerson opened this issue Jan 9, 2015 · 1 comment
Open
Tracked by #55825

Suboptimal Extract Local Variable behavior #22038

bwilkerson opened this issue Jan 9, 2015 · 1 comment
Labels
area-devexp For issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages. devexp-refactoring Issues with analysis server refactorings P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug

Comments

@bwilkerson
Copy link
Member

Add the following code to a Dart file:

String silly(String s) {
  return 'The string is ${s.length} characters long';
}

Then select 's.length' and select the 'Extract Local Variable' operation. The string will contain '${length}', but it would be better if it could be '$length'.

@kevmoo kevmoo added P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug and removed triaged labels Mar 1, 2016
@srawlins srawlins added the devexp-refactoring Issues with analysis server refactorings label Jun 17, 2020
@asashour
Copy link
Contributor

asashour commented Sep 8, 2021

@bwilkerson bwilkerson added area-devexp For issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages. and removed legacy-area-analyzer Use area-devexp instead. labels Feb 21, 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-refactoring Issues with analysis server refactorings P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

4 participants