Re: Need Help: compiling old Fortran program



Förster vom Silberwald <chain_lube@xxxxxxxxxxx> wrote:

F90 accepts it:
....
"./preprces.f", Line = 585, Column = 36: WARNING: Transfer of control
into the DO loop starting at line 587 is not safe.

Just because it accepts the code does *NOT* mean it compiles it
correctly. The earlier comments about outputting random numbers come to
mind. From this message, I would conclude that the compiler is
interpreting this like the extended range of a DO, even though that's
not what it is. It is clear to the human reader (me) that this is not
the intent of the code. In particular, theintent is to bypass the loop
rather than to transfer control into it.

I repeat the previous advice... but I think I'm about done with
repeating it in this case. If you won't listen to it, then I guess I
can't help you. If you want this code to work, you need to fix it
instead of looking for compiler options to make it compile. Suggested
fixes have been shown before.

--
Richard Maine | Good judgement comes from experience;
email: last name at domain . net | experience comes from bad judgement.
domain: summertriangle | -- Mark Twain
.



Relevant Pages

  • Re: Letter to US Sen. Byron Dorgan re unpaid overtime
    ... >> both less efficient and less safe than the Fortran and Basic standard. ... >> The C for loop is actually trying to do what a do loop does. ... sloppy thinking that results from confusing a programming language ... > I do not believe that you are capable of writing a conforming C compiler. ...
    (comp.programming)
  • Re: Letter to US Sen. Byron Dorgan re unpaid overtime
    ... it's a for loop in the C sense. ... > sloppy thinking that results from confusing a programming language ... >> I do not believe that you are capable of writing a conforming C compiler. ... Does Microsoft's C compiler perform this optimisation? ...
    (comp.programming)
  • Re: Histogram of character frequencies
    ... generated object code may simply be a loop in which elements are ... believe any C compiler anywhere would reject it. ... On the first iteration of the loop you test the end of file indicator ...
    (comp.lang.c)
  • Re: Fridays the thirteenth. (And a little puzzle.)
    ... -- compiler) is the usual method ... int febdays ... -- We're going to go round a loop dealing with each year in turn. ... -- other languages call) ...
    (uk.people.silversurfers)
  • Re: Interesting article by Randall Hyde
    ... >>> a test before executing the loop. ... is a compiler writer forced to ... And another thing you might consider is that compiler optimization was ... Then the programmer will have to protect the execution of that loop. ...
    (comp.lang.asm.x86)