Tag bug with duplicated class variable names

If reporting a bug with the Zeus IDE please post the details here. Please do not post questions here.
Post Reply
Jack Rosenbloom

Tag bug with duplicated class variable names

Post by Jack Rosenbloom »

If 2 different classes have a variable of the same name, then "Find Current Word" always naviagates to the same class.

Example

****my_class1.h***
class my_class1
{
void class1_routine(int para);
STATE my_states[3];
};


****my_class2.h***
class my_class2
{
void class2_routine(void);
STATE my_states[5];
};


****my_class1.cpp***
void class1 :: class1_routine( int para)
{
// SELECT my_state POSITION #1,
my_state[0].method();
}



****my_class2.cpp***
void class2 :: class2_routine( void )
{
// SELECT my_state POSITION #2
my_state[0].method();
}


Selecting my_state from position 1 or 2 will naviagate to the same class header file, even thought the classes are different.
jussij
Site Admin
Posts: 2650
Joined: Fri Aug 13, 2004 5:10 pm

Post by jussij »

If 2 different classes have a variable of the same name, then "Find Current Word" always naviagates to the same class.
This is not so much a bug as a feature :)

All the Find Current Word does is search the tag database for the current word and display the first item found and hence the function always display the same first item found.

But if you use the Find Tag Next, Find Tag Previous or Search Results menu options you can navigate to any other tags that might have been found.

I suppose the bug might be that the Search Results page was not displayed automatically, but I not convinced that this is best corse of action in a situation such as this :?:

Cheers Jussi
Post Reply