Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!bloom-beacon!gatech!rutgers!bellcore!tness7!tness1!sugar!ssd From: ssd@sugar.UUCP (Scott Denham) Newsgroups: comp.lang.fortran Subject: Re: Assigned GOTO Summary: Another use for assigned GOTO Message-ID: <2261@sugar.UUCP> Date: 6 Jul 88 22:26:58 GMT References: <2742@utastro.UUCP> <20008@beta.UUCP> <224@raunvis.UUCP> <12215@mimsy.UUCP> Organization: Sugar Land UNIX - Houston, TX Lines: 29 In article <12215@mimsy.UUCP>, chris@mimsy.UUCP (Chris Torek) writes: > I am confident that I could convert any assigned GOTO FORTRAN code into > something more reasonable, but I am curious: what do people actually > use it for? { one example of such use deleted} > In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163) One of the few helpful uses I've made of assigned GOTO is to implement a form of internal procedures - for small chunks of code that can't be handled as statement function definitions but need access to too much stuff to make a reasonable subroutine out of it. (Subroutine calls also break optimization pretty badly on IBM, or did at one time). Such use might look something like ASSIGN 1400 TO R1 GOTO 10020 1400 CONTINUE ....... 10200 FOO = FOO ** 2 ....... GOTO R1 (1400,1500,1600,1700) Unfortunately, IBM's compiler does no checking whatsoever of the possible return values - at one time they didn't even have to be valid labels!! This can lead to some rather misleading documention. Are other compilers as loose with the defintions ??? Scott Denham Western Atlas International