summaryrefslogtreecommitdiff
path: root/Zend/tests/jump11.phpt
blob: 4c4c4f30a20f38db6f62444677ffbea947258e50 (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
--TEST--
jump 08: goto inside switch in constructor
--FILE--
<?php
class foobar {
    public function __construct() {
        switch (1) {
            default:
                goto b;
                a:
                    print "ok!\n";
                    break;
                b:
                    print "ok!\n";
                    goto a;
        }
        print "ok!\n";
    }
}

new foobar;
?>
--EXPECT--
ok!
ok!
ok!