[PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH] Allow constants / expressions to be passed by reference]

2002-05-29 Thread Andi Gutmans
I don't see any reason to allow passing non-variables by reference. It is semantically incorrect. Andi At 09:40 29/05/2002 +0200, Stig S. Bakken wrote: If this patch doesn't break anything, and it doesn't give us any difficulties with ZE2 or major design issues, I'm +1. - Stig On Tue,

RE: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH] Allow constants / expressions to be passed by reference]

2002-05-29 Thread phpsurf
To: Stig S. Bakken; Jason T. Greene Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH] Allow constants / expressions to be passed by reference] I don't see any reason to allow passing non-variables by reference. It is semantically

Re: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH] Allow constants / expressions to be passed by reference]

2002-05-29 Thread brad lafountain
I have ran into this limitation too or something like foo(); or foo($bar); function foo($bar = null) { } --- Andi Gutmans [EMAIL PROTECTED] wrote: I don't see any reason to allow passing non-variables by reference. It is semantically incorrect. Andi At 09:40 29/05/2002 +0200,

Re: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH] Allow constants / expressions to be passed by reference]

2002-05-29 Thread Sebastian Bergmann
brad lafountain wrote: function foo($bar = null) { } This has already been fixed for the Zend Engine 2: * Parameters that are passed by reference to a function may now have default values. Example: ?php function my_function($var = null) { if

Re: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH]Allow constants / expressions to be passed by reference]

2002-05-29 Thread Jason T. Greene
Andi, I do not see how this is semantically incorrect, or how it is that much different than allowing default values for pass by reference arguments. IMO The only useful reason to deny passing a constant/expression in a function is to provide a warning message. Some of the problems I outlined

[Fwd: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH] Allow constants / expressions to be passed by reference]]

2002-05-29 Thread Sebastian Bergmann
Hamster ate my mail? Resent, just in case. Sebastian Bergmann wrote: brad lafountain wrote: function foo($bar = null) { } This has already been fixed for the Zend Engine 2: * Parameters that are passed by reference to a function may now have default values. Example:

Re: [Fwd: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT][PATCH] Allow constants / expressions to be passed by reference]]

2002-05-29 Thread Jason T. Greene
Yes and as I said in my argument, this solves some of the problems but does not solve a non-rightmost parameter being optional. -Jason On Wed, 2002-05-29 at 11:43, Sebastian Bergmann wrote: Hamster ate my mail? Resent, just in case. Sebastian Bergmann wrote: brad lafountain wrote:

[PHP-DEV] Re: [Zend Engine 2] RE: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV][RESENT] [PATCH] Allow constants / expressions to be passed by reference]

2002-05-29 Thread Shane Caraveo
for params and still have them passed by reference ... -Original Message- From: Andi Gutmans [mailto:[EMAIL PROTECTED]] Sent: mercredi 29 mai 2002 17:26 To: Stig S. Bakken; Jason T. Greene Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT

Re: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH] Allow constants / expressions to be passed by reference]

2002-05-29 Thread Andi Gutmans
Okay I'll try and look at your patch in the next couple of days. It's quite sensitive code which this changes (has harmless as it might seem) so I need some time to read over it. Andi At 11:37 29/05/2002 -0500, Jason T. Greene wrote: Andi, I do not see how this is semantically incorrect, or

Re: [PHP-DEV] Re: [Zend Engine 2] Re: [PHP-DEV] [RESENT] [PATCH]Allow constants / expressions to be passed by reference]

2002-05-29 Thread Jason T. Greene
On Wed, 2002-05-29 at 13:53, Andi Gutmans wrote: Okay I'll try and look at your patch in the next couple of days. It's quite sensitive code which this changes (has harmless as it might seem) so I need some time to read over it. Thanks, I did test this very thoroughly. However, due to its