From rz48@rz.uni-karlsruhe.de  Wed Mar 19 10:17:06 1997
Received: from nz11.rz.uni-karlsruhe.de (nz11.rz.uni-karlsruhe.de [129.13.64.7]) by dkuug.dk (8.6.12/8.6.12) with ESMTP id KAA00584 for <sc22wg5@dkuug.dk>; Wed, 19 Mar 1997 10:15:03 +0100
Message-Id: <199703190915.KAA00584@dkuug.dk>
Received: from ry70.rz.uni-karlsruhe.de by nz11.rz.uni-karlsruhe.de with SMTP (PP); Wed, 19 Mar 1997 10:14:28 +0100
Received: by ry70.rz.uni-karlsruhe.de
	(1.37.109.16/16.2) id AA243362864; Wed, 19 Mar 1997 10:14:24 +0100
Subject: Re: N1277
In-Reply-To: <199703182258.OAA15681@eis-net-001.jpl.nasa.gov> from Van Snyder at "Mar 18, 97 02:56:54 pm"
To: vsnyder@math.Jpl.Nasa.Gov
Date: Wed, 19 Mar 1997 10:14:24 +0100 (CET)
Cc: sc22wg5@dkuug.dk
From: hennecke@rz.uni-karlsruhe.de (Michael Hennecke)
Reply-To: hennecke@rz.uni-karlsruhe.de (Michael Hennecke)
X-Mailer: ELM [version 2.4ME+ PL31 (25)]
Mime-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Content-Length: 1713      

According to Van Snyder:
> The BIND(C) attribute of a type that's intended to match to a C
> struct applies to the type, not to its components.
> 
> So, BIND(C) should be an annotation of the TYPE declaration, not a
> statement amongst the component declarations.
> 
> On page 14, your first Fortran example should be
> 
>   TYPE, BIND(C) :: point
>     INTEGER(c_int) :: x, y
>   END TYPE point
> [snip]

I thought of this. You may see it both ways. You use PRIVATE for the
components to convince me of this view.  I might use SEQUENCE (at the 
same <private-sequence-stmt>) to point out the other way: SEQUENCE also 
applies to the type, not its components. Nevertheless it is not given on
the type declaration stmt.

On the other hand, PRIVATE at the type statement concerns the <name> of
the type. And BIND(C) does not apply to the <name> (aka structure tag)
of the structure, which is local and completely arbitrary, but rather
to the contents in complete analogy to SEQUENCE.

Therefore, I decided to put BIND(C) in the <private-sequence-stmt>.
I'm not completely happy with this, but it's also not too strange...

Thanks,
Michael

 ======================================================================
  Michael Hennecke      http://www.uni-karlsruhe.de/~Michael.Hennecke/ 
 ----------------------------------------------------------------------
  University of Karlsruhe         RFC822: hennecke@rz.uni-karlsruhe.de 
  Computing Center (G20.21 R210)               No longer on BITNET :-(
  Zirkel 2  *  P.O. Box 69 80                 Phone: +49 721  608-4862 
  D-76128  Karlsruhe                               Fax: +49 721  32550 
 ======================================================================
