From: bobduff@world.std.com (Robert A Duff)
Subject: Re: GOTO considered necessary (reworked)
Date: 1997/06/21
Date: 1997-06-21T00:00:00+00:00 [thread overview]
Message-ID: <EC3uEA.MAE@world.std.com> (raw)
In-Reply-To: dewar.866851293@merv
In article <dewar.866851293@merv>, Robert Dewar <dewar@merv.cs.nyu.edu> wrote:
>Bob Duff said
>
><<In my experience, a hand-coded lexical analyzer is always better done
>with loops and ifs and case statements, rather than as above. That is,
>forget that it's a FSM, and just write it in the natural way. ("An
>identifier is a letter, followed by a sequence of zero or more letters
>and digits" translates quite nicely into loops, not gotos.) I know you
>agree, since I've seen the GNAT lexer.>>
>
>You may have seen it, but you have not read it all, it has a number of
>gotos of the FSM type in it. Of course it is not full of this, because
>FSM's don't have much to do with lexical analyzers except in unusual cases.
I've read it all. It has very few gotos (and those, I didn't object
to). Mostly, it's made of loop/if/case. It certainly doesn't fit into
the pattern envisioned in this thread about FSM's, where every state
starts with a label, and every state "goto"s the next state.
- Bob
next prev parent reply other threads:[~1997-06-21 0:00 UTC|newest]
Thread overview: 63+ messages / expand[flat|nested] mbox.gz Atom feed top
1997-06-11 0:00 GOTO considered necessary (reworked) Samuel Mize
1997-06-11 0:00 ` Bryce Bardin
1997-06-12 0:00 ` Anonymous
1997-06-12 0:00 ` John G. Volan
1997-06-16 0:00 ` Anonymous
1997-06-12 0:00 ` Robert Dewar
1997-06-12 0:00 ` John G. Volan
1997-06-13 0:00 ` Robert A Duff
1997-06-16 0:00 ` John G. Volan
1997-06-17 0:00 ` Robert Dewar
1997-06-17 0:00 ` Robert A Duff
1997-06-18 0:00 ` Spam Hater
1997-06-20 0:00 ` Robert Dewar
1997-06-21 0:00 ` Robert A Duff [this message]
1997-06-21 0:00 ` Robert Dewar
1997-06-20 0:00 ` Robert Dewar
1997-06-25 0:00 ` Wolfgang Gellerich
1997-06-25 0:00 ` Michael F Brenner
1997-06-26 0:00 ` Wolfgang Gellerich
1997-06-25 0:00 ` Samuel T. Harris
1997-06-19 0:00 ` Karel Th�nissen
1997-06-19 0:00 ` Karel Th�nissen
1997-06-23 0:00 ` John G. Volan
1997-06-23 0:00 ` Robert Dewar
1997-06-24 0:00 ` Brian Rogoff
1997-06-25 0:00 ` Featuritis not always bad (was re: GOTO considered necessary) Karel Th�nissen
1997-06-26 0:00 ` Robert Dewar
1997-06-26 0:00 ` Karel Th�nissen
1997-06-23 0:00 ` GOTO considered necessary (reworked) Spam Hater
1997-06-25 0:00 ` Karel Th�nissen
1997-06-23 0:00 ` John G. Volan
1997-06-17 0:00 ` Robert I. Eachus
1997-06-17 0:00 ` Robert A Duff
1997-06-25 0:00 ` Van Snyder
1997-07-21 0:00 ` Shmuel (Seymour J.) Metz
1997-06-12 0:00 ` Michael F Brenner
1997-06-17 0:00 ` Robert Dewar
1997-06-17 0:00 ` Robert A Duff
1997-06-20 0:00 ` Robert Dewar
1997-06-21 0:00 ` Robert A Duff
1997-06-21 0:00 ` Robert Dewar
1997-06-13 0:00 ` Robert A Duff
1997-06-14 0:00 ` Samuel Mize
1997-06-14 0:00 ` Matthew Heaney
1997-06-14 0:00 ` Samuel Mize
1997-06-14 0:00 ` Robert Dewar
1997-06-16 0:00 ` Robert A Duff
1997-06-17 0:00 ` Spam Hater
1997-06-17 0:00 ` Robert A Duff
1997-06-19 0:00 ` Spam Hater
1997-06-17 0:00 ` Robert Dewar
1997-06-17 0:00 ` Spam Hater
1997-06-17 0:00 ` Robert A Duff
1997-06-19 0:00 ` John Herro
1997-06-25 0:00 ` Function result Van Snyder
1997-06-27 0:00 ` Robert Dewar
1997-06-27 0:00 ` Jon S Anthony
1997-06-20 0:00 ` GOTO considered necessary (reworked) Robert Dewar
1997-06-16 0:00 ` Spam Hater
1997-06-17 0:00 ` Robert Dewar
1997-06-17 0:00 ` Spam Hater
1997-06-16 0:00 ` Anonymous
1997-06-16 0:00 ` Robert Dewar
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox