Using Eclipse Luna Service Release 2 (4.4.2), C and C++, although this problem relates to C code. Running Eclipse on Win XP.
I'm using a system with 2 projects. The projects are linked by Properties - Project References.
Some references work OK: I can use "open declaration" on a symbol in one project and it immediately jumps to the correct place in the 2nd project where it is defined. However, occasionally I find a symbol which brings up a dialog box "Open Declaration" listing 2 alternatives, both of which are exactly the same file (by exactly the same path). One of these choices gives the correct result, the other one gives almost the same except that it's a few lines out. Also, Eclipse (parser) thinks there are some syntax errors where there aren't any. I've rebuilt the index on both projects, tried referencing both projects to each other and also one way only. I've stopped Eclipse and restarted it.
Any solutions?
In my case, the index was out of sync.
From the top level in the project in Project Explorer, right-click and select Index-Rebuild.
Apparently it just happens every now and then; a colleague of mine encounters it regularly (Linux build).
See info about the indexer on Eclipse help.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With