Index: clang/include/clang/Analysis/CallGraph.h =================================================================== --- clang/include/clang/Analysis/CallGraph.h +++ clang/include/clang/Analysis/CallGraph.h @@ -60,7 +60,7 @@ /// /// Recursively walks the declaration to find all the dependent Decls as well. void addToCallGraph(Decl *D) { - TraverseDecl(D); + (void)TraverseDecl(D); } /// Determine if a declaration should be included in the graph. Index: clang/lib/AST/ExprConstant.cpp =================================================================== --- clang/lib/AST/ExprConstant.cpp +++ clang/lib/AST/ExprConstant.cpp @@ -16244,7 +16244,7 @@ CallStackFrame Frame(Info, SourceLocation(), FD, /*This*/ nullptr, CallRef()); APValue ResultScratch; - Evaluate(ResultScratch, Info, E); + (void)Evaluate(ResultScratch, Info, E); return Diags.empty(); } Index: clang/lib/ASTMatchers/ASTMatchFinder.cpp =================================================================== --- clang/lib/ASTMatchers/ASTMatchFinder.cpp +++ clang/lib/ASTMatchers/ASTMatchFinder.cpp @@ -569,7 +569,7 @@ if (LE->hasExplicitParameters()) { // Visit parameters. for (ParmVarDecl *Param : Proto.getParams()) - TraverseDecl(Param); + (void)TraverseDecl(Param); } const auto *T = Proto.getTypePtr(); Index: clang/lib/Analysis/UnsafeBufferUsage.cpp =================================================================== --- clang/lib/Analysis/UnsafeBufferUsage.cpp +++ clang/lib/Analysis/UnsafeBufferUsage.cpp @@ -44,7 +44,7 @@ bool findMatch(const DynTypedNode &DynNode) { Matches = false; if (const Stmt *StmtNode = DynNode.get()) { - TraverseStmt(const_cast(StmtNode)); + (void)TraverseStmt(const_cast(StmtNode)); *Builder = ResultBindings; return Matches; } Index: clang/lib/Format/TokenAnnotator.cpp =================================================================== --- clang/lib/Format/TokenAnnotator.cpp +++ clang/lib/Format/TokenAnnotator.cpp @@ -1272,7 +1272,7 @@ if (Next->is(tok::less)) next(); else - consumeToken(); + (void)consumeToken(); if (!CurrentToken) break; auto Previous = CurrentToken->getPreviousNonComment(); Index: clang/lib/Parse/ParseObjc.cpp =================================================================== --- clang/lib/Parse/ParseObjc.cpp +++ clang/lib/Parse/ParseObjc.cpp @@ -3052,7 +3052,7 @@ const Token &AfterNext = GetLookAheadToken(2); if (AfterNext.isOneOf(tok::colon, tok::r_square)) { if (Tok.is(tok::identifier)) - TryAnnotateTypeOrScopeToken(); + (void)TryAnnotateTypeOrScopeToken(); return Tok.is(tok::annot_typename); } Index: clang/lib/Parse/Parser.cpp =================================================================== --- clang/lib/Parse/Parser.cpp +++ clang/lib/Parse/Parser.cpp @@ -1603,7 +1603,7 @@ // Otherwise recover by skipping to next semi or mandatory function body. if (SkipUntil(tok::l_brace, StopAtSemi | StopBeforeMatch)) break; - TryConsumeToken(tok::semi); + (void)TryConsumeToken(tok::semi); } // The actions module must verify that all arguments were declared. Index: llvm/include/llvm/Demangle/ItaniumDemangle.h =================================================================== --- llvm/include/llvm/Demangle/ItaniumDemangle.h +++ llvm/include/llvm/Demangle/ItaniumDemangle.h @@ -3333,7 +3333,7 @@ if (consumeIf("dn")) return getDerived().parseDestructorName(); - consumeIf("on"); + (void)consumeIf("on"); Node *Oper = getDerived().parseOperatorName(/*NameState=*/nullptr); if (Oper == nullptr) @@ -3466,7 +3466,7 @@ AbstractManglingParser::parseNumber(bool AllowNegative) { const char *Tmp = First; if (AllowNegative) - consumeIf('n'); + (void)consumeIf('n'); if (numLeft() == 0 || !std::isdigit(*First)) return StringView(); while (numLeft() != 0 && std::isdigit(*First)) @@ -3535,7 +3535,7 @@ return nullptr; } - consumeIf("Dx"); // transaction safe + (void)consumeIf("Dx"); // transaction safe if (!consumeIf('F')) return nullptr;