please comment closing of bug#35995

This is a discussion on please comment closing of bug#35995 within the PHP General forums, part of the PHP Programming Forums category; hi! before reporting a similar bug again, i would like to discuss what other users / developers think about this bug: ...


Go Back   Usenet Forums > PHP Programming Forums > PHP General

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-08-2006
Rainer Collet
 
Posts: n/a
Default please comment closing of bug#35995

hi!

before reporting a similar bug again, i would like to discuss what
other users / developers think about this bug:
http://bugs.php.net/bug.php?id=35995

function(&$test){...}
test($test = 0);

this is an extreme helpful syntax, but the above code worked in all
versions of php4 and php5 except php5.1.2. the developers say, this is
not a bug in php5.1.2, because it should have never worked in older
version, too.

ok, i understand: $test = 0 is an expression, that cannot be passed by
reference.

but why not interprete it as follows:
1. assign $test to 0
2. pass $test by reference too function test
it only depends order of execution.

i think: this bug should not be closed, but fixed, because it breaks
BC! we use this syntax widly in our company. i would change it, but
finding the locations in the source code is extreme difficult, because
you cannot find all occurences by regex.

if you understand the semantics of the above syntax the way i described
above, it is very useful!

what do you think?

thanks,
- rainer

Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 01:29 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0