3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class Foo { public static $val = 'Foo'; public static function huh() { echo self::$val; } } class Bar extends Foo { protected static $val = 'Bar'; } Foo::huh(); Bar::huh();
Output for 5.3.0 - 5.4.9
Fatal error: Access level to Bar::$val must be public (as in class Foo) in /in/A6uV6 on line 11
Process exited with code 255.