Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:59331 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 14005 invoked from network); 2 Apr 2012 21:51:30 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 2 Apr 2012 21:51:30 -0000 Authentication-Results: pb1.pair.com header.from=sam.e.giles@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=sam.e.giles@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 74.125.83.42 as permitted sender) X-PHP-List-Original-Sender: sam.e.giles@gmail.com X-Host-Fingerprint: 74.125.83.42 mail-ee0-f42.google.com Received: from [74.125.83.42] ([74.125.83.42:56868] helo=mail-ee0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id BE/EB-43049-16F1A7F4 for ; Mon, 02 Apr 2012 17:51:30 -0400 Received: by eekb57 with SMTP id b57so889915eek.29 for ; Mon, 02 Apr 2012 14:51:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=19HoLQXTQVNQp3usXDnj/7j7xSZBqyNYtRveM2CF//A=; b=I/e339b50m0YgYcWaAb/ACQ6jxBgGHAUxqGXnYt6zWmqfUoXE+fMixS21qAltGGnsC Gcv4uw4cVLctP5IBctr8KYQpG3AlR7K2RhvVFdzKhCGH//A88/1rdzn2AF0R4TIs8v1l mixSkuhG8oEsqm/Y2Tr+VuOlqvqAEYXMetB5EJv7WViMsld3jGQlmuqlXHWAtN8hhspC l3W44AlQvzLwLMaE8XT8xtqAjhXLcRg0AGRORmokPX6MjTBDxhGg37cPKcALeI6wSroB dv3gWAp7V0YEmKv/KwcctYPksa0+zHH50QsY3VYBhupPsJ8668zGHI8QtWdzqwEYM9L1 7ZAw== MIME-Version: 1.0 Received: by 10.14.95.141 with SMTP id p13mr1646482eef.112.1333403486762; Mon, 02 Apr 2012 14:51:26 -0700 (PDT) Received: by 10.213.30.11 with HTTP; Mon, 2 Apr 2012 14:51:26 -0700 (PDT) In-Reply-To: References: Date: Mon, 2 Apr 2012 22:51:26 +0100 Message-ID: To: Anthony Ferrara Cc: Rasmus Schultz , internals@lists.php.net Content-Type: multipart/alternative; boundary=bcaec52be6c12bb79704bcb93151 Subject: Re: [PHP-DEV] resume after exception From: sam.e.giles@gmail.com (Samuel Giles) --bcaec52be6c12bb79704bcb93151 Content-Type: text/plain; charset=ISO-8859-1 Hi Anthony, Ok, I see that now. I know you're not necessarily saying what's been proposed is a good idea but I can see a benefit in pythonic style generators as a separate piece of functionality, implementing a yield function, has this ever been discussed before? My apologies if this is the case I've not seen it since I've been following this list. I know there is the SPL Iterator, but just as in the example you provided implementations *can* be verbose and convoluted. Cheers, Sam On Mon, Apr 2, 2012 at 10:34 PM, Anthony Ferrara wrote: > Sam, > > I'm not saying it's a good idea, but this would allow for pythonic > style generators. http://wiki.python.org/moin/Generators > > Just pointing out one potential use-case... > > Anthony > > On Mon, Apr 2, 2012 at 4:35 PM, Samuel Giles > wrote: > > My major concern would be, how does this* really* add to PHP? Perhaps > I'm > > missing the point, but what would this allow that can't be done in some > > form using well defined "patterns", for lack of a better word. > > > > I'm not keen on the idea of throwing things such as Interrupts either, it > > doesn't quite fit with their general use case. > > > > Sam > --bcaec52be6c12bb79704bcb93151--