Re: 3.0 feature request: foreac

new topic     » topic index » view thread      » older message » newer message

Kat wrote:

> Make it even easier: forget the others, and add ONE versatile and elegant 
> word: goto.

-----------------------------------------------------------------

Date:         Mon, 15 Nov 1999 18:06:48 -0500
 From:         Robert Craig <rds at ATTCANADA.NET>
Subject:      Goto

Since some people think I should come out of hiding
and voice an opinion on language design proposals,
here's my current thinking about "goto".

1. completely general goto, including jumps
    between routines: 0% chance

2. goto within a routine: 0.01% chance

3. specialized goto to break out of nested loops: 1% chance

I'm not religiously opposed to goto's. There are some
goto's coded into the C source of the interpreter, and
at one point in the early days I even had one of the
"between routines" gotos that are possible in C using
setjmp()/longjmp(). It proved to be nightmarishly hard
to understand and maintain so I took it out.

I agree that a specialized goto (or special "exit")
to get out of a nested loop is probably less clumsy
than setting up artificial state variables. I just don't think
that this occurs often enough, or causes enough pain
to warrant a new language feature, such as labelled
statements and a special kind of exit.

The normal sort of gotos, that let you jump around within
a routine are like cigarettes. One or two, once in a while,
will not harm you. The trouble is they become addictive.
If you never start using them, you will never have a craving
for one.

When I had to maintain code written by someone
else, the sight of a heavily goto'd section of code would
really be discouraging. The guy who wrote the goto's
probably had some idea of what the control-flow was
supposed to be, but I had to struggle to get the
same picture into my head. Standard control-flow
statements, like for..end for, if-elsif-else etc are much
easier to digest and reason about.

Regards,
     Rob Craig
     Rapid Deployment Software
     http://www.RapidEuphoria.com

---------------------------------------------------------------

Date: 8 Feb 2002
 From: Robert Craig <rds at RapidEuphoria.com>
Subject: Re: goto...
  by inmta006.topica.com with SMTP; 9 Feb 2002 05:47:30 -0000
          (InterMail vM.4.01.03.16 201-229-121-116-20010115) with SMTP
          id <20020209054729.TXNH9253.tomts20-srv.bellnexxia.net@Rob>
          for <EUforum at topica.com>; Sat, 9 Feb 2002 00:47:29 -0500
	charset="iso-8859-1"

Euler German writes:
> Though I'd love to here a word or two from Rob. 
> Hello Rob! Your time now!

I've stated many times in the past that I am
firmly opposed to adding a goto statement.
You'd have to pay me a million dollars. 
(real U.S. dollars, not 62 cent Canadian dollars)

Regards,
   Rob Craig
   Rapid Deployment Software
   http://www.RapidEuphoria.com


Well there you go Kat, your your NEVER going to get a goto statement from RDS,
unless ofcourse you were willing to pay a huge sum of money for it. If you want
it so bad, but rather not use a slow modified interpreter, "goto" another
language that has it (like me: Java, C#, PB).

Your 224 messages spanning 6 years pestering Robert for the goto statement and
labels, has NOT and NEVER will change his strong opposition against them, period.


Regards,
Vincent

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu