jaycetyle / vscode-gnu-global

Visual Studio Code GNU Global Extension
MIT License
33 stars 14 forks source link

Find references bug? #18

Closed CenJieTeng closed 4 years ago

CenJieTeng commented 4 years ago

win 7 vscode 1.45.0 Linux centos 6.4 gnu-global 6.6.4

Such as:

File: A.h
class A
{
    int target();
    int target;
}

File: B.h
class B
{
    int target();
    void func();
}

File:B.cpp
void B::func()
{
   int target = 0;
   int b = target;
}

File:C.h
class C
{
    void target();
}

main.cpp
int main()
{
    A a;
    a.target();
}

Find reference results for A::target(): A.h -->int target(); -->int target;

B.h -->int target(); B.cpp -->int target = 0; -->int b = target;

C.h -->void target();

main.cpp -->a.target();

I expect result: main.cpp -->a.target();

CenJieTeng commented 4 years ago

If the target is familiar function name(init, start, ...) and widely used,spend a lot of time Find references. My computer is behind, feel more obvious;