On Mon, Feb 6, 2012 at 4:07 AM, Tim Streater <t...@clothears.org.uk> wrote:

> On 06 Feb 2012 at 07:47, Adam Richardson <simples...@gmail.com> wrote:
> > While not purely focused on PHP, I toss this out to the group because I
> > believe there are some novel, interesting points regarding the potential
> > benefits of using the goto construct as implemented in PHP:
> >
> > http://adamjonrichardson.com/2012/02/06/long-live-the-goto-statement/
> Your val_nested() function looks like a straw-man to me. I've not used a
> goto since I stopped writing in FORTRAN in 1978, and not missed it [1].
> Neither do I ever have deeply nested if-then-else - these are a good source
> of bugs. I suppose the rest of your article might have been dealing with
> simplifying val_nested() but TBH I wasn't interested enough to find out.

I disagree that the nested function is a straw-man. I (just as the other
authors I'd linked to describing the "arrow" pattern of code) have seen
plenty of examples of similar code.

PHP provides a restricted implementation of the goto construct that, in my
opinion, can hold great value for developers.

Thanks for the feedback,


Nephtali:  A simple, flexible, fast, and security-focused PHP framework

Reply via email to