Fortran Best Practice Minibook

I have a better answer, and closer to the way the check is implemented in nagfor, by requesting the -C=calls option. The ultimate cause is the same but the runtime error happens at the CALL statement. Thanks for making me look deeper (I have a sense of deja vu).

15.5.2.11 Sequence association, para 5

5 An actual argument that represents an element sequence and corresponds to a dummy argument that is an array is sequence associated with the dummy argument. The rank and shape of the actual argument need not agree with the rank and shape of the dummy argument, but the number of elements in the dummy argument shall not exceed the number of elements in the element sequence of the actual argument. If the dummy argument is assumed-size, the number of elements in the dummy argument is exactly the number of elements in the element sequence.

4 Likes