<?php
$bar = new Bar;
$foo = new Foo;
class Bar {
public function __get($x) {
global $foo;
}
}
class Foo {
public function __get($x) {
global $bar;
$bar->lol;
}
}
$foo->blah--;
?>
Warning: Decrement on type null has no effect, this will change in the next major version of PHP in /in/I8oZ6 on line 15
Deprecated: Creation of dynamic property Foo::$blah is deprecated in /in/I8oZ6 on line 15
Output for 8.2.0 - 8.2.18
Deprecated: Creation of dynamic property Foo::$blah is deprecated in /in/I8oZ6 on line 15
Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /in/I8oZ6 on line 5
Process exited with code 255.
Parse error: parse error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /in/I8oZ6 on line 5
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error, expecting `T_OLD_FUNCTION' or `T_FUNCTION' or `T_VAR' or `'}'' in /in/I8oZ6 on line 5
Process exited with code 255.