Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 Renaming Class - Copy Constructor

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
inline Posted - Jul 09 2007 : 06:31:05 AM
Hi there,

I am using VS2005 and VAX Build 1557.

If I am renaming a class I get this little bug:


class MyClass
{
public:
	MyClass();
	~MyClass();
	
private:
   MyClass& operator=(const MyClass&);
};


I am renaming "MyClass" in "YourClass" and get the following:


class YourClass
{
public:
	YourClass();
	~YourClass();
	
private:
   YourClass& operator=(const MyClass&);
};


Everything is renamed correctly but the parameter of my copy constructor.


Keep up the good work.
4   L A T E S T    R E P L I E S    (Newest First)
sl@sh Posted - Jul 13 2007 : 03:08:01 AM
*sigh* I'd wish my UML tool already took the possibility of 'copy protection constructors' into consideration. As it is, it inserts a dummy parameter name even if I don't supply one in the UML model

But then again, this leads to VAX handling those constructors correctly
feline Posted - Jul 12 2007 : 06:58:01 AM
That's fair This is a known bug, and is on our list of bugs to fix. case=3027 is the number of this particular bug, something that I don't always explain since most of the forum regulars are familiar with this, and used to it.
inline Posted - Jul 12 2007 : 04:06:17 AM
Ah yes, you are right. It works if I have a parameter name.

But because I want to declare the copy constructor as private to prevent copies it would not need a name :)
feline Posted - Jul 09 2007 : 08:56:52 AM
This happens because there is no parameter name. Change the copy constructor to be:

   YourClass& operator=(const MyClass& rhs);


and VA will correctly find and rename all instances of the class name.

case=3027

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