Skip to content

Commit b9c55a2

Browse files
committed
Fix style and format
1 parent 1cbe00d commit b9c55a2

File tree

1 file changed

+9
-11
lines changed

1 file changed

+9
-11
lines changed

flang/lib/Semantics/check-omp-structure.cpp

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1480,17 +1480,15 @@ void OmpStructureChecker::CheckThreadprivateOrDeclareTargetVar(
14801480
}
14811481
},
14821482
[&](const parser::Name &name) {
1483-
if (!name.symbol) {
1484-
return;
1485-
}
1486-
if (auto *cb{name.symbol->detailsIf<CommonBlockDetails>()}) {
1487-
for (const auto &obj : cb->objects()) {
1488-
if (FindEquivalenceSet(*obj)) {
1489-
context_.Say(name.source,
1490-
"A variable in a %s directive cannot appear in an EQUIVALENCE statement"
1491-
" (variable '%s' from common block '/%s/')"_err_en_US,
1492-
ContextDirectiveAsFortran(), obj->name(),
1493-
name.symbol->name());
1483+
if (name.symbol) {
1484+
if (auto *cb{name.symbol->detailsIf<CommonBlockDetails>()}) {
1485+
for (const auto &obj : cb->objects()) {
1486+
if (FindEquivalenceSet(*obj)) {
1487+
context_.Say(name.source,
1488+
"A variable in a %s directive cannot appear in an EQUIVALENCE statement (variable '%s' from common block '/%s/')"_err_en_US,
1489+
ContextDirectiveAsFortran(), obj->name(),
1490+
name.symbol->name());
1491+
}
14941492
}
14951493
}
14961494
}

0 commit comments

Comments
 (0)