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=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,4b06f8f15f01a568 X-Google-Attributes: gid103376,public From: eachus@spectre.mitre.org (Robert I. Eachus) Subject: Re: Software landmines (was: Why C++ is successful) Date: 1998/08/31 Message-ID: #1/1 X-Deja-AN: 386570149 References: <6rnh8p$dno$1@nnrp1.dejanews.com> <6rs6is$6ck$1@nnrp1.dejanews.com> <6s6h4a$ha9$1@nnrp1.dejanews.com> Organization: The Mitre Corp., Bedford, MA. Newsgroups: comp.lang.ada Date: 1998-08-31T00:00:00+00:00 List-Id: In article <6s6h4a$ha9$1@nnrp1.dejanews.com> dennison@telepath.com writes: > My point exactly. Why doesn't this same logic apply to goto's vs. more > structured flow control statements? Let's not start this argument again. ;-) But there is visible bias in your question, which has to be rooted out before the answer is obvious. There are many situations in which if statements, for loops, while loops, etc., are more structured than gotos. So if you want to write a well structured program you use them. There are a few cases where the best structure uses gotos. In those cases, if you are trying to write a well structured program, you use a goto--unless you are molested by the goto gestapo. In my personnal experience, these have only occured in programs which implemented finite state machines. (And even then the main FSM loop was implemented as a loop. The gotos were to deal with special cases such as the final state.) There are rather more cases where the goto is better than the stuctures available in langauges not as rich as Ada. In those cases the best choice may be to change languages. ;-) -- Robert I. Eachus with Standard_Disclaimer; use Standard_Disclaimer; function Message (Text: in Clever_Ideas) return Better_Ideas is...