|
@@ -23,6 +23,7 @@ function patchDir(string $base, string $dir): int
|
23
|
23
|
}
|
24
|
24
|
$patched = $original = file_get_contents($filename);
|
25
|
25
|
$patched = preg_replace('/\):\s*(\?[a-zA-Z]+|void)\s*\n/', ") /*:$1*/\n", $patched);
|
|
26
|
+ $patched = preg_replace('/([\(,])\s*(\?[a-zA-Z]+|void)\s+\$/', "$1 /*$2*/ \$", $patched);
|
26
|
27
|
$patched = preg_replace('/(private|public|protected) const/', "/*$1*/ const", $patched);
|
27
|
28
|
if ($patched && $patched != $original) {
|
28
|
29
|
file_put_contents($filename, $patched);
|