function foo()
{
    $k = get_thing();
    $y = get_two();
    $x = "initial x value";
    do_echo($x);
    try {
        $x = $y ? "ok1" : "ok2";
        ${$k} = 3;
        goto heh;
        // needed or hphpc decides the assignment to $x can be removed
    } catch (Exception $e) {
        var_dump($x);
        return;
    }
    heh:
    var_dump($x);
}
Beispiel #2
0
function interface_type()
{
    return get_thing(new Z());
}