Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 Forward declaration of classes

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
eco Posted - Apr 18 2006 : 03:56:07 AM
if I write this:

//------------------------------------
// somewhere in a .h file

class classB; // this is a legal forward declaration

// my class
class classA
{
public:
classB* pcls;
};

//------------------------------------
// somewhere else in another .h file
class classB
{
// class implementation
};




//------------------------------------
//
void main( )
{
classA a;
classB b; // ***** see below
}


***** if I click on GoTo classB,
then I VA send me to the forward declaration and not on the class implementation. this is not the case of a friend declaration, but I won't declare all my classes as friend for VA.


5   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Apr 24 2006 : 6:35:47 PM
i am seeing the same thing, using VS2003 and VA 1445, simply placing all of the code into a single file.

the good news is that this seems to be fixed (i cannot reproduce this) in the 15xx builds of VA. these are currently working their way towards a beta release.

hopefully these versions will fix this for you as well.
eco Posted - Apr 20 2006 : 03:10:44 AM
Hi,
If i paste this code in a new empty project with only one .cpp file, it does the same.
(you can forget the 2 comment lines at the top, even in one file this is reproductible)
I can reproduce this on all the 6 machines that get Va X .

the exact description is that if i click on the keyword classB in the main function and i click on GoTo VA send me on line 4 (class classB; // this is a legal forward declaration)

Our project is nearly 1.000.000 lines of code and for us it's a big problem.

I can reproduce this with 1444 & 1445 versions.
jpizzi Posted - Apr 19 2006 : 10:51:58 PM
Copying and pasting your example code into a new project in VS 2003 with VA 1444, I do not see the behavior you are describing. Does it do this for you in a new project with the sample code you have?

Interestingly, I do not even have to include the .h file in main.cpp for it to work (although, of course, it won't compile that way).

Are the mentioned header files in your project?
eco Posted - Apr 19 2006 : 02:43:36 AM
Sorry,
I'm using build 1445 under vc2003 but the problem exist since a long time

VA_X.dll file version 10.2.1445.0 built 2006.04.12
Licensed to:
VA X: xxxxx
VA.NET 7.1:
VA 4.1:
VAOpsWin.dll version 1.3.2.4
VATE.dll version 1.0.4.15
DevEnv.exe version 7.10.3077.0
msenv.dll version 7.10.3077.0
Font: Courier New 13(Pixels)
Comctl32.dll version 5.82.2900.2180
WindowsNT 5.1 Build 2600 Service Pack 2
2 processors

Platform: Custom
Stable Includes:
c:\\program files\\microsoft visual studio .net 2003\\vc7\\include;
c:\\program files\\microsoft visual studio .net 2003\\vc7\\PlatformSDK\\include\\prerelease;
c:\\program files\\microsoft visual studio .net 2003\\vc7\\PlatformSDK\\include;
c:\\program files\\microsoft visual studio .net 2003\\sdk\\v1.1\\include;

Library Includes:

Other Includes:

rhummer Posted - Apr 18 2006 : 11:19:31 AM
What version of VA X are you using and what IDE?

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