[J3] Small problem with characteristics of procedures?

Robert Corbett rpcorbett at att.net
Mon Apr 22 19:01:39 UTC 2024


The omission is intentional.  A
 procedure with the BIND attribute will use the call mechanism for the language specified instead of the call mechanism used for procedures without the BIND attribute.  If an actual procedure with the BIND attribute were passed to a dummy procedure that does not have the BIND attribute, calls of the dummy procedure would result in unspecified behavior.

Bob Corbett

> On Apr 22, 2024, at 11:18 AM, Clune, Thomas L. (GSFC-6101) via J3 <j3 at mailman.j3-fortran.org> wrote:
> 
> 
> Section 15.3.1 Characteristics of procedures states that one of the characteristics is “whether it has the BIND attribute”.    
> 
> “The characteristics of a procedure are the classification of the procedure as a function or subroutine, whether it
> is pure, whether it is simple, whether it is elemental, whether it has the BIND attribute, the characteristics of its
> dummy arguments, and the characteristics of its function result if it is a function.”
>  
> Then section 15.3.2.3 Characteristics of a dummy procedure
>  
> “The characteristics of a dummy procedure are the explicitness of its interface (15.4.2), its characteristics as a
> procedure if the interface is explicit, whether it is a pointer, and whether it is optional (8.5.12, 8.6.10).”
>  
> And finally, in 15.5.2.10 Actual arguments associated with dummy procedures
>  
> “If the interface of a dummy procedure is explicit, its characteristics as a procedure (15.3.1) shall be the same as those of its effective argument, except that a pure effective argument may be associated with a dummy argument that is not pure, a simple effective argument may be associated with a dummy argument that is not simple, and an elemental intrinsic actual procedure may be associated with a dummy procedure (which cannot be elemental).”
>  
> I had expected to see another exception in 15.5.2.0 for the BIND attribute.    Is this an unintended omission?
>  
> Tom
>  
>  
>  
>  
>  
>  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.j3-fortran.org/pipermail/j3/attachments/20240422/1a585a81/attachment.htm>


More information about the J3 mailing list