[all-commits] [llvm/llvm-project] 90c4ed: [flang] Dial some errors down to warnings for ASSO...

Peter Klausler via All-commits all-commits at lists.llvm.org
Mon Jul 25 11:06:46 PDT 2022

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 90c4eda3d29a9d08744891b941a30f1be61dbe46
  Author: Peter Klausler <pklausler at nvidia.com>
  Date:   2022-07-25 (Mon, 25 Jul 2022)

  Changed paths:
    M flang/lib/Evaluate/intrinsics.cpp
    M flang/test/Semantics/associated.f90

  Log Message:
  [flang] Dial some errors down to warnings for ASSOCIATED()

When a procedure pointer is associated with a procedure target, f18
will emit hard error messages if the pointer is incompatible with the
target in a way that would cause the program to not work if the
procedure pointer were actually called.  However, in the context of
the ASSOCIATED() intrinsic, the compiler should not consider a query
to be a compilation-time error if the pointer and the target are
incompatible.  The standard gives us sufficient wiggle room here
to treat these cases as warnings.

Attempts to use ASSOCIATED to test whether a procedure pointer is
associated with a data object, or vice versa, remain errors.

Differential Revision: https://reviews.llvm.org/D130384

More information about the All-commits mailing list