3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php error_reporting(-1); class A { static $i=1; static function B() { echo self::$i."\n"; echo __CLASS__; } } class B extends A { static $i=2; static function B(){ echo self::$i."\t".__CLASS__; } } B::B();
Output for 5.3.0 - 5.4.24
Fatal error: Constructor B::B() cannot be static in /in/SdrGS on line 15
Process exited with code 255.