3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class Foo { static $modeMapping = array( 'bar' => 'Exception' ); public static function testing() { if (isset( self::$modeMapping[$mode] ) ) { return new self::$modeMapping[$mode]( ); } } } var_dump( Foo::testing() );
based on 2aqPC
Output for 5.3.18 - 7.2.0
Notice: Undefined variable: mode in /in/eY00J on line 6 NULL