3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $string = '{{ 1, $user:John Doe; $dgd:brat; }}'; preg_match_all("/(?=[^}]*}})([$]?(^([:punct:]\s)?)+)/", $string, $matches); print_r($matches[1]);
based on 7uO7L
Output for 5.2.0 - 5.6.28, 7.0.0 - 7.1.0
Warning: preg_match_all(): Compilation failed: POSIX named classes are supported only within a class at offset 19 in /in/KtkaZ on line 4
Output for hhvm-3.10.0 - 3.12.0
Warning: Compilation failed: POSIX named classes are supported only within a class at offset 19 in /in/KtkaZ on line 4
Output for 4.3.11 - 5.1.6
Warning: preg_match_all(): Compilation failed: POSIX named classes are supported only within a class at offset 19 in /in/KtkaZ on line 4 Notice: Undefined offset: 1 in /in/KtkaZ on line 5
Output for 4.3.0 - 4.3.10
Warning: Compilation failed: POSIX named classes are supported only within a class at offset 19 in /in/KtkaZ on line 4 Notice: Undefined offset: 1 in /in/KtkaZ on line 5