3v4l.org

run code in 500+ PHP versions simultaneously
<?php $s = "/**\r\n". "* @changelog https://github.com/rectorphp/rector/blob/master/docs/rector_rules_overview.md\r\n". "*/\r\n"; $annotation = '@changelog'; var_dump(extractAnnotationFromClass($s, $annotation)); function extractAnnotationFromClass(string $docComment, string $annotation): ?string { // @see https://regex101.com/r/oYGaWU/1 $pattern = '#' . preg_quote($annotation, '#') . '\s+(?<content>.*?)$#m'; preg_match($pattern, $docComment, $matches); return $matches['content'] ?? null; }
Output for git.master, git.master_jit, rfc.property-hooks
string(78) "https://github.com/rectorphp/rector/blob/master/docs/rector_rules_overview.md "

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
51.54 ms | 1436 KiB | 4 Q