[flang] Stricter scrutiny of MOVE_ALLOC calls
authorPeter Klausler <pklausler@nvidia.com>
Thu, 13 Oct 2022 23:44:34 +0000 (16:44 -0700)
committerPeter Klausler <pklausler@nvidia.com>
Sun, 30 Oct 2022 16:50:47 +0000 (09:50 -0700)
commita6935cfed89edb1e10cd20ae0062362b6bdbbda0
tree64bc1e61bdd08d450773b9e2021389879e287df2
parente125e6c429e16741b128b2cab3787cdc57e166c6
[flang] Stricter scrutiny of MOVE_ALLOC calls

Enforce remaining semantic restrictions on the arguments to MOVE_ALLOC,
namely that the first two arguments must be allocatable (!) and that
if the source is polymorphic, so must the destination be.

Differential Revision: https://reviews.llvm.org/D136973
flang/lib/Evaluate/intrinsics.cpp
flang/test/Semantics/move_alloc.f90