ClangCodeModel: Fix an instance of mis-highlighting with clangd

In the expression x.f(), x was wrongly categorized as an output
parameter if f was a static function.

Change-Id: I9167f98916963cdaa4b5ac6ead2c86fab43ad02e
Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
Christian Kandeler
2021-09-16 13:37:14 +02:00
parent b771bdf4c1
commit 56f9d17d35
3 changed files with 15 additions and 0 deletions

View File

@@ -2444,6 +2444,10 @@ static void semanticHighlighter(QFutureInterface<TextEditor::HighlightingResult>
}
if (it->kind().endsWith("Cast") && it->hasConstType())
return false;
if (it->kind() == "Member" && it->arcanaContains("(")
&& !it->arcanaContains("bound member function type")) {
return false;
}
}
return false;
};