From b302b0921cfed2b8db3a5c0e6a01f33fdc63db29 Mon Sep 17 00:00:00 2001 From: chrchr-github <78114321+chrchr-github@users.noreply.github.com> Date: Mon, 30 Sep 2024 14:17:04 +0200 Subject: [PATCH] Update tokenize.cpp --- lib/tokenize.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/tokenize.cpp b/lib/tokenize.cpp index 22c34ccf079..9102c750600 100644 --- a/lib/tokenize.cpp +++ b/lib/tokenize.cpp @@ -698,7 +698,7 @@ namespace { mRangeAfterVar.second = mEndToken; return; } - if (Token::Match(type, "%name% ( !!(") && Token::simpleMatch(type->linkAt(1), ") ;") && !type->isStandardType() && type->linkAt(1) != type->next()) { + if (type != start && Token::Match(type, "%name% ( !!(") && Token::simpleMatch(type->linkAt(1), ") ;") && !type->isStandardType()) { mNameToken = type; mEndToken = type->linkAt(1)->next(); mRangeType.first = start;