(j3.2006) (SC22WG5.5646) [ukfortran] Another comment on Corrigendum 4

Van Snyder Van.Snyder
Fri Jan 22 16:03:07 EST 2016

On Fri, 2016-01-22 at 16:41 +0900, Cohen Malcolm wrote:
> (1) No, subobject does not work, for exactly the same reason that we just 
> added "potential subobject component".

We added "potential subobject component" because the definitions of
ultimate component, subcomponent, and direct component stop at
allocatable, not because "subobject" didn't work for objects.  We used
"potential subobject component" in connection with LOCK_TYPE and
EVENT_TYPE because "subobject" clearly applies to objects, not types,
and therefore could not be used in those cases.

The definition of "subobject" does not stop at allocatable, either in
1.3.44 or 6.4.2p5; rather (in connection with components in 6.4.2p5) it
stops at pointer, just as does "potential subobject component."  A dummy
argument is an object, not a type, so "subobject" ought to work.

> (2) "potential subobject component" applies to objects as well as types. 
> Just look at the definition - no limitation to types is implied inferred or 
> stated.  Objects as well as types have components, and thus have potential 
> subobject components.

I thought 4.5.1p5 was the definition.  Is the summary of it in
the complete and correct definition?

I don't object to using potential subobject component, but it seems that
subobject would work.

We could write a precise and complete definition of "subobject" that
would be a bit more informative than 1.3.44:

o  element or section of an array
o  substring of a character
o  real or imaginary part of a data object of complex type
o  component or subobject of a nonpointer object or subobject

Leave the last sentence of 6.4.2p5 where it is, since it pertains only
to the syntax of <data-ref>.

> Cheers,
> -----Original Message----- 
> From: Van Snyder
> Sent: Friday, January 22, 2016 4:15 PM
> To: j3 at mailman.j3-fortran.org
> Subject: Re: (j3.2006) (SC22WG5.5646) [ukfortran] Another comment on 
> Corrigendum 4
> On Fri, 2016-01-22 at 13:45 +0900, Cohen Malcolm wrote:
> > Thinking further about Van's example, it would seem that in
> >
> > >  C1278a An INTENT(OUT) dummy argument of a pure procedure shall not be
> > >         polymorphic or have a polymorphic allocatable ultimate 
> > > component.
> >
> > what we need instead of "ultimate component" is our new term "potential
> > subobject component".
> "potential subobject component" applies to types, not objects, so we
> need "shall not be polymorphic with a declared (dynamic?) type that has
> a polymorphic allocatable potential subobject component" or something
> like that.
> Would "subobject" work instead of "ultimate component"?  "subcomponent"
> doesn't work.
> > Cheers,
> _______________________________________________
> J3 mailing list
> J3 at mailman.j3-fortran.org
> http://mailman.j3-fortran.org/mailman/listinfo/j3
> ________________________________________________________________________
> This e-mail has been scanned for all viruses by Star.
> ________________________________________________________________________

More information about the J3 mailing list