(j3.2006) Questions about passed-object dummy argument

Van Snyder van.snyder
Thu Dec 1 04:18:27 EST 2016


On Thu, 2016-12-01 at 16:04 +0900, Cohen Malcolm wrote:
> I strongly disagree.  Your suggested change is not acceptable, indeed it 
> opens a new can of worms we decided not to open; that is, it contains a new 
> technical feature that is undesirable.

I don't understand the can of worms, or how clarifying a constraint so
that one doesn't need to refer to one eight clauses distant from it to
understand it, contains a new feature.

Is the problem in the proposed rewording caused by replacing "have the
PASS attribute" with "have a passed-object dummy argument?"  Is the new
feature that the existing constraint actually required PASS to appear in
the binding declaration, while the proposed revision allows the binding
to get a passed object without specifying it explicitly?

What's obvious to Malcolm because he works with this all day every day
sometimes needs explanation.

> Furthermore, that the procedure is necessarily elemental is not the point of 
> this constraint.  That the object must be passed to the type-bound procedure 
> is the point.

If C1536 doesn't remind the reader that the procedure is necessarily
elemental, one must use C761 to prove that either it must necessarily be
so, or that C1536 and C761 contradict each other.  I think we need a
good reason to preserve that obfuscation.  I don't see how stating the
conclusion of reasoning that requires bringing together facts from two
clauses separated by hundreds of pages introduces a problem.  I need to
be convinced that it introduces a problem.  A reason for the problem
would be more helpful than a simple assertion of it.

> There is no theorom-proving going on here.  One constraint is quite properly 
> talking about procedure invocation.  The other is talking about 
> passed-object dummy arguments.
> 
> Cheers,
> 
> -----Original Message----- 
> From: Van Snyder
> Sent: Thursday, December 1, 2016 3:46 PM
> To: j3 at mailman.j3-fortran.org
> Subject: Re: (j3.2006) Questions about passed-object dummy argument
> 
> On Thu, 2016-12-01 at 15:31 +0900, Cohen Malcolm wrote:
> > > But the
> > >constraint is the other way around, and doesn't mention elementality.
> >
> > It does not need to.  The constraint has that effect.
> 
> Sure.  But working out that C1536 implies that the invoked procedure is
> necessarily elemental requires proving a theorem involving C761, which
> is eight clauses distant.  It would be clearer to say so.  I'd prefer
> something like
> 
> C1536 If the invoked procedure is elemental and the <data-ref> is an
>       array, the binding shall have a passed-object dummy argument.
> 
> This also more explicitly allows the case of the binding getting a
> passed-object dummy argument without either PASS or NOPASS appearing,
> which isn't obvious from the current wording.
> 
> 
> _______________________________________________
> 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