From owner-sc22wg5@open-std.org  Mon Dec  8 19:25:10 2008
Return-Path: <owner-sc22wg5@open-std.org>
X-Original-To: sc22wg5-dom7
Delivered-To: sc22wg5-dom7@www2.open-std.org
Received: by www2.open-std.org (Postfix, from userid 521)
	id BA3CEC178E5; Mon,  8 Dec 2008 19:25:10 +0100 (CET)
X-Original-To: sc22wg5@open-std.org
Delivered-To: sc22wg5@open-std.org
Received: from nspiron-1.llnl.gov (nspiron-1.llnl.gov [128.115.41.81])
	by www2.open-std.org (Postfix) with ESMTP id C5559C178E4
	for <sc22wg5@open-std.org>; Mon,  8 Dec 2008 19:25:08 +0100 (CET)
X-Attachments: None
Received: from cyrus2.llnl.gov ([128.15.97.105])
  by nspiron-1.llnl.gov with ESMTP; 08 Dec 2008 10:25:07 -0800
From: Aleksandar Donev <donev1@llnl.gov>
Organization: LLNL
Subject: Re: (j3.2006) (SC22WG5.3751) Response on the TR29113 draft N1761
Date: Mon, 8 Dec 2008 10:25:07 -0800
User-Agent: KMail/1.9.4
Cc: WG5 <sc22wg5@open-std.org>
References: <20081207203535.92039C178D6@www2.open-std.org> <493D5649.3000706@cray.com>
In-Reply-To: <493D5649.3000706@cray.com>
MIME-Version: 1.0
Content-Type: text/plain;
  charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline
To: Undisclosed.Recipients: ;
Message-Id: <200812081025.07349.donev1@llnl.gov>
Sender: owner-sc22wg5@open-std.org
Precedence: bulk

On Monday 08 December 2008 09:15, Bill Long wrote:
>  Issue 6 - referencing or defining assumed rank entities:
> =A0 =A0 =A0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> =A0 =A0 =A0We need some rules to deal with this.
>
> There are rules currently - basically that the only thing allowed on
> the Fortran side is to pass an assumed-rank dummy as an actual
> argument to another procedure. Are you saying that the scope of the
> TR needs to be expanded to specify ways for things like this to be
> used in Fortran?
Reinhold suggested a SELECT RANK construct. It does seem reasonable and=20
not hard for either vendors or the standard, and it is safe to use.

However, note that for TYPE(*) it is hard to do anything, since there is=20
no type descriptor passed like for CLASS(*) [so no TYPE SELECT for such=20
arguments]. So what do you do with a "TYPE(*), DIMENSION(..)" argument=20
inside a SELECT RANK? It will have a rank but not a declared type. Can=20
the standard even be parsed to figure out what one can do with such a=20
thing? We wanted to play it safe for now and simply say nothing is=20
allowed, except calls to certain intrinsics.

But, again, Reinhold's suggestion seems OK to me if it is deemed useful.

Best,
Aleks

=2D-=20
Aleksandar Donev, Ph.D.
Lawrence Postdoctoral Fellow @ Lawrence Livermore National Laboratory
High Performance Computational Materials Science and Chemistry
E-mail: donev1@llnl.gov
Phone: (925) 424-6816  Fax: (925) 423-0785
Address: P.O.Box 808, L-367, Livermore, CA 94551-9900
Web: http://cherrypit.princeton.edu/donev
