blob: 840e298b826a3b9a02efeaf2fb330c03ab215c15 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
--TEST--
Dynamic calls to scope introspection functions are forbidden
--FILE--
<?php
function test_calls($func) {
$i = 1;
array_map($func, [['i' => new stdClass]]);
var_dump($i);
$func(['i' => new stdClass]);
var_dump($i);
call_user_func($func, ['i' => new stdClass]);
var_dump($i);
}
test_calls('extract');
?>
--EXPECTF--
Warning: Cannot call extract() dynamically in %s on line %d
int(1)
Warning: Cannot call extract() dynamically in %s on line %d
int(1)
Warning: Cannot call extract() dynamically in %s on line %d
int(1)
|