Re: uniqueness of {if,do,case}-construct-name



In article <nospam-03BE88.22161529042005@xxxxxxxxxxxxxxxxxx>,
Richard E Maine <nospam@xxxxxxxxxxxxx> writes:
> In article <d4uu27$pi1$1@xxxxxxxxxxxxxxxxxxxxxxx>,
> kargl@xxxxxxxxxxxxxxxxxxxxxxxxxxxx (Steven G. Kargl) wrote:
>
>> I've read through Chapter 8 of Final Committe Draft of the
>> Fortran 95 standard, and I can't find where the if-construct-name,
>> do-construct-name, and case-construct-name are required to be
>> unique. Is such a constraint mandated by the standard?
>
> It isn't a constraint, but yes. You are looking in the wrong chapter.
> Pretty much all the name uniqueness stuff is in c14.

Thanks. I'll read Ch. 14, next.

> There's a proposal to lift this restriction in the standard after f2003.
> (I don't particularly favor the proposal, but I appear to be in a
> minority on that).

I'd be interesting in your reasoning. AFAICT, the construct-name
is local to the construct. For example, a EXIT or CYCLE in the 2nd
loop of the example code that I posted will not branch to the
end of the first loop.

--
Steve
http://troutmask.apl.washington.edu/~kargl/
.



Relevant Pages

  • Re: What is this
    ... type parameters as an entity of the same in the host would have, ... an example like that in some interp. ... I have to say that constraint doesn't seem to fit well with the material ... the standard to me. ...
    (comp.lang.fortran)
  • Re: C Strings not returning from a function
    ... Constraint violation. ... I'm not so sure the standard specifies ... what the effect of the implicit declaration of mallocis. ... what violates a constraint. ...
    (comp.lang.c)
  • Re: int pointing to char
    ... >> The C standard doesn't classify constraint violations in several ... >undefined behaviors. ... violating a shall outside a constraint ...
    (comp.lang.c)
  • Re: Converting fixed-to-free format
    ... input lines could not be longer than 72 characters. ... In fact the same constraint should exist for free source ... in the standard for that case either. ... KIND-less literals ...
    (comp.lang.fortran)
  • Re: C Strings not returning from a function
    ... Constraint violation. ... I'm not so sure the standard specifies ... what the effect of the implicit declaration of mallocis. ...
    (comp.lang.c)