(j3.2006) (SC22WG5.4311) Executing a type-bound procedure on a coindexed object
Bill Long
longb
Wed Aug 18 20:17:09 EDT 2010
Aleksandar Donev wrote:
> On 07/30/10 12:07, Reinhold.Bader at lrz.de wrote:
>> I agree. But in this case there does appear to be an inconsistency in the
>> standard, at least with respect to what was intended (I think :-)). The
>> way out would be to either drop the additional restriction, or to prohibit
>> TBP calls on polymorphic coindexed objects altogether.
>>
> I tried to understand all the different constraints and failed. It seems
> to me the intent was to not allow any use of coindexed polymorphic
> objects beyond accessing components that are not polymorphic (i.e.,
> anything that would require looking into type tables). The note is also
> technically correct. Please remind me (sorry, my books are in boxes so
> harder to look stuff up)---does there have to be a passed argument for
> every TBP? Or can you simply use an object to do type dispatch but not
No. You can specify NOPASS for a type-bound procedure.
Cheers,
Bill
> actually pass it to the procedure? In any case it begs the question why
> the user would write x[1]%tbp instead of x%tbp when the types must
> match. Perhaps prohibiting it all together is better for now.
> Best,
> Aleks
>
--
Bill Long longb at cray.com
Fortran Technical Support & voice: 651-605-9024
Bioinformatics Software Development fax: 651-605-9142
Cray Inc./Cray Plaza, Suite 210/380 Jackson St./St. Paul, MN 55101
More information about the J3
mailing list