php-src/ext/standard/tests/array/count_symbol_table.phpt
Xinchen Hui 801e46d8c0 Add test for bug (count on symbol table)
I should have do this ....
2015-11-23 06:21:30 -08:00

23 lines
286 B
PHP

--TEST--
Test count() function : count on symbol table
--FILE--
<?php
$c1 = 0;
$c2 = 0;
$a = 1;
$b = 1;
$c1 = count($GLOBALS);
unset($a);
unset($GLOBALS["b"]);
$c2 = count($GLOBALS);
var_dump($c1 - $c2);
$c = 1;
$c1 = count($GLOBALS);
var_dump($c1 - $c2);
?>
--EXPECT--
int(2)
int(1)