[flang] Catch character length errors in pointer associations
authorPeter Klausler <pklausler@nvidia.com>
Tue, 3 Jan 2023 23:09:50 +0000 (15:09 -0800)
committerPeter Klausler <pklausler@nvidia.com>
Wed, 1 Feb 2023 20:12:43 +0000 (12:12 -0800)
commit50960e93833c821598044db131cf820edf6c6b3f
treef87cd47c6e5b9d2640440e474afa4eed738e7e92
parent3c1d0255d1788c607abb74ea0e775f1f753a9b94
[flang] Catch character length errors in pointer associations

When character lengths are known at compilation time, report an error
when a data target with a known length does not match the explicit length
of a pointer that is being associated with it; see 10.2.2.3 paragraph 5.

Differential Revision: https://reviews.llvm.org/D142755
flang/include/flang/Evaluate/characteristics.h
flang/lib/Evaluate/characteristics.cpp
flang/lib/Evaluate/variable.cpp
flang/lib/Semantics/check-call.cpp
flang/lib/Semantics/pointer-assignment.cpp
flang/test/Semantics/assign13.f90 [new file with mode: 0644]