如何对PHP的64位整数? [英] how to have 64 bit integer on PHP?
本文介绍了如何对PHP的64位整数?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
没有人知道如何让64位整数的PHP?现在看来似乎不是由配置文件,而是它可能是一个编译时选择,它取决于平台?
does someone know how to have 64 bit integer on PHP? it seems like it is not by config file but rather it might be a compile time option and it depends on the platform?
推荐答案
原生64位整数需要64位硬件和64位版本的PHP。
Native 64-bit integers require 64-bit hardware AND the 64-bit version of PHP.
在32位硬件:
$ php -r 'echo PHP_INT_MAX;'
2147483647
在64位硬件:
$ php -r 'echo PHP_INT_MAX;'
9223372036854775807
这篇关于如何对PHP的64位整数?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文