From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=0.6 required=5.0 tests=BAYES_20,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,14f7200925acb579 X-Google-Attributes: gid103376,public From: Chris Morgan Subject: Re: No Go To's Forever! Date: 2000/03/23 Message-ID: <87hfdy8gio.fsf@think.mihalis.net>#1/1 X-Deja-AN: 601157317 Sender: cm@think.mihalis.net References: <38D7B41D.B3494C6A@lmco.com> <38D8E9DE.14E93706@quadruscorp.com> X-Trace: typhoon1.gnilink.net 953785174 151.202.100.10 (Wed, 22 Mar 2000 23:19:34 EST) Organization: Linux Hackers Unlimited NNTP-Posting-Date: Wed, 22 Mar 2000 23:19:34 EST Newsgroups: comp.lang.ada Date: 2000-03-23T00:00:00+00:00 List-Id: "Marin D. Condic" writes: > While I will concede that there are times when a goto might make sense, > I'll say this much: I have been writing software in Ada since the > original standard was published and it must total up to millions of > lines of code by now. Not only have I never once used the goto (except > possibly in experimental code designed to illustrate its use) but I have > never once encountered it in a fielded, working body of code. Do not ever enter HMS ImNotTellingYou. On that boat, IIRC, there are programs made from hundreds of thousands, perhaps millions of lines of Ada with a high density of gotos. They naturally express a state machine for each concurrent application process. The design says "I go into a loop, I read my input buffer and process these messages until some condition terminates the loop". The implementation makes that a function which is called with the next message. Loops that persist over several invocations of a function obviously have to be "faked" one way or another. A goto is as good as and possibly more honest than any other way. -- Chris Morgan http://mihalis.net "O gummier hum warder buffer-lore rum Enter dare enter envelopes ply"