PHP 4.0 Bug #8702 Updated: Nesting trim inside an empty wont parse
| From: | rasmus@php.net | Date: | Sun, 14 Jan 2001 21:37:54 +0000 |
| Subject: | PHP 4.0 Bug #8702 Updated: Nesting trim inside an empty wont parse | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-44075@lists.php.net to get a copy of this message | ||
ID: 8702
Updated by: rasmus
Reported By: bob@bravenet.com
Old-Status: Open
Status: Closed
Bug Type: Scripting Engine problem
Assigned To:
Comments:
As per the documentation empty() has no meaning for anything other than a variable. You can't
pass it an expression.
Previous Comments:
---------------------------------------------------------------------------
[2001-01-14 16:32:30] bob@bravenet.com
if ( empty(trim($str)) ) {
echo "BUG";
} else {
echo "WORKS";
}
Dont really need all the echo's since it never gets past a syntax check for the empty(trim())
part. I have to assume its a bug since logically, it shouldnt give a parser error.
Parse error: parse error, expecting
T_VARIABLE' or '$'' in
/website/main/test.php on line 2
---------------------------------------------------------------------------
Full Bug description available at: http://bugs.php.net/?id=8702