Bug #9356 Updated: settype thinks 0.2 and (1.2 - 1) have different values
| From: | hholzgra@php.net | Date: | Sat, 27 Oct 2001 16:10:49 +0000 |
| Subject: | Bug #9356 Updated: settype thinks 0.2 and (1.2 - 1) have different values | ||
| References: | 1 | Groups: | php.dev php.doc |
| Request: | Send a blank email to php-dev+get-69142@lists.php.net to get a copy of this message | ||
ID: 9356
Updated by: hholzgra
Reported By: phpbug01@smayw.nask.com
Old Status: Assigned
Status: Closed
Bug Type: Documentation problem
Operating System: Linux 2.2.17
PHP Version: 4.0.4pl1
Assigned To: hholzgra
New Comment:
forgot to close this after i added a warning note
to the manual some time ago
Previous Comments:
------------------------------------------------------------------------
[2001-02-21 05:17:17] hholzgra@php.net
the good old rounding problem again
... have to get what i have written about it and put it into FAQ and manual ...
------------------------------------------------------------------------
[2001-02-20 15:55:08] phpbug01@smayw.nask.com
http://www.tpsa.com/settype.php
http://www.tpsa.com/settype.phps
it has phpinfo(); in it
sniplet:
$zzz=(10*(10.2-1));
$zzztype=gettype($zzz);
echo "\$zzz = $zzz and is $zzztype<br>";
settype($zzz, "integer");
echo "after settype to integer: \$zzz = $zzz <br>";
$zz=(10*(1.2-1));
$zztype=gettype($zz);
echo "\$zz = $zz and is $zztype<br>";
settype($zz, "integer");
echo "after settype to integer: \$zz = $zz <br>";
------------------------------------------------------------------------
Edit this bug report at http://bugs.php.net/?id=9356&edit=1