php-src/Zend/tests/034.phpt

27 lines
335 B
Plaintext
Raw Normal View History

2008-05-12 06:44:10 +08:00
--TEST--
Testing multiples 'default:' in switch
--FILE--
2018-09-17 01:16:42 +08:00
<?php
2008-05-12 06:44:10 +08:00
switch (1) {
case 2:
print 'foo';
break;
case 3:
print 'bar';
break;
default:
print 1;
break;
default:
print 2;
break;
default:
print 3;
break;
}
?>
--EXPECTF--
Fatal error: Switch statements may only contain one default clause in %s on line 13