php-8.0.30-src/ext/opcache/tests/ssa_bug_002.phpt

19 lines
246 B
PHP

--TEST--
Incorrect NOP removal on jump to NOP
--SKIPIF--
<?php require_once('skipif.inc'); ?>
--FILE--
<?php
function test(int $i) : int {
if ($i == 1) {
$x = $i + 1;
}
return $i;
}
var_dump(test(42));
?>
--EXPECT--
int(42)