Summary: Improve `ArcanistInlineHTMLXHPASTLinterRule` such that it doesn't raise duplicate warnings. Also be a bit more lax with whitespace.
Test Plan: Unit tests now pass.
Reviewers: #blessed_reviewers, epriestley
Reviewed By: #blessed_reviewers, epriestley
Subscribers: Korvin
Differential Revision: https://secure.phabricator.com/D13896
continue;
}
+ if (preg_match('/^\s*$/', $html->getValue())) {
+ continue;
+ }
+
$this->raiseLintAtToken(
$html,
pht('PHP files must only contain PHP code.'));
+ break;
}
}
This shouldn't fatal the parser.
~~~~~~~~~~
+disabled:2:1
?>
~~~~~~~~~~
+disabled:1:1
error:1:1
~~~~~~~~~~
garbage garbage