3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $regex = '~ function #function keyword \s+ #any number of whitespaces (?P<function_name>.*?) #function name itself \s* #optional white spaces (?P<parameters>\(.*?\)) #function parameters \s* #optional white spaces (?P<body>\{.*?\}) #body of a function ~six'; preg_match_all($regex, 'printr(abc,assdd)', $matches) print_r($matches);
Output for 5.4.0 - 5.4.23
Parse error: syntax error, unexpected 'print_r' (T_STRING) in /in/6GmT2 on line 17
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Parse error: syntax error, unexpected T_STRING in /in/6GmT2 on line 17
Process exited with code 255.