3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class a { const TEST = 5; public static $arr = array( self::TEST => 'xxxxxxxxxxxx', ); } try { throw new Exception(a::$a[a::TEST], a::TEST); } catch(Exception $e) { echo $e->getMessage(); }
based on eJsEr
Output for 7.0.0 - 7.2.0
Fatal error: Uncaught Error: Access to undeclared static property: a::$a in /in/nBbM2:10 Stack trace: #0 {main} thrown in /in/nBbM2 on line 10
Process exited with code 255.
Output for 5.3.21 - 5.6.28
Fatal error: Access to undeclared static property: a::$a in /in/nBbM2 on line 10
Process exited with code 255.