#7568 [Opn->WFx]: 64-bit integers, 32-bit unsigned and 64-bit unsigned

From: Date: Fri, 18 Jul 2003 07:23:09 +0000
Subject: #7568 [Opn->WFx]: 64-bit integers, 32-bit unsigned and 64-bit unsigned
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-44235@lists.php.net to get a copy of this message
 ID:               7568
 Updated by:       helly@php.net
 Reported By:      simon at comsys dot ntu-kpi dot kiev dot ua
-Status:           Open
+Status:           Wont fix
 Bug Type:         Feature/Change Request
-Operating System: FreeBSD 4.1-STABLE
+Operating System: *
 PHP Version:      4.0.3pl1
 New Comment:

PHP is a weak typed language and only supports int and double which are
system dependant. If you must ensure a hughe number range then take
bcmath as suggested.


Previous Comments:
------------------------------------------------------------------------

[2003-07-17 16:20:43] tomer at parity-bit dot com

Use the bcmath extension if you have it.

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

[2000-11-01 06:44:56] simon at comsys dot ntu-kpi dot kiev dot ua

Is it possible to add support of 64-bit integers (signed and unsigned)
and 32-bit unsigned integers to PHP?

I use MySQL with BIGINT UNSIGNED fields and it's impossible to read
such values from database (I can read them, but can't operate with
them). I can't just convert returned string to integers because size of
integers in PHP is limmited to 32-bit, and last bit is used for sign. I
can write my own functions to work with 64-bit unsigned integers but it
should do PHP itself.

Another problem is 32-bit integers. They always are signed integers and
it is also hard to work with INT UNSDIGNED fields in database.

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


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



Thread (1 message)

  • helly@php.net
  • Unknown Message
    • helly@php.net
« previous php.bugs (#44235) next »