[flang-commits] [flang] [llvm] Adding parsing and semantic support for scan directive. (PR #102792)
Anchu Rajendran S via flang-commits
flang-commits at lists.llvm.org
Wed Aug 28 16:59:09 PDT 2024
================
@@ -1591,6 +1593,20 @@ bool OmpAttributeVisitor::Pre(
default:
break;
}
+ if (standaloneDir.v == llvm::omp::Directive::OMPD_scan) {
+ if ((std::get<parser::OmpClauseList>(x.t).v.size() != 1)) {
+ context_.Say(standaloneDir.source,
+ "Exactly one of `exclusive` or `inclusive` clause is expected"_err_en_US);
+ }
+ if (!parentContext ||
+ (llvm::omp::getDirectiveAssociation(parentContext->directive) !=
----------------
anchuraj wrote:
I added a directive set. I copied this piece directly from clang. However, this would be a great improvement so I made the change accordingly. Thank you!
https://github.com/llvm/llvm-project/pull/102792
More information about the flang-commits
mailing list