Skip to content

Commit 904241e

Browse files
committed
respond to review comments§
1 parent 15ada54 commit 904241e

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

flang/lib/Evaluate/tools.cpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1217,12 +1217,6 @@ struct HasStructureComponentHelper
12171217
HasStructureComponentHelper() : Base(*this) {}
12181218
using Base::operator();
12191219

1220-
bool operator()(const DataRef &dataRef) const {
1221-
return std::holds_alternative<Component>(dataRef.u);
1222-
}
1223-
bool operator()(const NamedEntity &NamedEntity) const {
1224-
return NamedEntity.UnwrapComponent() != nullptr;
1225-
}
12261220
bool operator()(const Component &) const { return true; }
12271221
};
12281222

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4676,7 +4676,7 @@ void OmpStructureChecker::CheckStructureComponent(
46764676
if (const parser::DataRef *dataRef{
46774677
std::get_if<parser::DataRef>(&designator.u)}) {
46784678
if (!IsDataRefTypeParamInquiry(dataRef)) {
4679-
const auto expr = AnalyzeExpr(context_, designator);
4679+
const auto expr {AnalyzeExpr(context_, designator)};
46804680
if (expr.has_value() && evaluate::HasStructureComponent(expr.value())) {
46814681
context_.Say(designator.source,
46824682
"A variable that is part of another variable cannot appear on the %s clause"_err_en_US,

0 commit comments

Comments
 (0)