[flang-commits] [flang] [Flang][OpenMP] Fix false positive common block error in LINEAR clause (PR #189170)
Aditya Trivedi via flang-commits
flang-commits at lists.llvm.org
Sat Mar 28 22:07:49 PDT 2026
================
@@ -750,7 +750,7 @@ void OmpStructureChecker::Enter(const parser::OmpClause::Linear &x) {
"The list item `%s` in a LINEAR clause must not be Cray Pointer or a variable with POINTER attribute"_err_en_US,
symbol->name());
}
- if (FindCommonBlockContaining(*symbol)) {
+ if (symbol->has<CommonBlockDetails>()) {
context_.Say(source,
"'%s' is a common block name and must not appear in an LINEAR clause"_err_en_US,
----------------
adit4443ya wrote:
Done
https://github.com/llvm/llvm-project/pull/189170
More information about the flang-commits
mailing list