/hphp/test/slow/ext_array/array_unshift.php
PHP | 14 lines | 11 code | 3 blank | 0 comment | 0 complexity | cd78b8eebdc26c52920cfc7ef7093cbe MD5 | raw file
Possible License(s): LGPL-2.1, BSD-2-Clause, BSD-3-Clause, MPL-2.0-no-copyleft-exception, MIT, LGPL-2.0, Apache-2.0
- <?hh
- <<__EntryPoint>>
- function main_array_unshift() {
- $q = varray["orange", "banana"];
- array_unshift(inout $q, "apple", "raspberry");
- var_dump($q);
- $q = darray[0 => "orange", 1 => "banana", "a" => "dummy"];
- unset($q['a']);
- array_unshift(inout $q, "apple", "raspberry");
- var_dump($q);
- }