Skip to content

Commit

Permalink
php-protobuf had the same bug with empty comments as pb4php...
Browse files Browse the repository at this point in the history
  • Loading branch information
danielmewes committed May 29, 2013
1 parent 6754474 commit fddfc7e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/php-protobuf/ProtobufCompiler/ProtobufParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -1209,7 +1209,7 @@ private function _getBeginEnd($string, $char, $charend)
*/
private function _stripComments(&$string)
{
$string = preg_replace('/\/\/.+/', '', $string);
$string = preg_replace('/\/\/.*/', '', $string);
// now replace empty lines and whitespaces in front
$string = preg_replace('/\\r?\\n\s*/', PHP_EOL, $string);
}
Expand Down

0 comments on commit fddfc7e

Please sign in to comment.