]> granicus.if.org Git - php/commitdiff
* Roll it back then. I wonder if defaulting it to SORT_REGULAR would work well
authorMoriyoshi Koizumi <moriyoshi@php.net>
Fri, 15 May 2009 17:02:34 +0000 (17:02 +0000)
committerMoriyoshi Koizumi <moriyoshi@php.net>
Fri, 15 May 2009 17:02:34 +0000 (17:02 +0000)
  and I think allowing user-supplied comparator should make more sense when it
  comes to objects.

ext/standard/array.c

index b34ea9ba44616ec3f76a833361664c3af310175c..57f15946cec322461197e945bc6d9d478ecdbec7 100644 (file)
@@ -2889,7 +2889,7 @@ PHP_FUNCTION(array_unique)
        };
        struct bucketindex *arTmp, *cmpdata, *lastkept;
        unsigned int i;
-       long sort_type = PHP_SORT_REGULAR;
+       long sort_type = PHP_SORT_STRING;
 
        if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "a|l", &array, &sort_type) == FAILURE) {
                return;