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 recognise constructor with #pragma

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
yym Posted - Jan 17 2010 : 07:16:10 AM
Given the following code:

MyClass::MyClass()
#pragma warning(suppress:4355)
: m_member(this)
#pragma warning(suppress:4355)
, m_member2(this)
{
}

Visual Assist doesn't recognise this as being a constructor.
If the first pragma is removed it's OK.
3   L A T E S T    R E P L I E S    (Newest First)
accord Posted - Jan 18 2010 : 12:57:08 PM
I am seeing the same effects here. Thank you for the clear description.

case=11545
yym Posted - Jan 18 2010 : 06:39:59 AM
I didn't check Alt+G. m_member and m_member2 are underlined, and in the constructor the class members aren't suggested. Also the constructor doesn't appear in VA Outline.
accord Posted - Jan 18 2010 : 03:45:58 AM
What are you exactly seeing? For me, the constructor was recognized using VS2008 and VA 1738, but m_member and m_member2 was underlined. Is that what you are seeing?

I expanded your example with class declaration for the test:

class MyTest
{
    MyTest* m_member;
    MyTest* m_member2;
    MyTest();
}


When I placed the caret over the constructor in your code and pressed alt+G it took me to the constructor in my class declaration.

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