Details
-
Bug
-
Resolution: Duplicate
-
Not Evaluated
-
None
-
Qt Creator 2.4.0
-
None
Description
I submitted this a few years ago, and the answer was "yeah we know, but this would be complicated to fix". Still, I've just lost many minutes to this bug so am motivated to resubmit it!
Basically, create two projects, open them both and create two identical symbols (classes, functions, whatever) in the projects. Now if you ctrl-click / follow symbol to get to the definition of one of these symbols, it often jumps to the other project file! There's little warning about this (the only thing is the highlighted file in the file list), so I've spend a lot of time editing the wrong file, and wondering why my changes had no effect!
And in case you're wondering why on earth someone would have two things the same, well it is server and client thing using the same code. Copying the files is by far the easiest way to do this.
The fix (well, hacky fix) is surely fairly simple: if more than one symbol location is found, prefer the one in the same project! I understand you guys are moving to an LLVM-based code parser. Would that fix this bug? If not, it might be worth implementing a less hacky fix...
Attachments
Issue Links
- is replaced by
-
QTCREATORBUG-6697 Qt Creator sometimes confuses files with the same name even though they're in different projects
-
- Closed
-