[J3] Assumed-type dummy argument descriptor

Damian Rouson rouson at lbl.gov
Fri Apr 7 14:26:57 UTC 2023


Thanks, Malcolm.   Has an interp been submitted on the question of whether
the descriptor describes the actual or dummy argument?   Is this something
that will be discussed at the June meeting?

Damian

On Thu, Apr 6, 2023 at 23:20 Malcolm Cohen via J3 <j3 at mailman.j3-fortran.org>
wrote:

> Hi Damien,
>
>
>
> Unlimited polymorphic is not just TYPE(*) but also CLASS(*).
>
> C709 is about TYPE(*) only.
>
> CLASS(*) is quite often ALLOCATABLE.
>
>
>
> Cheers,
>
> --
>
> ..............Malcolm Cohen, NAG Oxford/Tokyo.
>
>
>
> *From:* J3 <j3-bounces at mailman.j3-fortran.org> *On Behalf Of *Damian
> Rouson via J3
> *Sent:* Friday, April 7, 2023 1:59 PM
> *To:* fortran standards email list for J3 <j3 at mailman.j3-fortran.org>
> *Cc:* Damian Rouson <rouson at lbl.gov>
> *Subject:* [J3] Assumed-type dummy argument descriptor
>
>
>
> Clause 16.9.284 of the Fortran 2018 standard defines the STORAGE_SIZE()
> intrinsic function.  In describing the function's one non-optional
> argument, the standard states, "If it is unlimited polymorphic or has any deferred
> type parameters, it shall not be an unallocated allocatable variable or a
> disassociated or undefined pointer."  Constraint C709 stipulates "An
> assumed-type entity shall be a dummy data object that does not have the
> ALLOCATABLE, CODIMMENSION, INTENT (OUT), POINTER, or VALUE attribute and
> is not an explicit-shape array."
>
>
>
> Given that an assumed-type dummy data object cannot have the ALLOCATABLE
> attribute, it seems that STORAGE_SIZE() definition must be referring to the
> actual argument. What would be the point in stipulating that an unlimited
> polymorphic data object shall not be an unallocated allocatable variable if
> it can't have the allocatable attribute?    I think this suggests that the
> CFI_cdesc_t descriptor describes the actual argument associated with an
> unlimited polymorphic dummy argument.  I know there was a related debate at
> the most recent J3 meeting, but I don't know the outcome.
>
>
>
> Damian
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.j3-fortran.org/pipermail/j3/attachments/20230407/142ac684/attachment.htm>


More information about the J3 mailing list