Bug #18214 Updated: REQUEST: WARNING ON ASSIGNMENT IN IF EXPRESSION
| From: | sniper@php.net | Date: | Sun, 07 Jul 2002 21:41:10 +0000 |
| Subject: | Bug #18214 Updated: REQUEST: WARNING ON ASSIGNMENT IN IF EXPRESSION | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-13428@lists.php.net to get a copy of this message | ||
ID: 18214
Updated by: sniper@php.net
Reported By: djanix@hotmail.com
Status: Bogus
Bug Type: Feature/Change Request
Operating System: any
PHP Version: 4CVS-2002-07-07
New Comment:
Not possible: if ($xx = some_function()) {} is perfectly
legal.
Previous Comments:
------------------------------------------------------------------------
[2002-07-07 17:40:16] sniper@php.net
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to
report
a bug at http://bugs.php.net/how-to-report.php
------------------------------------------------------------------------
[2002-07-07 17:38:33] djanix@hotmail.com
just a quick feature request...
how about a warning for assignment inside of an expression, like most
c compilers will generate...
" if ( $a = false ) { "
would generate a warning... if u had the warning enabled of
course....
i'm surprised it doesn't already do that...
-benjamin+
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=18214&edit=1