[clang] 0c2ded6 - [NFC] Fix compile warning introduced in #99732
Shilei Tian via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 6 09:45:55 PDT 2024
Author: Shilei Tian
Date: 2024-08-06T12:45:29-04:00
New Revision: 0c2ded670652c73cb0245b2a8ec065cd1b4f0c6f
URL: https://github.com/llvm/llvm-project/commit/0c2ded670652c73cb0245b2a8ec065cd1b4f0c6f
DIFF: https://github.com/llvm/llvm-project/commit/0c2ded670652c73cb0245b2a8ec065cd1b4f0c6f.diff
LOG: [NFC] Fix compile warning introduced in #99732
Added:
Modified:
clang/lib/Parse/ParseOpenMP.cpp
clang/lib/Serialization/ASTReader.cpp
Removed:
################################################################################
diff --git a/clang/lib/Parse/ParseOpenMP.cpp b/clang/lib/Parse/ParseOpenMP.cpp
index 899a56d3d5dfb..5732ee7add7c0 100644
--- a/clang/lib/Parse/ParseOpenMP.cpp
+++ b/clang/lib/Parse/ParseOpenMP.cpp
@@ -3337,7 +3337,7 @@ OMPClause *Parser::ParseOpenMPClause(OpenMPDirectiveKind DKind,
<< getOpenMPDirectiveName(DKind) << getOpenMPClauseName(CKind) << 0;
ErrorFound = true;
}
- [[clang::fallthrough]];
+ [[fallthrough]];
case OMPC_private:
case OMPC_firstprivate:
case OMPC_lastprivate:
diff --git a/clang/lib/Serialization/ASTReader.cpp b/clang/lib/Serialization/ASTReader.cpp
index 383b128145dce..ad9cc9f62b1fa 100644
--- a/clang/lib/Serialization/ASTReader.cpp
+++ b/clang/lib/Serialization/ASTReader.cpp
@@ -11423,7 +11423,7 @@ void OMPClauseReader::VisitOMPNumTeamsClause(OMPNumTeamsClause *C) {
unsigned NumVars = C->varlist_size();
SmallVector<Expr *, 16> Vars;
Vars.reserve(NumVars);
- for (auto _ : llvm::seq<unsigned>(NumVars)) {
+ for ([[maybe_unused]] auto _ : llvm::seq<unsigned>(NumVars)) {
(void)_;
Vars.push_back(Record.readSubExpr());
}
More information about the cfe-commits
mailing list