[PATCH] D84503: [flang][NFC] Verify C781 from - Clause 7 constraint checks for f18.

sameeran joshi via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 24 03:03:15 PDT 2020


sameeranjoshi created this revision.
sameeranjoshi added reviewers: PeteSteinfeld, sscalpone.
sameeranjoshi added a project: Flang.
Herald added a reviewer: jdoerfert.
Herald added a reviewer: DavidTruby.
Herald added a project: LLVM.

Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D84503

Files:
  flang/lib/Semantics/resolve-names.cpp
  flang/test/Semantics/bindings01.f90
  flang/test/Semantics/resolve80.f90


Index: flang/test/Semantics/resolve80.f90
===================================================================
--- flang/test/Semantics/resolve80.f90
+++ flang/test/Semantics/resolve80.f90
@@ -26,7 +26,7 @@
     !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
Index: flang/test/Semantics/bindings01.f90
===================================================================
--- flang/test/Semantics/bindings01.f90
+++ 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
Index: flang/lib/Semantics/resolve-names.cpp
===================================================================
--- flang/lib/Semantics/resolve-names.cpp
+++ flang/lib/Semantics/resolve-names.cpp
@@ -1651,7 +1651,7 @@
   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);


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D84503.280379.patch
Type: text/x-patch
Size: 1880 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200724/793695a0/attachment.bin>


More information about the llvm-commits mailing list