Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:11613 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 99217 invoked by uid 1010); 29 Jul 2004 14:16:45 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 99099 invoked from network); 29 Jul 2004 14:16:44 -0000 Received: from unknown (HELO mail.bpservers.com.ar) (200.32.3.79) by pb1.pair.com with SMTP; 29 Jul 2004 14:16:44 -0000 Received: (qmail 25850 invoked by uid 0); 29 Jul 2004 14:16:42 -0000 Received: from unknown (HELO ?192.168.0.240?) (168.226.82.211) by 200-32-3-79.prima.net.ar with SMTP; 29 Jul 2004 14:16:42 -0000 Reply-To: lpedretti@suserver.com Organization: Axon Sistemas To: PHP Internals List Date: Thu, 29 Jul 2004 11:17:09 -0300 User-Agent: KMail/1.6.2 References: <20040729021337.73894.qmail@pb1.pair.com> In-Reply-To: <20040729021337.73894.qmail@pb1.pair.com> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Message-ID: <200407291117.09573.lpedretti@suserver.com> Subject: Re: [PHP-DEV] GOTO operator From: lpedretti@suserver.com (Leonardo Pedretti) Goto is somewhat equivalent to 'case' combined with using 'continue' in loo= ps.=20 More precisely, this 2 language constructions are the 'goto' implementation= =20 with a different name so that Dijkstra does not get back from the grave to= =20 punish us =3DD It is true that goto is a little 'off-paradigm' in OOP and truly structured= =20 languages, however, the point is this: sometimes continue and case produce= =20 code that is not so clear and small at the same time as a little well used= =20 goto. BUT goto allows non experienced or not well educated programmers to=20 begin writing horrible and totally unstructured code, and go further=20 developing bad programming habits... IMHO, would php be a more restrictive= =20 language (strongly typed, or something alike) I would be totally and=20 unconditionally on for a goto addon. However, i see the bad habits and bad= =20 code promotion as something that should be very carefully noted before=20 deciding whether to apply it or not. I hope i have added some good points to help make the consideration deeper = and=20 better =3D) Regards Leo On Wednesday 28 July 2004 23:12, Sara Golemon wrote: > I wrote up a patch for implementing gotos in php scripts a couple months > ago as an exercise in working with the Zend engine. I put it aside > assuming noone would actually want it, but Wez and Ilia convinced me to > post it for consideration: > > Description: > http://pecl.org > > Patch: > http://pecl.org/patches/opcode_goto_5.1.0.diff > > Talk amongst yourselves... > > -Sara =2D-=20 Leonardo Pedretti Axon Sistemas L=EDder de Equipo Proyecto Basalto