[clang] [clang-format] Handle templates in qualified typenames (PR #143194)
via cfe-commits
cfe-commits at lists.llvm.org
Fri Jan 9 20:03:26 PST 2026
================
@@ -3669,12 +3718,11 @@ static FormatToken *getFunctionName(const AnnotatedLine &Line,
}
// Skip to the unqualified part of the name.
- while (Tok->startsSequence(tok::identifier, tok::coloncolon)) {
- assert(Tok->Next);
- Tok = Tok->Next->Next;
- if (!Tok)
- return nullptr;
- }
+ while (FormatToken *Next = skipNameQualifier(Tok))
+ Tok = Next;
+
+ if (!Tok)
+ return nullptr;
----------------
owenca wrote:
Addressed in 0bac8f1729512a0b392908d6a57a00b0387a855f
https://github.com/llvm/llvm-project/pull/143194
More information about the cfe-commits
mailing list