3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php namespace \; class Another{} namespace My\Full\Classname; class Another{} use My\Full\Classname as Another; $obj = new Another; // instantiates object of class My\Full\Classname $a = 'Another'; $obj = new $a; // instantiates object of class Another ?>
Output for 5.4.0 - 5.4.2
Parse error: syntax error, unexpected ';', expecting identifier (T_STRING) in /in/qQgnS on line 2
Process exited with code 255.
Output for 5.3.0 - 5.3.12
Parse error: syntax error, unexpected ';', expecting T_STRING in /in/qQgnS on line 2
Process exited with code 255.