note 102700 deleted from function.usort by danbrown
| From: | danbrown@php.net | Date: | Tue, 01 Mar 2011 14:17:13 +0000 |
| Subject: | note 102700 deleted from function.usort by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-177438@lists.php.net to get a copy of this message | ||
Note Submitter: cuong dot huy dot to at gmail dot com
----
Probably a bug or undocumented feature: usort() sort your list even if you don't want to.
Detail: If you call usort($your_list, "your_call_back_function"), where inside the
your_call_back_function() you return 0 immediately, then you would expect $your_list to be
unchanged. But in fact it is changed.