mirror of
https://github.com/php/php-src.git
synced 2026-04-05 07:02:33 +02:00
For rationale, see #6787 Extensions migrated in part 3: * ftp * gmp * iconv * opcache * shmop
23 lines
346 B
PHP
23 lines
346 B
PHP
--TEST--
|
|
Bug #77058: Type inference in opcache causes side effects
|
|
--EXTENSIONS--
|
|
opcache
|
|
--FILE--
|
|
<?php
|
|
|
|
function myfunc(){
|
|
$Nr = 0;
|
|
while(1){
|
|
$x--;
|
|
$x++;
|
|
if( ++ $Nr >= 2 ) break;
|
|
}
|
|
echo "'$Nr' is expected to be 2", PHP_EOL;
|
|
}
|
|
myfunc();
|
|
|
|
?>
|
|
--EXPECTF--
|
|
Warning: Undefined variable $x in %s on line %d
|
|
'2' is expected to be 2
|