From ae79b4759d9479d6ecabf8b3e36272ad9dc74852 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Sun, 18 Jul 2021 19:31:19 +0200 Subject: [PATCH] CI; Fix self check false positives --- lib/checkfunctions.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/checkfunctions.cpp b/lib/checkfunctions.cpp index e556f1461..de913e663 100644 --- a/lib/checkfunctions.cpp +++ b/lib/checkfunctions.cpp @@ -273,7 +273,7 @@ void CheckFunctions::checkMissingReturn() } if (inconclusive && Token::simpleMatch(scope->bodyEnd->tokAt(-2), ") ; }")) { const Token *ftok = scope->bodyEnd->linkAt(-2)->previous(); - if (mSettings->library.isNotLibraryFunction(ftok)) { + if (mSettings->library.isNotLibraryFunction(ftok) && !ftok->isKeyword()) { const Token *tok = ftok; while (Token::Match(tok->tokAt(-2), "%name% :: %name%")) tok = tok->tokAt(-2);