[J3] Allocatation upon assignment of a bummy argument in an interoperable procedure
parekhvs at gmail.com
Mon Oct 7 14:09:50 EDT 2019
Is the following code conforming?
subroutine sub(foo) bind(C, name="foo")
!.. Argument list
integer(c_int), allocatable, intent(out) :: foo
foo = 42 !<-- fails
!allocate( foo ); foo = 42 !<-- works
When foo is invoked from a companion C processor with a successfully
established C descriptor with the right attributes, the use of
ALLOCATE statement followed by the assignment works as I expect.
However allocation upon assignment, as shown above, fails.
More information about the J3