Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Feature Requests
 Fix includes
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

imp_galo
New Member

3 Posts

Posted - Dec 20 2007 :  07:34:19 AM  Show Profile  Reply with Quote
One feature that I really enjoy in java IDEs is Fix Imports. This means that if there is some import missing the IDE will find and include the respective import to the source code.

I would really like if VAX could do the same regarding c++ includes.

feline
Whole Tomato Software

United Kingdom
19021 Posts

Posted - Dec 20 2007 :  11:21:48 AM  Show Profile  Reply with Quote
I am not sure what you are asking for here. Do you mean suggesting the correct #include line to add to a file, or are you talking about something else?

zen is the art of being at one with the two'ness
Go to Top of Page

imp_galo
New Member

3 Posts

Posted - Dec 20 2007 :  12:39:29 PM  Show Profile  Reply with Quote
I mean a command fix imports that add the missing includes. Eg.

void Funcion( DWORD a )
{
}

won't compile because DWORD requires Windows.h, so if I execute the fix includes command it will add #include <Windows.h>.

Intellij also removes unecessary includes.

If you check netbeans or intellij you can understand better how this kind of feature works.

Thanks.
Go to Top of Page

sl@sh
Tomato Guru

Switzerland
204 Posts

Posted - Dec 21 2007 :  07:46:10 AM  Show Profile  Reply with Quote
Hmmm, why do you think DWORD resides in Windows.h? Or rather, why do you think VA will suggest it for you? When I type it in my editor, put the cursor on the word and then type Alt+G to invoke VA's goto declaration functionality, it suggest 3 include file locations for me, none of which happens to be Windows.h! However, I am quite sure, that including any of those three suggested include files won't be a good idea at all, simply because they are meant to be included in the right context (i. e. within central include files such as windows.h or afx.h)

VA may be able to find the actual location of one or more declarations of a specific symbol, but it might not come up with the right one. Especially when header files come with inherent dependencies...

I don't know about netbeans or intellij, but I understand both are Java, and the Java package structure is way more organized than windows system headers!

Edited by - sl@sh on Dec 21 2007 07:48:39 AM
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19021 Posts

Posted - Dec 21 2007 :  2:43:51 PM  Show Profile  Reply with Quote
We are looking into doing this:

case=226

but as sl@sh says, it is not always obvious what header file should be included.

zen is the art of being at one with the two'ness
Go to Top of Page

support
Whole Tomato Software

5566 Posts

Posted - Jan 27 2009 :  10:26:44 PM  Show Profile  Reply with Quote
case=226 is implemented in build 1715
Hover over an unrecognized symbol and choose "Add include xxxx" from the refactoring context menu.


Whole Tomato Software, Inc.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000