Re: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_compile.c zend_compile.h zend_globals.h zend_language_parser.y /tests break_label01.phpt
break_label02.phpt break_label03.phpt break_label04.phpt break_label05.phpt break_label06.phpt break_l

From: Date: Sat, 04 Mar 2006 00:41:03 +0000
Subject: Re: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_compile.c zend_compile.h zend_globals.h zend_language_parser.y /tests break_label01.phpt
break_label02.phpt break_label03.phpt break_label04.phpt break_label05.phpt break_label06.phpt break_l
References: 1 2 3 4 5 6  Groups: php.zend-engine.cvs 
Request: Send a blank email to [email protected] to get a copy of this message
On Fri, 3 Mar 2006, Andi Gutmans wrote:

> > > >I'd have to agree with Marcus on this one.  We are making one of the
> > > >first forward compatibility breaks in the procedural language for this?
> >
> > > Sorry, I don't get it. Why do we expect this to be an endless loop?
> > > break Label just says what loop to break out of. Or am I
> > > misunderstanding the concern?
> >
> >A label is commonly used for a 'goto' point. Now, think again without the
> >stuff you had in mind while brewing the patch but instead what you are
> >used to from any other language that offers labels.
> 
> Uhm, OK I thought again. You are getting confused with goto. This isn't goto
> but saying what loop you want to break/continue. You are marking the loop with
> a label and naming it, instead of counting. I don't see what other kind of
> semantics you'd expect. If you'd change it to jump then it's goto.
> 
> If you find it too confusing, then maybe this is a good reason to roll back
> and not support labeled breaks/continues. I wasn't too enthusiastic to begin
> with but did it out of peer pressure :)

I definitely don't want *this* either... (like I stated a few times 
before). This is totally against the KISS principle and *much* more 
confusing than goto proper.

Derick


Thread (28 messages)

« previous php.zend-engine.cvs (#4660) next »