From: Robert Dober Date: 2008-12-29T08:34:11+09:00 Subject: Re: Go LABEL On Thu, Dec 25, 2008 at 12:47 PM, Stefan Rusterholz wrote: > Bertram Scharpf wrote: >> Hi Xx, >> >> You should be glad not to be tempted practising this dangerous >> programming style. I did not miss the goto statement in any >> language for about twenty-five years. Be confident. >> >> Merry Christmas to all! >> >> Bertram > > I used goto to implement a parser for ISO 8601 (in C, generated by ruby) > and it is very handy for that. It's just too easy to implement a > statemachine with gotos. But besides generated code (which isn't > intended to be very readable) I do agree that goto is a bad choice. > I think it's just as bad to call a tool all-evil as to use a tool in the > wrong place. As a matter of fact gotos can make your code clearer, but that has been discovered a long time ago ;) and those gotos have been disguised into exit/break, continue, next, redo, case, throw-catch, raise-rescue. Modern languages like Ruby really have all the gotos you should wish for. I however understand that you used gotos in your C state-machine. But IIRC we were talking about Ruby-goto, right ;). Cheers Robert