[flang] Add semantic check for multiple part-ref with non-zero rank
authorKelvin Li <kli@ca.ibm.com>
Thu, 19 Jan 2023 15:52:10 +0000 (10:52 -0500)
committerKelvin Li <kli@ca.ibm.com>
Thu, 19 Jan 2023 15:54:44 +0000 (10:54 -0500)
commitf13d6001324e9c9653d8568c1d86e182b217e272
tree3cedcc585f35660156ed34f8f7f7f192126a84f5
parent9c0f9572e21e8ef9cdbab4ead88e02cc53e7ad1f
[flang] Add semantic check for multiple part-ref with non-zero rank

This patch is to diagnose the case when a type bound procedure is passed as an actual procedure argument.

   call sub0(t%t3%t2%t%info1)

Fix: https://github.com/llvm/llvm-project/issues/55826

Committed on behalf of DanielCChen

Differential Revision: https://reviews.llvm.org/D141506
flang/lib/Semantics/expression.cpp
flang/test/Semantics/expr-errors04.f90