3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $string = '{{ 1, $user:John Doe; $dgd:brat; }}'; preg_match_all("/(?=[^}]*}})([$]?[^[:punct:]]+)/", $string, $matches); print_r($matches[1]);
based on 9NjXE
Output for 4.3.0 - 5.6.28, hhvm-3.12.0, 7.0.0 - 7.1.0
Array ( [0] => 1 [1] => [2] => $user [3] => John Doe [4] => [5] => $dgd [6] => brat [7] => )
Output for hhvm-3.10.0

Process exited with code 153.