Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 New Refactorings: Inline Method and variable

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
MikMik Posted - Dec 01 2017 : 07:57:49 AM
Could we have the "Inline Method" refactoring, please?
https://refactoring.com/catalog/inlineMethod.html

It can be very useful, also as part of larger refactorings, like removing "primitive obsession" (see http://dev.solita.fi/2013/03/01/refactoring-primitive-obsession.html for some an example).

Also, "inline variable" or "inline constant" could be useful:

const double triple = val*3;

double x = doSomething(triple);

// Turns into
double x = doSomething(val*3);

Basically, they would be the opposite of Extract Method and Introduce Variable.
5   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Sep 17 2021 : 10:54:06 AM
They are both still on the list, and haven't been forgotten. Unfortunately they aren't feature requests that many of our users seem that interested in, which isn't helping to prioritise them. We have a lot of outstanding feature requests, plus new versions of Visual Studio to support, and somehow need to prioritise which things to do first, and user interest is part of that calculation.
MikMik Posted - Sep 16 2021 : 11:55:34 AM
quote:
Originally posted by feline

Unfortunately I don't currently have an estimate for when we will try adding these refactoring commands, but they are on our list of features to add.



Are these refactorings still in the To-do list? It's been a long time...
feline Posted - Dec 04 2017 : 05:53:39 AM
Unfortunately I don't currently have an estimate for when we will try adding these refactoring commands, but they are on our list of features to add.
MikMik Posted - Dec 01 2017 : 08:37:28 AM
quote:
Originally posted by feline

We are looking to add an inline refactoring command at some point:

case=1493

We are also looking to add a refactoring command to inline a local variable or constant:

case=31485



Thanks! I'm looking forward to having them available!

quote:

For now, Find References can help you with this, since you can quickly and easily see all of the references you want to update / replace.



Yes, I know some workarounds, but some tooling help would be great!
feline Posted - Dec 01 2017 : 08:16:02 AM
We are looking to add an inline refactoring command at some point:

case=1493

We are also looking to add a refactoring command to inline a local variable or constant:

case=31485

For now, Find References can help you with this, since you can quickly and easily see all of the references you want to update / replace.

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000