Path: utzoo!mnetor!uunet!lll-winken!lll-tis!ames!amdahl!pyramid!voder!kontron!optilink!cramer From: cramer@optilink.UUCP (Clayton Cramer) Newsgroups: comp.lang.c Subject: Re: gotos Message-ID: <2009@optilink.UUCP> Date: 8 Apr 88 17:16:36 GMT References: <2571@cognos.UUCP>, <77200029@uiucdcsp> <1988Apr5.213343.1528@utzoo.uucp> Organization: Optilink Corporation, Petaluma, CA Lines: 22 > > Sometimes, gotos are perfectly justifiable because they vastly > > simplify and clarify you code. > > And once in a long while, there is no better way. A loooong while. > If I were running a software house, I'd be tempted to say that using > a goto -- except in fixing a program that already uses them -- means > having $50 docked from your pay. It's not *forbidden*, you understand, > it's just that you have to want it really badly! > -- > "Noalias must go. This is | Henry Spencer @ U of Toronto Zoology > non-negotiable." --DMR | {allegra,ihnp4,decvax,utai}!utzoo!henry Exactly the right approach. The last project I supervised, the engineers that worked for me would occasionally try to justify a goto. Every single time, I demonstrated that the worst they were out was an automatic variable and maybe a do...while construct -- usually the do...while loop and an appropriate automatic variable were already there. I accept the remote possibility that goto might be appropriate somewhere -- just as I accept the remote possibility that leprechauns exist, and we've just never found them. Clayton E. Cramer