summaryrefslogtreecommitdiff
path: root/ext/opcache/tests/jmp_elim_004.phpt
blob: 8834ab4e85ce2eed981c2db617aca88c6fa18668 (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--
Incorrect empty basic block elimination
--INI--
opcache.enable_cli=1
opcache.optimization_level=-1
--SKIPIF--
<?php require_once('skipif.inc'); ?>
--FILE--
<?php

function test() {
    $foo = "test";
    var_dump($foo ?? "default");

    $null = null;
    var_dump($null ?? 3);
    var_dump($null ?? new stdClass);
}
test();

?>
--EXPECT--
string(4) "test"
int(3)
object(stdClass)#1 (0) {
}