Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Technical Support
 1626 rename oddity
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Uniwares
Tomato Guru

Portugal
2321 Posts

Posted - Jan 28 2008 :  3:51:05 PM  Show Profile  Reply with Quote
Where does the "Filter (xx)" under the first .h and .cpp file come from and why is is there?

feline
Whole Tomato Software

United Kingdom
18942 Posts

Posted - Jan 28 2008 :  5:35:47 PM  Show Profile  Reply with Quote
It is an attempt to explain the scope / location of the reference. If you do a Find References instead and jump to one of those then hopefully it will make a bit more sense. Some of those look like they might be function names, so the function the reference is found in.

zen is the art of being at one with the two'ness
Go to Top of Page

Uniwares
Tomato Guru

Portugal
2321 Posts

Posted - Jan 28 2008 :  6:04:12 PM  Show Profile  Reply with Quote
The closest it comes to is the namespace it is in (Uniwares::Mail::Filter). But then again, as you can see in the other .h and .cpp files, they are not shown to be in the same namespace as they are, rather it shows the classname.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18942 Posts

Posted - Jan 29 2008 :  07:30:32 AM  Show Profile  Reply with Quote
I have added the following, simple test case, to a header file:

class testThingsGenerally
{
private:
	int m_nSize;

public:
	void calculateSomething();
	void addChocolate();
};

void testThingsGenerally::calculateSomething()
{
	m_nSize = 2;
}

void testThingsGenerally::addChocolate()
{
	m_nSize = 3;
}

When I do a Find References on "m_nSize" I get the following:

c:\\src\\tests\\test_general.h
	testThingsGenerally (8):    int m_nSize;
	calculateSomething (17):    m_nSize = 2;
	addChocolate (22):    m_nSize = 3;

The numbers in round brackets are the line number in the current file, and the "word" in front of the number is the class or function that contains the reference. The "word" is a simple summary of the "scope" of the reference.

I see the same information in the Rename dialog when running a rename on "m_nSize".

Does what you are seeing make a bit more sense now?

zen is the art of being at one with the two'ness

Edited by - feline on Jan 29 2008 07:31:07 AM
Go to Top of Page

Uniwares
Tomato Guru

Portugal
2321 Posts

Posted - Jan 29 2008 :  08:52:45 AM  Show Profile  Reply with Quote
I already got your point, but it does not explain why the "scope word" in one case on the screen shot shows the namespace and in the other it shows the class name.

Compare the ctor of LoadAllSQLFilterDataStream with the ctor of RegExSQLDataStream, different files, same namespace (Uniwares::Mail::Filter), same scope, yet VAX shows a different "scope word"
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18942 Posts

Posted - Jan 29 2008 :  2:16:50 PM  Show Profile  Reply with Quote
Since I am not quite sure what your code looks like, I have run some more tests using this code. In the header file:

class testThingsGenerally
{
private:
	int m_nSize;

public:
	testThingsGenerally();
	~testThingsGenerally();
	void calculateSomething();
	void addChocolate();
};

namespace FELINE_TEST_GENERAL
{
	class testThingsGenerallySpace
	{
	public:
		testThingsGenerallySpace();
		~testThingsGenerallySpace();
	};
};

and in the matching cpp file:
testThingsGenerally::testThingsGenerally()	{ }
testThingsGenerally::~testThingsGenerally()	{ }

namespace FELINE_TEST_GENERAL
{
	testThingsGenerallySpace::testThingsGenerallySpace()	{ }
	testThingsGenerallySpace::~testThingsGenerallySpace()	{ }
}


When I run Find References on "testThingsGenerally" the references in the cpp file have no scope. That makes sense since they are at file scope.

When I run Find References on "testThingsGenerallySpace" the references in the cpp file have the namespace as the scope.

I suspect, but do not know for sure, that the namespace macro's are behind the mixed results you are seeing.

zen is the art of being at one with the two'ness
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000