I'm not sure even transfer() would help with derived types. All this seems
to argue even more strongly for the "typeless" idea Richard Russell
mentioned and which Richard Maine said is being considered - a "type" that
makes no assumptions about the data and allows you to move it around and
check for equality _only_.
Arguably, it's not really typeless - it's just the most primitive (general?)
type you can think of, with no operations other than compare and assign.
Calling it "type thingie" might be even more apt :-) . How to handle
pointers inside a "thingie" derived type might be the real trick. Do you
allow them? Can they only contain have pointers to other "thingies"? Do you
say that there are two kinds of "thingies": simple "thingies" and derived
type "thingies"?
I hope the levity I'm using here doesn't make anyone think I don't take this
seriously... In fact, I think it extremely important that some means be
devised to handle what IMHO I perceive to be the underlying problem: the
almost complete inability to write _general_ data manipulation code in
Fortran 9x in such a way that we are not in conflict with the standard. This
_should_ be doable in Fortran without having to make use of C or some other
language.
Alvaro
-----Original Message-----
From: Fortran 90 List [mailto:[log in to unmask]] On Behalf Of
Russell, Richard
Sent: Thursday, March 11, 2004 7:09 AM
To: [log in to unmask]
Subject: Re: Data type "UNDEFINED"
Sooner or later, the possibility of using derived types to create structures
of data comprised of different types will be suggested. That would create a
problem of passing data to/from the data manager, which isn't suppposed to
know anything about the structure of the data being moved. I suspect also
that storage arrangement of elements of a structure is not defined by the
standard, beyond what the SEQUENCE statement does, but frankly I don't know.
RAR
-----Original Message-----
From: Fortran 90 List [mailto:[log in to unmask]]On Behalf
Of Robin
Sent: Thursday, March 11, 2004 5:20 AM
To: [log in to unmask]
Subject: Re: Data type "UNDEFINED"
> Date: Wed, 10 Mar 2004 08:22:59 -0500
> From: "Russell, Richard" <[log in to unmask]>
> No, I didn't try TRANSFER. I actually had to look it up to see what it
does,
> and it still isn't totally clear to me.
> It seems to be a "move" of sorts, and is something that was added in
Fortran 95.
>
> Perhaps someone familiar with the equivalence issue can explain why
> equivalence of character and non-character entities is not allowed in the
standard,
? particularly since doing so can be implemented
>
Maybe CHAR and ICHAR are better?
> RAR
-----------------------------------------
*****************Internet Email Confidentiality Footer******************
Privileged/Confidential Information may be contained in this message.
If you are not the addressee indicated in this message (or responsible
for delivery of the message to such person), you may not copy or deliver
this message to anyone. In such case, you should destroy this message
and notify the sender by reply email. Please advise immediately if you
or your employer do not consent to Internet email for messages of this
kind. Opinions, conclusions and other information in this message that
do not relate to the official business of The Shaw Group Inc. or its
subsidiaries shall be understood as neither given nor endorsed by it.
________________________________________________________________________
The Shaw Group Inc.
http://www.shawgrp.com
|