Index: clang-tidy/misc/StaticAssertCheck.cpp =================================================================== --- clang-tidy/misc/StaticAssertCheck.cpp +++ clang-tidy/misc/StaticAssertCheck.cpp @@ -62,11 +62,15 @@ hasArgument(0, AssertCondition))), AssertCondition); - Finder->addMatcher(stmt(anyOf(conditionalOperator(hasCondition(Condition)), - ifStmt(hasCondition(Condition))), - unless(isInTemplateInstantiation())) + Finder->addMatcher(conditionalOperator(hasCondition(Condition), + unless(isInTemplateInstantiation())) .bind("condStmt"), this); + + Finder->addMatcher( + ifStmt(hasCondition(Condition), unless(isInTemplateInstantiation())) + .bind("condStmt"), + this); } void StaticAssertCheck::check(const MatchFinder::MatchResult &Result) {