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
 Technical Support
 Parsing functions when using #ifdef in the header
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Darakim
Junior Member

14 Posts

Posted - Apr 29 2005 :  2:57:31 PM  Show Profile
Is there anyway to have VisualAssist correctly parse functions defined like this example:

#ifdef ANSI
PUBLIC int siActDat
(
int cirId, /* circuit Id */
int *siCon, /* circuit connection */
int event /* event */
)
#else
PUBLIC int siActDat(cirId, siCon, event)
int cirId; /* circuit Id */
int *siCon; /* circuit connection */
int event; /* event */
#endif
{
...
}


Here is my version info:
-------------------------------------------------
VA_X.dll file version 10.1.1298.0
Licensed to:
VA X: [email protected] (2-user license) Support ends 2006.01.11
VAOpsWin.dll version 1.2.0.4
MSDev.exe version 6.0.9782.1
Devshl.dll version 6.0.9782.0
Devedit.pkg version 6.0.9782.0
Font: Lucida Console 13(Pixels)
Comctl32.dll version 5.82.2800.1106
WindowsNT 5.1 Build 2600 Service Pack 1
2 processors
-------------------------------------------------

jpizzi
Tomato Guru

USA
642 Posts

Posted - Apr 29 2005 :  11:35:43 PM  Show Profile
Dealing with #defines slows down the parser too much from what they have said in the past.

As for the K&R style, even without the #ifdef, it is not parsed corrrectly. I have asked WT about supporting this in the past, and they said that it is such an archaic style that they don't see ever getting around to supporting it.

Joe Pizzi
Go to Top of Page

Stephen
Tomato Guru

United Kingdom
781 Posts

Posted - May 03 2005 :  05:06:52 AM  Show Profile
Re the #ifdef's: It's not that it slows the parser down. It's that both are valid pieces of code which you want to edit. Moreover, VAX has no way of knowing which half of the #ifdef is on at any time. Do you really want it to reparse your whole project every time you change from Debug to Release build?

Stephen Turner
ClickTracks http://www.clicktracks.com/
Winner: ClickZ's Best Web Analytics Tool 2003 & 2004
Go to Top of Page

Darakim
Junior Member

14 Posts

Posted - May 03 2005 :  08:32:29 AM  Show Profile
Actually, I would love having VAX reparse my project when I change from debug to release. It would be so easier to have VAX jump to the right function (in case there are different definitions of function that depands on a #define). Doing this parsing would at the same time allow code that is not activated to be easily grey out by VAX.

I agree that this should not be done dynamically every time we write a new #define in a source file, but it could be done at project loading or when project settings are modified.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000