/hphp/test/slow/dict/dict-unset.php
PHP | 17 lines | 14 code | 3 blank | 0 comment | 0 complexity | 5932f0cb3127de8f50fa09e2258f0aa7 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
- function main() {
- $e = dict[];
- $one = dict[1 => "bar"];
- $two = dict[1 => "apple", "1" => "orange"];
- $e[1] = "red";
- $e["1"] = "green";
- $one["1"] = "foo";
- unset($e[1]);
- unset($one[1]);
- unset($two["1"]);
- var_dump($e, $one, $two);
- }
- main();