import zend standard tests
[hiphop-php.git] / hphp / test / zend / good / ext-standard-array / natcasesort_variation6.php
bloba351e141319a29b46aaca440a882c5b72946908e
1 <?php
2 /* Prototype : bool natcasesort(array &$array_arg)
3 * Description: Sort an array using case-insensitive natural sort
4 * Source code: ext/standard/array.c
5 */
7 /*
8 * Pass an array of referenced varaibles to test how natcasesort() re-orders it
9 */
11 echo "*** Testing natcasesort() : usage variation ***\n";
13 $value1 = 100;
14 $value2 = 33;
15 $value3 = 555;
17 echo "\n-- Initial test --\n";
18 $array = array( &$value1 , &$value2, &$value3);
19 var_dump( natcasesort($array) );
20 var_dump($array);
22 echo "\n-- Change \$value1 --\n";
23 $value1 = -29;
24 var_dump( natcasesort($array) );
25 var_dump($array);
27 echo "Done";