Re: '9223372036854775807' == '9223372036854775808'

From: Date: Tue, 17 Apr 2012 17:42:59 +0000
Subject: Re: '9223372036854775807' == '9223372036854775808'
References: 1 2 3  Groups: php.internals 
Request: Send a blank email to internals+get-60089@lists.php.net to get a copy of this message
On 04/13/2012 04:01 AM, Gustavo Lopes wrote:
Currently, when two strings are compared, PHP tries to do a numerical comparison first. Therefore: var_dump("010" == "10"); //true
I'm replying to this old mail now, because of the current discussion about hex numbers. The phrase "numerical comparison" caught my eye because it seems in-precise, for example: var_dump(010 == 10); // false Don't forget octal. Chris -- christopher.jones@oracle.com http://twitter.com/#!/ghrd

« previous php.internals (#60089) next »