Re: speaking of control structures...

From: Date: Thu, 07 May 2009 15:32:39 +0000
Subject: Re: speaking of control structures...
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-292383@lists.php.net to get a copy of this message
Robert Cummings wrote:
On Thu, 2009-05-07 at 09:33 -0400, Tom Worster wrote:
On 5/6/09 9:31 PM, "Clancy" <clancy_1@cybec.com.au> wrote:
I can understand your reluctance to disregard your mother's advice, but unfortunately she had been brainwashed to accept the dogma of the day.
actually, i don't believe so. she did numerical work so she continued using fortran and therefore gotos for the rest of her life. i think she just didn't like goto. moreover, she was never dogmatic on any topic, it wasn't in her nature. anyway, how do you know how she came by her opinions?
Because that's how most people came by their opinion of goto? How did you come by your opinion of goto? Oh yeah, your momma! Here let me open your eyes a bit... I've done a grep on the PHP 5.2.9 source code, Apache 2.2.11 source code, and MySQL 5.1.33 source code for use of goto:
    PHP 5.2.9:     http://pastebin.com/f6b88957
Apache 2.2.11: http://pastebin.com/f2c7f5d93 MySQL 5.1.33: http://pastebin.com/f4441a891 It would seem that goto has a lot of use in modern code. Just because someone tells you something, doesn't mean you should believe it at face value. Goto has many important uses in programming. The goto that was spurned is not really the goto in use today. The goto in use today generally has scope within a well defined context such as a function. Cheers, Rob.
further a switch statement pretty much is a goto (well a multiway goto), and as I mentioned couple of days ago continue is pretty much a goto as well - think its technical term is a "continuation" which is v similar to a computed go to.

« previous php.general (#292383) next »