(j3.2006) Final subroutines and coarrays

Tobias Burnus burnus
Sun Feb 5 09:59:02 EST 2012


Dear all,

if I correctly read the F2008 standard, one is allowed to have a FINAL 
subroutine with a dummy argument which is a coarray. If one has such a 
variable, it would be only finalized if it is a coarray. (or if the 
variable is an array and there is an elemental FINAL subroutine).

Do I read the Fortran standard correctly? Or is there something hidden, 
which disallows coarrays as dummy argument of a FINAL subroutine?

Tobias

PS: WG5/N1830 has:

C480 (R452) A final-subroutine-name shall be the name of a module 
procedure with exactly one dummy argument. That argument shall be 
nonoptional and shall be a nonpointer, nonallocatable, nonpolymorphic 
variable of the derived type being defined. All length type parameters 
of the dummy argument shall be assumed. The dummy argument shall not 
have the INTENT (OUT) or VALUE attribute.

C482 (R452) A final subroutine shall not have a dummy argument with the 
same kind type parameters and rank as the dummy argument of another 
final subroutine of that type.



More information about the J3 mailing list