home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!stanford.edu!agate!agate!matt
- From: matt@physics16.berkeley.edu (Matt Austern)
- Newsgroups: comp.lang.c++
- Subject: Re: GOTO, was: Tiny proposal for na
- Date: 26 Aug 92 12:24:22
- Organization: Lawrence Berkeley Laboratory (Theoretical Physics Group)
- Lines: 20
- Message-ID: <MATT.92Aug26122422@physics16.berkeley.edu>
- References: <714668024@thor> <6800007@tisdec.tis.tandy.com>
- <1992Aug26.130335.26725@hemlock.cray.com>
- Reply-To: matt@physics.berkeley.edu
- NNTP-Posting-Host: physics16.berkeley.edu
- In-reply-to: dsf@cray.com's message of 26 Aug 92 13:03:35 CDT
-
- In article <1992Aug26.130335.26725@hemlock.cray.com> dsf@cray.com (Dan Frankowski) writes:
-
- > If one-entry-one-exit is part of a structured programming, then the
- > goto is not "just another structured technique." Note that I did not
- > say gotos have no uses. (I haven't made up my mind yet. Maybe this
- > thread will help me decide. :-)
-
- The classic situation where gotos are generally believed to be useful
- is writing a finite-state machine.
-
- It seems to me that you could probably do better, though, by defining
- some abstract class State, and then deriving the actual states of the
- finite-state machine from it; this seems like it might be a more
- elegant technique. (I haven't tried this, though; I'm just
- speculating.)
- --
- Matthew Austern Just keep yelling until you attract a
- (510) 644-2618 crowd, then a constituency, a movement, a
- austern@lbl.bitnet faction, an army! If you don't have any
- matt@physics.berkeley.edu solutions, become a part of the problem!
-