Clang: Fix highlighting of template function in using declaration

This completes

    commit a3a62e78f7
    Clang: Fix highlighting of function in using declaration

Change-Id: I3c163096374d7a1f45a590bb8ebfe5f5a1f8d417
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
This commit is contained in:
Nikolai Kosjar
2017-08-10 15:24:50 +02:00
parent 63551d7711
commit c0364564a4
3 changed files with 12 additions and 1 deletions

View File

@@ -165,7 +165,8 @@ void HighlightingMark::overloadedDeclRefKind(const Cursor &cursor)
// Workaround https://bugs.llvm.org//show_bug.cgi?id=33256 - SomeType in
// "using N::SomeType" is mistakenly considered as a CXCursor_OverloadedDeclRef.
if (cursor.overloadedDeclarationsCount() >= 1
&& cursor.overloadedDeclaration(0).kind() != CXCursor_FunctionDecl) {
&& cursor.overloadedDeclaration(0).kind() != CXCursor_FunctionDecl
&& cursor.overloadedDeclaration(0).kind() != CXCursor_FunctionTemplate) {
m_types.mainHighlightingType = HighlightingType::Type;
}
}