Annotation of embedaddon/php/Zend/tests/isset_003.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: Testing isset accessing undefined array itens and properties
3: --FILE--
4: <?php
5:
6: $a = 'foo';
7: $b =& $a;
8:
9: var_dump(isset($b));
10:
11: var_dump(isset($a[0], $b[1]));
12:
13: var_dump(isset($a[0]->a));
14:
15: var_dump(isset($c[0][1][2]->a->b->c->d));
16:
17: var_dump(isset(${$a}->{$b->$c[$d]}));
18:
19: var_dump(isset($GLOBALS));
20:
21: var_dump(isset($GLOBALS[1]));
22:
23: var_dump(isset($GLOBALS[1]->$GLOBALS));
24:
25: ?>
26: --EXPECTF--
27: bool(true)
28: bool(true)
29: bool(false)
30: bool(false)
31:
32: Notice: Undefined variable: d in %s on line %d
33:
34: Notice: Undefined variable: c in %s on line %d
35:
36: Notice: Trying to get property of non-object in %s on line %d
37: bool(false)
38: bool(true)
39: bool(false)
40: bool(false)
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>