Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 Expand/Extract Preprocessor Macro(s)

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
jay.carlton Posted - Feb 20 2014 : 09:47:02 AM
Hi,

Occasionally I'll come across a preprocessor macros or symbol that I'd rather not use anymore, and it would be nice to have a refactoring option to replace either individual occurrences or all occurrences of it with the expanded source code. Presumably VA is doing the heavy lifting to parse these macros already, and this capability might also be a good troubleshooting aid if anyone runs into problems with particular macros.

A related operation would be "Extract Preprocessor Macro/Constant" that could work like Extract Method or Extract Literal, except you'd probably eventually want support for the # and ## notions.
In almost every case I'd tend to use C++ constants and typedefs rather than #defines, but for completeness I suppose there cases where one might want this (C code, for example).

Thanks,
Jay
1   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Feb 25 2014 : 11:38:57 PM
An interesting idea, we are considering adding a command to expand / inline a macro:

case=5160

As you say, there are some edge cases that we need to watch out for. Simple macros are safer than some of the more complex ones.

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