Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!killer!tness7!tness1!sugar!ssd
From: ssd@sugar.UUCP (Scott Denham)
Newsgroups: comp.lang.fortran
Subject: Re: Assigned GOTO
Summary: Safe???  It's not even sane!!!
Message-ID: <2270@sugar.UUCP>
Date: 8 Jul 88 04:26:00 GMT
References: <2742@utastro.UUCP> <20008@beta.UUCP> <224@raunvis.UUCP> <3350@s.cc.purdue.edu>
Organization: Sugar Land UNIX - Houston, TX
Lines: 24

In article <3350@s.cc.purdue.edu>, ags@s.cc.purdue.edu (Dave Seaman) writes:
 (discussion and examples of computed GOTO's deleted)
> 
> The fact that a compiler does not check the return values does not
> necessarily mean that it is safe to put in anything you like.  An
> optimizing compiler may assume (without bothering to check) that your list
> of return values is accurate and use that assumption to generate more
> efficient code.  Naturally, such code is likely to break if the
> destination of the GOTO is not in the label list.  
> 
> Dave Seaman	  					
 
 I certainly didn't mean to condone putting bogus values into the 
 list of alternate branch points. As one who derives a large portion of
 my livelyhood out of trying to mantain, debug, and extend FORTRAN code
 written be other (soimetimes LOTS of other) people, I can testify that 
 the only thing WORSE than undocumented code is MIS-documented code. No
 matter how much skepticism you view the documentation with, it tends
 to lead you to a particular mindset when trying to understand how a
 program does (or doesn't :} ) what it is supposed to do. Bogus lists
 of alternate returns from assigned GOTO's are one of the nastiest!
 (Did he REALLY tghink he could get there from here....here from there???!)
 
  Scott Denham