ID: 41951 User updated by: rachmel at avaya dot com Reported By: rachmel at avaya dot com -Status: Feedback +Status: Open Bug Type: *Math Functions Operating System: WindRiver Linux PHP Version: 5.2CVS-20070710 New Comment:
I see.. Well, can you at least give me directions? Where can I find the code responsible for parsing numbers and deciding whether to save them as int / floats? Thanks, Nir. Previous Comments: ------------------------------------------------------------------------ [2007-07-11 07:22:17] [EMAIL PROTECTED] We don't have any PPC-windriver machines off hand, so I don't thin anybody is able to help you except for yourself. ------------------------------------------------------------------------ [2007-07-10 14:38:19] rachmel at avaya dot com Hi, I tried the CVS head version you offered me in the above link. The problem is still there, and the numbers are not converted to float as expected. ------------------------------------------------------------------------ [2007-07-10 14:10:06] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows (zip): http://snaps.php.net/win32/php5.2-win32-latest.zip For Windows (installer): http://snaps.php.net/win32/php5.2-win32-installer-latest.msi ------------------------------------------------------------------------ [2007-07-10 13:54:39] rachmel at avaya dot com Description: ------------ I am cross compiling php from i686-red-hat linux plat to ppc-windriver linux plat. The problem I see, is that when trying to assign a value bigger than MAX_INT (2147483648-1), the variable gets the value of MAX_INT-1. This is not just an explicit variable issue. Just trying to 'echo' the same value results in the same problem. When compiling for my i686 platform, this problem doesn't occur. I am upgrading from php 5.1.4, and I didn't have any problems in that version. Reproduce code: --------------- <?php $a = 0x8fffffff; $b = 2415919103; var_dump($a); var_dump($b); ?> Expected result: ---------------- float(2415919103) float(2415919103) Actual result: -------------- int(2147483647) int(2147483647) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=41951&edit=1