[all-commits] [llvm/llvm-project] 0c1905: [flang] Make generic resolution conform to 15.5.5....

Peter Klausler via All-commits all-commits at lists.llvm.org
Sat May 28 10:06:28 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 0c190575ebfc81e117d95e2eca25789610192125
      https://github.com/llvm/llvm-project/commit/0c190575ebfc81e117d95e2eca25789610192125
  Author: Peter Klausler <pklausler at nvidia.com>
  Date:   2022-05-28 (Sat, 28 May 2022)

  Changed paths:
    M flang/include/flang/Semantics/expression.h
    M flang/include/flang/Semantics/tools.h
    M flang/lib/Semantics/expression.cpp
    M flang/lib/Semantics/resolve-names.cpp
    M flang/lib/Semantics/tools.cpp
    A flang/test/Semantics/generic01.f90
    M flang/test/Semantics/resolve22.f90

  Log Message:
  -----------
  [flang] Make generic resolution conform to 15.5.5.2 w/r/t host association

When two or more generic interfaces are available by declaration or
by USE association at different scoping levels, we need to search
the outer generic interfaces as well as the inner ones, but only after
the inner ones have failed to produce a specific procedure that matches
a given set of actual arguments.  This means that it is possible for
a specific procedure of a generic interface of an inner scope to override
a conflicting specific procedure of a generic interface of an outer
scope.

Also cope with forward references to derived types when a generic
interface is also in scope.

Fixes LLVM bug https://github.com/llvm/llvm-project/issues/55240 and
LLVM bug https://github.com/llvm/llvm-project/issues/55300.

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




More information about the All-commits mailing list