Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!elroy.jpl.nasa.gov!ames!dftsrv!jagubox.gsfc.nasa.gov!jim From: jim@jagubox.gsfc.nasa.gov (Jim Jagielski) Newsgroups: comp.lang.fortran Subject: Re: Is this kosher? Message-ID: <2796@dftsrv.gsfc.nasa.gov> Date: 30 Jan 91 13:57:23 GMT References: <2787@dftsrv.gsfc.nasa.gov> <20773@hydra.gatech.EDU> Sender: news@dftsrv.gsfc.nasa.gov Reply-To: jim@jagubox.gsfc.nasa.gov (Jim Jagielski) Organization: NASA/Goddard Space Flight Center Lines: 35 In article <20773@hydra.gatech.EDU> gt4512c@prism.gatech.EDU (BRADBERRY,JOHN L) writes: }In article <2787@dftsrv.gsfc.nasa.gov> jim@jagubox.gsfc.nasa.gov (Jim Jagielski) writes: }> }>Tell me, is jumping into an IF block statement legal (I know it ain't }>pretty)... for example: } }In general, this is NOT considered good programming practice and }usually leads to code that is difficult to maintain and modify. } }When faced with an urge to do something like this, take a deep }breath, get a beverage, and RE-THINK your logic. The next person }to 'fix' your code will thank you! } It ain't my code... I've seen this quite a few times on VAX machines (their FORTRAN accepts it without even a hiccup) but, of course, when porting to other machines the code dies a horrible death. Sometimes it does make sense to do this if the block you are referring back to is large... of course, in that case is better to just make it "into" a subroutine and use it as such. In any case, the 3 books I've looked through ("Fortran77" by Meissner/ Organick; "Problem Solving... Fortran 77" by Koffman/Friedman; and "Fortran77 for Engineers..." by Nyhoff/Leestma) don't mention it at all. Oh well... anyway, thanks for all the feedback! -- ======================================================================= #include =:^) Jim Jagielski NASA/GSFC, Code 711.1 jim@jagubox.gsfc.nasa.gov Greenbelt, MD 20771 "Exploding is a perfectly normal medical phenomenon. In many fields of medicine nowadays, a dose of dynamite can do a world of good."