mirror of
https://github.com/php/php-src.git
synced 2024-09-22 10:27:25 +00:00
be271f277e
We need to check not only for defs but also for uses of the variable.
23 lines
326 B
PHP
23 lines
326 B
PHP
--TEST--
|
|
Bug #81652: The value of error_reporting() gets overridden
|
|
--FILE--
|
|
<?php
|
|
|
|
class Foo {
|
|
public $a;
|
|
|
|
public function bar() {
|
|
$this->a = true ? @random_int(0, 100) : false;
|
|
}
|
|
}
|
|
|
|
var_dump(error_reporting());
|
|
$c = new Foo();
|
|
$c->bar();
|
|
var_dump(error_reporting());
|
|
|
|
?>
|
|
--EXPECT--
|
|
int(32767)
|
|
int(32767)
|