#9118 [Opn->Csd]: 3.0.18 bug - if ("INF" == "INF") {} does not equal true
| From: | hholzgra@php.net | Date: | Mon, 30 Sep 2002 23:41:00 +0000 |
| Subject: | #9118 [Opn->Csd]: 3.0.18 bug - if ("INF" == "INF") {} does not equal true | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-20824@lists.php.net to get a copy of this message | ||
ID: 9118
Updated by: hholzgra@php.net
Reported By: bcross@manlab.com
-Status: Open
+Status: Closed
Bug Type: Misbehaving function
Operating System: Debian Linux
PHP Version: 3.0.17
New Comment:
works in 4.2.3
Previous Comments:
------------------------------------------------------------------------
[2001-02-05 13:31:01] bcross@manlab.com
I encountered a strange behaviour of comparing values. I've only
encountered it with a value of "INF". The following script should cause
"INF" to be displayed in version 3.0.18 on Linux
<?php
$arr =array(
"TEST",
"INF"
);
$cnt = sizeof($arr);
for ($x=0; $x < $cnt; $x++) {
$item = $arr[$x];
if ("$item" == "$item") {
} else {
print "$item<br>\n";
}
}
?>
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=9118&edit=1