Bug #633: PHP compares arrays wrongly
| From: | mlemos at acm dot org | Date: | Wed, 09 Sep 1998 02:56:32 +0000 |
| Subject: | Bug #633: PHP compares arrays wrongly | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-19@lists.php.net to get a copy of this message | ||
From: mlemos@acm.org
Operating system: Amiga OS
PHP version: 3.0 Final Release
PHP Bug Type: Parser error
Bug description:
It seems that PHP either is not ready to compare arrays or
it just compares different arrays wrongly saying they are
equal.
Just try this:
<?
$array_1=array("1");
$array_2=array("2");
if($array_1!=$array_2)
echo "Different\n";
else
echo "Equal\n";
?>
If PHP is not ready to compare arrays or objects for the matter, it should
issue an error or a warning at least when you have error reporting set to
15.