Annotation of embedaddon/php/Zend/tests/bug43344_1.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: Bug #43344.1 (Wrong error message for undefined namespace constant)
! 3: --FILE--
! 4: <?php
! 5: namespace Foo;
! 6: function f1($a=bar) {
! 7: return $a;
! 8: }
! 9: function f2($a=array(bar)) {
! 10: return $a[0];
! 11: }
! 12: function f3($a=array(bar=>0)) {
! 13: reset($a);
! 14: return key($a);
! 15: }
! 16: echo bar."\n";
! 17: echo f1()."\n";
! 18: echo f2()."\n";
! 19: echo f3()."\n";
! 20: ?>
! 21: --EXPECTF--
! 22: Notice: Use of undefined constant bar - assumed 'bar' in %sbug43344_1.php on line 13
! 23: bar
! 24:
! 25: Notice: Use of undefined constant bar - assumed 'bar' in %sbug43344_1.php on line 3
! 26: bar
! 27:
! 28: Notice: Use of undefined constant bar - assumed 'bar' in %sbug43344_1.php on line 6
! 29: bar
! 30:
! 31: Notice: Use of undefined constant bar - assumed 'bar' in %sbug43344_1.php on line 9
! 32: bar
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>