Edit report at https://bugs.php.net/bug.php?id=55378&edit=1

 ID:                 55378
 Updated by:         der...@php.net
 Reported by:        for-bugs at hnw dot jp
 Summary:            binary number literal returns float number though
                     its value is enough small
-Status:             Open
+Status:             Assigned
 Type:               Bug
 Package:            Scripting Engine problem
 Operating System:   MacOSX
 PHP Version:        5.4.0alpha3
-Assigned To:        
+Assigned To:        derickr
 Block user comment: N
 Private report:     N



Previous Comments:
------------------------------------------------------------------------
[2011-08-07 01:37:02] for-bugs at hnw dot jp

Description:
------------
The binary numbers format(see #50648, https://bugs.php.net/bug.php?id=50648)
was introduced to PHP 5.4.0alpha3.

However, its boundary value is wrong for judging whether return value shoud be 
integer or floating point number. See test script.

Test script:
---------------
<?php
var_dump(0b1111111);
var_dump(0b1111111111111111);


Expected result:
----------------
int(127)
int(65535)

Actual result:
--------------
int(127)
float(65535)


------------------------------------------------------------------------



-- 
Edit this bug report at https://bugs.php.net/bug.php?id=55378&edit=1

Reply via email to