(j3.2006) Generic interface question
Malcolm Cohen
malcolm
Tue Mar 8 19:49:24 EST 2011
Van Snyder asserted:
> The interface bodies for SA and SB are global
>entities (according to 16.2p1).
No, they are not. Not according to 16.2, not according to any text in the
standard. Interface bodies are a piece of syntax.
> They have the same binding label (a
>global identifier according to 16.2p1).
Interface bodies don't have binding labels. Procedures, variables and common
blocks can have binding labels.
Interface bodies are not "entities of the program". They are syntax in the
Fortran source text. That's not an entity of the program any more than my
breakfast.
Your example has two local names for the same procedure. That's not unusual -
we've had that via use association since F90 and via argument association since
F66 (admittedly the latter is a bit of a stretch!).
Aleks Donev:
>complained loudly
Yes we heard you. And it seems to have been fixed. I hope that was deliberate!
Though it's Yet Another Feature that is, unless I missed it, not listed in the
Introduction, so maybe another interp really is in order (to get the
Introduction fixed). Sigh. Attempting to list all the new features in the
Introduction was a good idea, but we don't seem to have made a very good job of
it. Perhaps we'll do better next time.
I note that under the conjecture that interface bodies are global entities,
binding labels are the least of our worries - one would not be able to have an
interface body for any external procedure since it and the external procedure
would be two entities with the same global identifier. Fortunately, the
supposition that a piece of syntax in the source code is an entity of the
program is unfounded. It ***describes*** an entity (indeed, declares it), and
that entity is the procedure so described.
Cheers,
--
................................Malcolm Cohen, Nihon NAG, Tokyo.
More information about the J3
mailing list