Skip to content

Commit abf8e6e

Browse files
committed
add braces
1 parent 3447262 commit abf8e6e

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

flang/lib/Parser/unparse.cpp

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2078,18 +2078,21 @@ class UnparseVisitor {
20782078
std::get<std::optional<std::list<OmpMapClause::TypeModifier>>>(x.t);
20792079
auto &type = std::get<std::optional<OmpMapClause::Type>>(x.t);
20802080
Walk(typeMod);
2081-
if (typeMod.has_value() && type.has_value())
2081+
if (typeMod.has_value() && type.has_value()) {
20822082
Put(", ");
2083+
}
20832084
Walk(type);
2084-
if (typeMod.has_value() || type.has_value())
2085+
if (typeMod.has_value() || type.has_value()) {
20852086
Put(": ");
2087+
}
20862088
Walk(std::get<OmpObjectList>(x.t));
20872089
}
20882090
void Unparse(const OmpMapClause::TypeModifier &x) {
2089-
if (x == OmpMapClause::TypeModifier::OmpxHold)
2091+
if (x == OmpMapClause::TypeModifier::OmpxHold) {
20902092
Word("OMPX_HOLD");
2091-
else
2093+
} else {
20922094
Word(OmpMapClause::EnumToString(x));
2095+
}
20932096
}
20942097
void Unparse(const OmpScheduleModifier &x) {
20952098
Walk(std::get<OmpScheduleModifier::Modifier1>(x.t));

0 commit comments

Comments
 (0)