Skip to content

Commit

Permalink
Fix regex to remove heredocs
Browse files Browse the repository at this point in the history
  • Loading branch information
Bastian Hofmann committed Dec 14, 2015
1 parent ef9aac1 commit d6dfc0a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rg/tools/phpnsc/ClassScanner.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ private function cleanContent($fileContent) {
$fileContent = $cleanWithWhitespaces("/(\'.*\')/sU", $fileContent);
$fileContent = $cleanWithWhitespaces("/(\".*\")/sU", $fileContent);
$fileContent = $cleanWithWhitespaces("/(\/\/.*)/", $fileContent);
$fileContent = $cleanWithWhitespaces("/(<<<(?P<tag>[A-Za-z_]+).*\g<tag>;)/sU", $fileContent);
$fileContent = $cleanWithWhitespaces("/(<<<(?<tag>[A-Za-z_]+).*\k<tag>;)/sU", $fileContent);

if (false) {
$fileContent = preg_replace("/(\/\*.*\*\/)/sU", '', $fileContent);
Expand Down

0 comments on commit d6dfc0a

Please sign in to comment.