[flang-commits] [flang] d79c284 - [flang] Fix a warning
Kazu Hirata via flang-commits
flang-commits at lists.llvm.org
Tue Jul 1 10:34:48 PDT 2025
Author: Kazu Hirata
Date: 2025-07-01T10:34:41-07:00
New Revision: d79c284a2fef5f9cb6b803b3d0cb4c1f857ece03
URL: https://github.com/llvm/llvm-project/commit/d79c284a2fef5f9cb6b803b3d0cb4c1f857ece03
DIFF: https://github.com/llvm/llvm-project/commit/d79c284a2fef5f9cb6b803b3d0cb4c1f857ece03.diff
LOG: [flang] Fix a warning
This patch fixes:
flang/lib/Semantics/check-omp-structure.cpp:1747:41: error: lambda
capture 'this' is not used [-Werror,-Wunused-lambda-capture]
Added:
Modified:
flang/lib/Semantics/check-omp-structure.cpp
Removed:
################################################################################
diff --git a/flang/lib/Semantics/check-omp-structure.cpp b/flang/lib/Semantics/check-omp-structure.cpp
index 30eff01256c61..aa4cdb9d27019 100644
--- a/flang/lib/Semantics/check-omp-structure.cpp
+++ b/flang/lib/Semantics/check-omp-structure.cpp
@@ -1744,7 +1744,7 @@ void OmpStructureChecker::Enter(const parser::OpenMPFlushConstruct &x) {
void OmpStructureChecker::Leave(const parser::OpenMPFlushConstruct &x) {
auto &flushList{std::get<std::optional<parser::OmpArgumentList>>(x.v.t)};
- auto isVariableListItemOrCommonBlock{[this](const Symbol &sym) {
+ auto isVariableListItemOrCommonBlock{[](const Symbol &sym) {
return IsVariableListItem(sym) ||
sym.detailsIf<semantics::CommonBlockDetails>();
}};
More information about the flang-commits
mailing list