[flang-commits] [PATCH] D125139: [flang] Accept POINTER followed by INTERFACE

Peter Klausler via Phabricator via flang-commits flang-commits at lists.llvm.org
Fri May 6 15:30:07 PDT 2022


klausler created this revision.
klausler added a reviewer: jeanPerier.
klausler added a project: Flang.
Herald added subscribers: mehdi_amini, jdoerfert.
Herald added a project: All.
klausler requested review of this revision.

As is already supported for dummy procedures, we need to also accept
declarations of procedure pointers that consist of a POINTER attribute
statement followed by an INTERFACE block.  (The case of an INTERFACE
block followed by a POINTER statement already works.)

While cleaning this case up, adjust the utility predicate IsProcedurePointer()
to recognize it (namely a SubprogramDetails symbol with Attr::POINTER)
and delete IsProcName().  Extend tests, and add better comments to
symbol.h to document the two ways in which procedure pointers are
represented.


https://reviews.llvm.org/D125139

Files:
  flang/include/flang/Semantics/symbol.h
  flang/include/flang/Semantics/tools.h
  flang/lib/Evaluate/tools.cpp
  flang/lib/Lower/ConvertType.cpp
  flang/lib/Semantics/check-nullify.cpp
  flang/lib/Semantics/data-to-inits.cpp
  flang/lib/Semantics/resolve-names.cpp
  flang/lib/Semantics/tools.cpp
  flang/test/Semantics/nullify02.f90
  flang/test/Semantics/procinterface01.f90

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D125139.427772.patch
Type: text/x-patch
Size: 8000 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/flang-commits/attachments/20220506/f6399cc5/attachment-0001.bin>


More information about the flang-commits mailing list