summaryrefslogtreecommitdiff
path: root/tests/lang/bug29566.phpt
blob: 9c9a466388e0173767b9d144e917bfc97a9540ab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
--TEST--
Bug #29566 (foreach/string handling strangeness)
--FILE--
<?php
$var="This is a string";

$dummy="";
unset($dummy);

foreach($var['nosuchkey'] as $v) {
}
?>
--EXPECTF--
Warning: Illegal string offset 'nosuchkey' in %sbug29566.php on line %d

Warning: Invalid argument supplied for foreach() in %sbug29566.php on line %d