|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2014-05-04 08:19 UTC] requinix@php.net
-Status: Open
+Status: Not a bug
[2014-05-04 08:19 UTC] requinix@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Wed Oct 07 22:00:01 2026 UTC |
Description: ------------ The exact PHP version is PHP 5.5.3-1ubuntu2.3 (I was unable to find this in the version list). Here is an example of the issue: if (((float)8568.2 + (float)-614) == (float)7954.2) { echo 'Match'; } else { echo 'No Match'; } The result of this comparison is always false, resulting in "No Match". The expected result is true or "Match" as 8568.2 + -614 = 7954.2 Example run via PHP HTTP Server. PHP Modules: [PHP Modules] bcmath bz2 calendar Core ctype curl date dba dom ereg exif fileinfo filter ftp gettext hash iconv intl json libxml mbstring mhash mongo mysql mysqli openssl pcntl pcre PDO pdo_mysql Phar posix readline Reflection session shmop SimpleXML soap sockets SPL standard sysvmsg sysvsem sysvshm tokenizer wddx xml xmlreader xmlwriter Zend OPcache zip zlib [Zend Modules] Zend OPcache Test script: --------------- if (((float)8568.2 + (float)-614) == (float)7954.2) { echo 'Match'; } else { echo 'No Match'; } Expected result: ---------------- echo 'Match'; Actual result: -------------- echo 'No Match';