Hi Nikita!

Nikita Popov wrote:
I've update the message to say:

Deprecated: usort(): Returning bool from comparison function is
deprecated, return an integer less than, equal to, or larger than zero in
%s on line %d

The astute reader will notice that this is equivalent to "any integer", but
I think phrased this way, the meaning should be clear to anyone familiar
with the basic concept of comparison functions, while not mentioning -1, 0
and 1 in particular.

Sounds good!

PS: Yes, I'm aware that you can also return a floating point number. No,
you should definitely not do that, because it's going to get casted to an
integer and produce wrong results if the numbers get large enough.

That sounds like something we could easily and cheaply fix…

Regards,
Andrea

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to