[flang-commits] [flang] b752a8c - [flang][NFC] Verify C781 from - Clause 7 constraint checks for f18.
Sameeran joshi via flang-commits
flang-commits at lists.llvm.org
Fri Jul 31 11:28:34 PDT 2020
Author: sameeran joshi
Date: 2020-07-31T23:58:18+05:30
New Revision: b752a8ca499b84d46c5b710f7a3b475fdf0d752e
URL: https://github.com/llvm/llvm-project/commit/b752a8ca499b84d46c5b710f7a3b475fdf0d752e
DIFF: https://github.com/llvm/llvm-project/commit/b752a8ca499b84d46c5b710f7a3b475fdf0d752e.diff
LOG: [flang][NFC] Verify C781 from - Clause 7 constraint checks for f18.
Reviewed By: PeteSteinfeld
Differential Revision: https://reviews.llvm.org/D84503
Added:
Modified:
flang/lib/Semantics/resolve-names.cpp
flang/test/Semantics/bindings01.f90
flang/test/Semantics/resolve80.f90
Removed:
################################################################################
diff --git a/flang/lib/Semantics/resolve-names.cpp b/flang/lib/Semantics/resolve-names.cpp
index eb7dd697b274..e85dfa9c91ef 100644
--- a/flang/lib/Semantics/resolve-names.cpp
+++ b/flang/lib/Semantics/resolve-names.cpp
@@ -1547,7 +1547,7 @@ bool AttrsVisitor::IsConflictingAttr(Attr attrName) {
return HaveAttrConflict(attrName, Attr::INTENT_IN, Attr::INTENT_INOUT) ||
HaveAttrConflict(attrName, Attr::INTENT_IN, Attr::INTENT_OUT) ||
HaveAttrConflict(attrName, Attr::INTENT_INOUT, Attr::INTENT_OUT) ||
- HaveAttrConflict(attrName, Attr::PASS, Attr::NOPASS) ||
+ HaveAttrConflict(attrName, Attr::PASS, Attr::NOPASS) || // C781
HaveAttrConflict(attrName, Attr::PURE, Attr::IMPURE) ||
HaveAttrConflict(attrName, Attr::PUBLIC, Attr::PRIVATE) ||
HaveAttrConflict(attrName, Attr::RECURSIVE, Attr::NON_RECURSIVE);
diff --git a/flang/test/Semantics/bindings01.f90 b/flang/test/Semantics/bindings01.f90
index 26dd25a24650..f2d5876167c2 100644
--- a/flang/test/Semantics/bindings01.f90
+++ b/flang/test/Semantics/bindings01.f90
@@ -1,6 +1,6 @@
! RUN: %S/test_errors.sh %s %t %f18
! Confirm enforcement of constraints and restrictions in 7.5.7.3
-! and C733, C734 and C779, C780, C781, C782, C783, C784, and C785.
+! and C733, C734 and C779, C780, C782, C783, C784, and C785.
module m
!ERROR: An ABSTRACT derived type must be extensible
diff --git a/flang/test/Semantics/resolve80.f90 b/flang/test/Semantics/resolve80.f90
index 7e9df344a161..689187d4e15e 100644
--- a/flang/test/Semantics/resolve80.f90
+++ b/flang/test/Semantics/resolve80.f90
@@ -26,7 +26,7 @@ module m
!WARNING: Attribute 'PASS' cannot be used more than once
procedure(subPass), pass, deferred, pass :: passBinding
!ERROR: Attributes 'PASS' and 'NOPASS' conflict with each other
- procedure(subPassNopass), pass, deferred, nopass :: passNopassBinding
+ procedure(subPassNopass), pass, deferred, nopass :: passNopassBinding ! C781
end type boundProcType
contains
More information about the flang-commits
mailing list