Re: [PHP-DEV] PHP 4.0 Bug #4676: Incorrect float calculation 5.5/2=2.5 (instead 2.75) From: Andi Gutmans (andi <email protected>)
Date: 05/29/00

Can you please try PHP 4.0.0.
It works for me with the latest CVS and nothing has changed since 4.0.0 in
this area.
Keep us updated so that we can close the bug report.
BTW, it might have something to do with your character set in windows
being defined to German. Let us know what the following gives you:
echo "5,5"/2;

If this results in 2.75 then that is the problem. We are fixing the
current CVS so that no matter what your character set the standard for
numbers will be in the format of 5.5 (with a period and not comma).

Andi

On 29 May 2000 phaigner <email protected> wrote:

> From: phaigner <email protected>
> Operating system: Windows98, PSW 4.0
> PHP version: 4.0 Release Candidate 2
> PHP Bug Type: Misbehaving function
> Bug description: Incorrect float calculation 5.5/2=2.5 (instead 2.75)
>
> <HTML>
> <BODY>
> <?
> echo "5.5/3=" . 5.5/3 . " ---> correct<br>";
> echo "5.5/2=" . 5.5/2 . " ---> result is 2.5 on Win98/PWS, should be 2.75 ";
> ?>
> </BODY>
> </HTML>
>
>
>

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: php-dev-unsubscribe <email protected>
For additional commands, e-mail: php-dev-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>