Commit 4e0bc293 authored by Sergey Kalinichev's avatar Sergey Kalinichev

Fix code completion performance regression

Use PersistentSymbolTable for functions. It doesn't break the scope.

This should fix issues with slow code-completion when there are
a lot of functions with broken ranges (e.g. from macro expansions).
This happens for some system headers.
parent 5ffe0c1d
......@@ -454,7 +454,7 @@ Declaration* findDeclaration(const QualifiedIdentifier& qid, const DUContextPoin
for (auto it = decl.iterator(); it; ++it) {
auto declaration = it->declaration();
if (declaration->kind() == Declaration::Instance) {
if (declaration->kind() == Declaration::Instance && !declaration->isFunctionDeclaration()) {
break;
}
if (!handled.contains(declaration)) {
......
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