Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 Find References bug

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
HarryStorbacka Posted - Feb 28 2012 : 07:06:56 AM
There seems to be a problem with "Find References" when using a #define and std::tr1::shared_ptr.


#include <memory>

#define MySharedPtr std::tr1::shared_ptr

class Foo_Impl
{
public:
	Foo_Impl() : value(1) {}
	int value;
};

class Foo
{
public:
	Foo() {}
	// std::tr1::shared_ptr<Foo_Impl> impl;
	MySharedPtr<Foo_Impl> impl;

	void set_value(int v)
	{
		impl->value = v;
	}
};

int _tmain(int argc, _TCHAR* argv[])
{
	Foo foo;
	foo.set_value(2);
	return 0;
}


Doing a "Find References" on "value" in "impl->value" results in a unrecognized symbol message popping up. When just using std::tr1::shared_ptr it works fine.

Visual Studio 2008 SP1 and VA 10.6. 1862.0
3   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Feb 28 2012 : 5:41:24 PM
Thank you for the update, I am glad this helped and fixed this for you.
HarryStorbacka Posted - Feb 28 2012 : 5:16:13 PM
Adding the #define to VA's StdAfx.h per instructions in the link above fixed it. Thanks!
feline Posted - Feb 28 2012 : 4:18:16 PM
Thank you for the very clear example. Can you try turning on deep macro parsing, as explained in this FAQ entry please:

http://docs.wholetomato.com?W363

this fixes the problem with your sample code for me, so hopefully this will help in your main solution.

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