Adding UNION/MAP -- Feedback and tips pls!
Russell Brennan
RussellJBrennan@gmail.com
Mon Mar 4 19:30:00 GMT 2013
>> Forgive my ignorance, what is an unchecked union? Also, what do you
>> mean by preservation of overlaid data?
> One where you can assign one member of the union and read another.
Isn't that the definition of a union? ie, all unions are unchecked?
> Er, have you seen the specification of DEC UNION? I suggest getting
> hold of a copy before implementing it! It's better to read it than
> for me to play Chinese whispers.
Let's not get snarky! Didn't you previously state that you yourself
could not find a specification? I'm going off of this:
http://wwwth.mpp.mpg.de/members/hahn/decfortman.html#359 and I think
the idea behind union/map is pretty straightforward.
>> I feel that the extension is obscure enough that people who don't
>> already use it would not choose to pick it up, unless they really
>> needed to. In that case, it would probably be a boon to them!
> I disagree. It's a loathesome feature from the point of view of software
> engineering. I want it rejected with maximum prejudice, even if other
> more civilised GNU extensions are enabled.
Perhaps from an academic standpoint unions have no place. In practice
though, they can be quite useful and imo make the developer's intent
much more clear. I find them to be a more clear construct than
equivalence, for instance. That being said, my sole interest in
adding the extension is to facilitate compilation of legacy code in
which refactoring is not going to happen. I'm sure there is plenty of
code out there besides mine that use the extension, and could benefit
from not having to purchase a closed-source compiler.
v/r
~Russell
More information about the Fortran
mailing list