Commit 54d60a77 authored by Roberto Raggi's avatar Roberto Raggi

Use the canonical symbol when searching references.

parent efed56c4
......@@ -259,8 +259,15 @@ void CppFindReferences::findAll(const Snapshot &snapshot, Symbol *symbol)
Core::ProgressManager *progressManager = Core::ICore::instance()->progressManager();
// find the canonical symbol.
Symbol *canonicalSymbol = symbol;
for (; symbol; symbol = symbol->next()) {
if (symbol->name() == canonicalSymbol->name())
canonicalSymbol = symbol;
}
QFuture<Core::Utils::FileSearchResult> result =
QtConcurrent::run(&find_helper, snapshot, symbol);
QtConcurrent::run(&find_helper, snapshot, canonicalSymbol);
m_watcher.setFuture(result);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment