@@ -941,9 +941,9 @@ void OmpStructureChecker::Leave(const parser::OpenMPLoopConstruct &x) {
941941 dirContext_.pop_back ();
942942
943943 assert (!loopStack_.empty () && " Expecting non-empty loop stack" );
944- const LoopConstruct &top = loopStack_.back ();
944+ const LoopConstruct &top{ loopStack_.back ()} ;
945945#ifndef NDEBUG
946- auto *loopc = std::get_if<const parser::OpenMPLoopConstruct *>(&top);
946+ auto *loopc{ std::get_if<const parser::OpenMPLoopConstruct *>(&top)} ;
947947 assert (loopc != nullptr && *loopc == &x && " Mismatched loop constructs" );
948948#endif
949949 loopStack_.pop_back ();
@@ -1633,8 +1633,8 @@ void OmpStructureChecker::ChecksOnOrderedAsStandalone() {
16331633 int dependSinkCount{0 }, dependSourceCount{0 };
16341634 bool exclusiveShown{false }, duplicateSourceShown{false };
16351635
1636- auto visitDoacross = [&](const parser::OmpDoacross &doa,
1637- const parser::CharBlock &src) {
1636+ auto visitDoacross{ [&](const parser::OmpDoacross &doa,
1637+ const parser::CharBlock &src) {
16381638 common::visit (
16391639 common::visitors{
16401640 [&](const parser::OmpDoacross::Source &) { dependSourceCount++; },
@@ -1650,11 +1650,11 @@ void OmpStructureChecker::ChecksOnOrderedAsStandalone() {
16501650 context_.Say (src,
16511651 " At most one SOURCE dependence type can appear on the ORDERED directive" _err_en_US);
16521652 }
1653- };
1653+ }} ;
16541654
16551655 // Visit the DEPEND and DOACROSS clauses.
1656- auto depClauses = FindClauses (llvm::omp::Clause::OMPC_depend);
1657- for (auto itr = depClauses.first ; itr != depClauses.second ; ++itr) {
1656+ auto depClauses{ FindClauses (llvm::omp::Clause::OMPC_depend)} ;
1657+ for (auto itr{ depClauses.first } ; itr != depClauses.second ; ++itr) {
16581658 const auto &dependClause{
16591659 std::get<parser::OmpClause::Depend>(itr->second ->u )};
16601660 if (auto *doAcross{std::get_if<parser::OmpDoacross>(&dependClause.v .u )}) {
@@ -1665,7 +1665,7 @@ void OmpStructureChecker::ChecksOnOrderedAsStandalone() {
16651665 }
16661666 }
16671667 auto doaClauses{FindClauses (llvm::omp::Clause::OMPC_doacross)};
1668- for (auto itr = doaClauses.first ; itr != doaClauses.second ; ++itr) {
1668+ for (auto itr{ doaClauses.first } ; itr != doaClauses.second ; ++itr) {
16691669 auto &doaClause{std::get<parser::OmpClause::Doacross>(itr->second ->u )};
16701670 visitDoacross (doaClause.v .v , itr->second ->source );
16711671 }
@@ -4405,7 +4405,7 @@ void OmpStructureChecker::Leave(const parser::DoConstruct &x) {
44054405 assert (!loopStack_.empty () && " Expecting non-empty loop stack" );
44064406 const LoopConstruct &top = loopStack_.back ();
44074407#ifndef NDEBUG
4408- auto *doc = std::get_if<const parser::DoConstruct *>(&top);
4408+ auto *doc{ std::get_if<const parser::DoConstruct *>(&top)} ;
44094409 assert (doc != nullptr && *doc == &x && " Mismatched loop constructs" );
44104410#endif
44114411 loopStack_.pop_back ();
0 commit comments