Re: [PHP-DEV] PHP as a template language

2012-04-05 Thread Philip Olson
On Apr 5, 2012, at 8:22 PM, Rasmus Lerdorf wrote: > On 04/05/2012 07:55 PM, Sébatien Durand wrote: >> IMHO, PHP is a great template language. This is what makes it so simple >> and powerful, compared to other web languages. >> >> So far, we have "> >> A suggestion : deprecate these old tags an

Re: [PHP-DEV] PHP as a template language

2012-04-05 Thread Rasmus Lerdorf
On 04/05/2012 07:55 PM, Sébatien Durand wrote: > IMHO, PHP is a great template language. This is what makes it so simple > and powerful, compared to other web languages. > > So far, we have " > A suggestion : deprecate these old tags and replace them with a more > elegant and a shorter implemen

[PHP-DEV] PHP as a template language

2012-04-05 Thread Sébatien Durand
IMHO, PHP is a great template language. This is what makes it so simple and powerful, compared to other web languages. So far, we have "http://www.php.net/unsub.php

Re: [PHP-DEV] resume after exception

2012-04-05 Thread Galen Wright-Watson
On Thu, Apr 5, 2012 at 4:47 PM, Stas Malyshev wrote: > > However, in general, thinking about more complex flow control structures > in fine. Just there's no reason to get exceptions mixed into it. > > Agreed. While restarting and resuming after exceptions could be useful, and a condition signaling

Re: [PHP-DEV] resume after exception

2012-04-05 Thread Stas Malyshev
Hi! >> While exceptions themselves may not be suitable for a general-purpose > control structure, they do embody one. It's an early-return mechanism that > you also see in some of the other control structures mentioned in this > thread (Python's generators, Common LISP's conditions). Even the "ret

Re: [PHP-DEV] resume after exception

2012-04-05 Thread Galen Wright-Watson
2012/4/5 Stas Malyshev > Hi! > > >> it's a wonderful mechanism with more uses than simply reporting errors > >> - the aspect of transferring control is what I find really interesting > >> about exceptions. > > Exceptions should not be used for flow control. [...] > > While exceptions themselves m

[PHP-DEV] Access by siblings of (abstract) protected methods

2012-04-05 Thread Galen Wright-Watson
Last month, Ahmad Farouk asked a question on StackOverflow about siblings accessing protected methods ( http://stackoverflow.com/q/9425770/90527) in PHP (I've been using 5.3.8 on OS X; others haven't mentioned which versions they've tested). He was surpris

Re: [PHP-DEV] resume after exception

2012-04-05 Thread Stas Malyshev
Hi! >> it's a wonderful mechanism with more uses than simply reporting errors >> - the aspect of transferring control is what I find really interesting >> about exceptions. Exceptions should not be used for flow control. They are called "exceptions" for a reason - to signify that something unusua

Re: [PHP-DEV] Re: 回复: [PHP-DEV] resume after exception

2012-04-05 Thread Anthony Ferrara
Rasmus, What would that give you that a continuation passing paradigm wouldn't? Why not tell the code what to call before you call it, rather than bubbling up the stack (which then forces a fork of the stack, as you need to partially unwind it, but keep track of what you unwound for the resume).

[PHP-DEV] Re: 回复: [PHP-DEV] resume after exception

2012-04-05 Thread Rasmus Schultz
interesting, but this doesn't have anything in particular to do with what I was talking about. to the best of my understanding, an exception transfers control back to the nearest calling code that has declared it is ready/willing/able to resume control in the event that, somewhere up the call-stac

[PHP-DEV] Threading issues with internal classes

2012-04-05 Thread Johannes Schlüter
Dmitry, while looking at #55334 I discovered two issues regarding the handling of properties and constants in threaded environments which might cause race conditions. The reproduce code for both issues is as simple as and then hit it on a 8+ core box in threaded mode. (using less cores crashes