3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php var_dump(f(),f2()); function f(){ switch(0){ case 'ramen': return 'ramen'; case 'a': return 'string("1")'; case 1: return 'int(1)'; default: return 'default'; }} function f2(){ $v=0; switch($v){ case 'ramen': return 'ramen'; case 'A': return 'string("1")'; case 1: return 'int(1)'; default: return 'default'; }}
Output for 4.3.0 - 7.1.0
string(5) "ramen" string(5) "ramen"