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

Inline temporary variable should be available on usages of variable, not just declaration #34142

jinujoseph opened this Issue Mar 15, 2019 · 2 comments


5 participants
Copy link

jinujoseph commented Mar 15, 2019

Reported by @drewnoakes
Affected Branch:
Affected Build: 16.0.0 Preview 4.1 SVC1
Affected Product Language:

Steps to reproduce:

Given code

var s = "";

The "Inline temporary variable" refactoring should be available on all usages of the s symbol (i.e. on both the declaration and the usage).


This comment has been minimized.

Copy link

CyrusNajmabadi commented Mar 17, 2019

This would def need a design review. Thsi could easily make the feature too noisy, and we've already heard from people (including team members that they're finding code-actions noisy enough).


This comment has been minimized.

Copy link

drewnoakes commented Mar 18, 2019

A benefit of having it on the usage is the (future) ability to inline only a single usage. This is something ReSharper offers and can be quite useful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.