3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php namespace { const TEST_CONST1 = true; define("TEST_CONST2", true); function testExistConst() { var_dump(constant("TEST_CONST1")); var_dump(constant("TEST_CONST2")); var_dump(TEST_CONST1); var_dump(TEST_CONST2); } }