53 auto ExcludedOperators = binaryOperation(hasAnyOperatorName(
54 "|",
"&",
"^",
"<<",
">>",
"~",
"|=",
"&=",
"^=",
"<<=",
">>="));
57 castExpr(hasCastKind(CK_IntegralToBoolean),
58 unless(isExpansionInSystemHeader()), hasType(booleanType()),
60 expr(hasType(qualType(hasCanonicalType(hasDeclaration(
61 enumDecl(isCompleteAndHasNoZeroValue(),
65 unless(declRefExpr(to(enumConstantDecl()))),
66 unless(ignoringParenImpCasts(ExcludedOperators)))),
67 unless(hasAncestor(staticAssertDecl())))
Every ClangTidyCheck reports errors through a DiagnosticsEngine provided by this context.