Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 VA doesn't recognize the typedefs correctly

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
damrit Posted - Aug 07 2006 : 3:51:04 PM
VA doesn't recognize the following correctly:
struct
{
int i;
} MyFirstStruct;

typedef struct : public MyFirstStruct
{
int j;
} MySecondStruct;

The all occurances of MySecondStuct have the red underline and it is not colored (indicating that it is not recognized). However, the following make it work:

typedef struct MySecondStruct : public MyFirstStruct
{
int j;
} MySecondStruct;
1   L A T E S T    R E P L I E S    (Newest First)
jpizzi Posted - Aug 08 2006 : 12:20:27 AM
I would suggest not mixing C and C++ syntax. You are bound to get very confused.

C++ syntax for what you are trying is:


struct MyFirstStruct
{
    int i;
};

struct MySecondStruct : public MyFirstStruct
{
    int j;
};

I suspect that VA will have no problem with this syntax. I would be surprised that mixing the syntaxes as you have in your example works, but then again we are talking about the liberal Microsoft compiler, here.

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