Ask a question
Missed IBM TechXchange Dev Day: Virtual Agents? On-demand viewing is available here
Originally posted by: ChristineLi
To facilitate function calls, a constraint has been relaxed according to TS29113, starting from XL Fortran for AIX Fix Pack 1 (September 2014 PTF) for 15.1 and XL Fortran for Linux Fix Pack 1 (October 2014 PTFs) for 15.1. Now you can pass a scalar as the actual argument that corresponds to an assumed-size dummy argument of assumed-type. In this case, the assumed-size array dummy argument has exactly one element.
Here is a code example for your reference:
REAL r1 CALL sub(r1) !You can pass a scalar as the actual argument that corresponds !to an assumed-size dummy argument of assumed-type. CONTAINS SUBROUTINE sub(arg) TYPE(*) :: arg(3, 2:*) END END