From owner-sc22wg5@open-std.org  Wed Jul 28 18:00:26 2010
Return-Path: <owner-sc22wg5@open-std.org>
X-Original-To: sc22wg5-dom8
Delivered-To: sc22wg5-dom8@www2.open-std.org
Received: by www2.open-std.org (Postfix, from userid 521)
	id 3E847C3BA06; Wed, 28 Jul 2010 18:00:26 +0200 (CEST)
X-Original-To: sc22wg5@open-std.org
Delivered-To: sc22wg5@open-std.org
X-Greylist: delayed 451 seconds by postgrey-1.18 at www2.open-std.org; Wed, 28 Jul 2010 18:00:23 CEST
Received: from mail-vw0-f47.google.com (mail-vw0-f47.google.com [209.85.212.47])
	by www2.open-std.org (Postfix) with ESMTP id 9A07CC3BA01
	for <sc22wg5@open-std.org>; Wed, 28 Jul 2010 18:00:23 +0200 (CEST)
Received: by vws13 with SMTP id 13so5631091vws.34
        for <sc22wg5@open-std.org>; Wed, 28 Jul 2010 09:00:22 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:received:received:message-id:date:from
         :user-agent:mime-version:to:subject:references:in-reply-to
         :content-type:content-transfer-encoding;
        bh=H8drlakn96s92nHENSelZ0WP+tHbNCorA/7eFC5YRDY=;
        b=uMxTOBJ6xaoUj4xgoDhLrfVUQ4EM+5L3ktoYc0wVowVz3xjwE74sZzJG+o0Rhx8kiZ
         ZaXFNuQyuxuS+RYMfj+iktMGGYMZ31kGXYitXz25SPcLfbiAMBZV53cHNBmgVyroALui
         3L89d4dOYSCWxmmvFmQl84ZUJ71HeXJW9J12w=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=message-id:date:from:user-agent:mime-version:to:subject:references
         :in-reply-to:content-type:content-transfer-encoding;
        b=DgRPPrcBtisCzbaIIeQ2LVrtlhmgGFophlOZYEEevaLWManeQi+U4ZU/MfkN/qxSg6
         l4aPPQIc+IR+G9yi0t+0LIcmMFt3U6LhiQ+8Ls58f19zgWkm/TUG12Ndn8OUNhCCFTHR
         W4k9Oz8rkXTNSwNm4PCahLpCLBEenU5NIB1KE=
Received: by 10.220.128.138 with SMTP id k10mr6264037vcs.116.1280332369018;
        Wed, 28 Jul 2010 08:52:49 -0700 (PDT)
Received: from [192.168.1.3] (ucomdsl-209-203-174-15.ucom.net [209.203.174.15])
        by mx.google.com with ESMTPS id y25sm4589006vbw.16.2010.07.28.08.52.47
        (version=SSLv3 cipher=RC4-MD5);
        Wed, 28 Jul 2010 08:52:48 -0700 (PDT)
Message-ID: <4C50524F.5010502@courant.nyu.edu>
Date: Wed, 28 Jul 2010 08:52:47 -0700
From: Aleksandar Donev <aleks.donev@gmail.com>
User-Agent: Thunderbird 2.0.0.24 (Windows/20100228)
MIME-Version: 1.0
To: sc22wg5@open-std.org
Subject: Re: (j3.2006) (SC22WG5.4302) Executing a type-bound procedure on
 a	coindexed object
References: <20100725204840.C4C81C178E6@www2.open-std.org>
In-Reply-To: <20100725204840.C4C81C178E6@www2.open-std.org>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Sender: owner-sc22wg5@open-std.org
Precedence: bulk

Reinhold.Bader@lrz.de wrote:

> NOTE 12.16 of the draft 2008 standard appears to imply that a type-bound
> procedure may be invoked on a polymorphic coindexed object:
> 
> "When resolving type-bound procedure references, constraints on the use of
> coindexed objects ensure that
> the coindexed object (on the remote image) has the same dynamic type as
> the corresponding object on the
> local image. Thus a processor can resolve the type-bound procedure using
> the coarray variable on its own
> image and pass the coindexed object as the actual argument."
> 
> However, according to 12.5.2.4, para 2:
> 
> "The dummy argument shall be type compatible with the actual argument. If
> the actual argument is a polymorphic
> coindexed object, the dummy argument shall not be polymorphic."
> 
> Considering that the passed argument dummy is required to be polymorphic
> (at least in case the type is extensible), this restriction appears to
> contradict the implication of the NOTE.
I am on the road and do not have the resources (including the standard)
for a careful study, so I am speaking from memory and intuition about
what we intended. I believe the above prohibition was put there because
of the need to copy unknown stuff (e.g., added components) from a remote
object into a local copy. I recall Jim (IBM) complained about this as it
requires some nontrivial work to also keep dynamic tables in sync across
images or some such. So it is possible we added the restriction a while
after the note. Perhaps John or Bill can be of more help in digging some
history out.
Interesting question though!
Aleks


-- 
Aleksandar Donev
Assistant Professor of Mathematics
Courant Institute of Mathematical Sciences, New York University
E-mail: donev@courant.nyu.edu
Phone: (510) 910-0891
Address: 251 Mercer St, New York, NY 10012
Web: http://cims.nyu.edu/~donev/

