3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php namespace Foo { class Bar {} }; namespace Foo\Baz { class Qux {} } namespace { use Foo as F; use F\Baz; new Baz\Qux; }
based on hVGsJ
Output for 7.0.0 - 7.2.0
Fatal error: Uncaught Error: Class 'F\Baz\Qux' not found in /in/0seJD:20 Stack trace: #0 {main} thrown in /in/0seJD on line 20
Process exited with code 255.
Output for 5.3.18 - 5.6.28
Fatal error: No code may exist outside of namespace {} in /in/0seJD on line 7
Process exited with code 255.