mirror of
https://github.com/php/php-src.git
synced 2026-03-29 03:32:20 +02:00
We should strip NOPs from unreachable_free blocks as well, to make sure that the free really is the first op.
23 lines
385 B
PHP
23 lines
385 B
PHP
--TEST--
|
|
Bug #80194: Assertion failure during block assembly of unreachable free with leading nop
|
|
--FILE--
|
|
<?php
|
|
|
|
function test($x) {
|
|
switch ($x->y) {
|
|
default:
|
|
throw new Exception;
|
|
case 'foobar':
|
|
return new stdClass();
|
|
break;
|
|
}
|
|
}
|
|
|
|
$x = (object)['y' => 'foobar'];
|
|
var_dump(test($x));
|
|
|
|
?>
|
|
--EXPECT--
|
|
object(stdClass)#2 (0) {
|
|
}
|