Permalink
Browse files

tasks: warns when is missing space after /**

  • Loading branch information...
dg committed Mar 18, 2018
1 parent bd2e874 commit d643765c065a1e849ff63aa7e296b64b69959bc3
Showing with 3 additions and 0 deletions.
  1. +3 −0 src/Tasks.php
@@ -39,6 +39,9 @@ public static function invalidPhpDocChecker($contents, Result $result)
foreach (token_get_all($contents) as $token) {
if ($token[0] === T_COMMENT && Strings::match($token[1], '#/\*(?!\*).*(?<!\w)@[a-z]#isA')) {
$result->warning('Missing /** in phpDoc comment', $token[2]);
} elseif ($token[0] === T_COMMENT && Strings::match($token[1], '#/\*\*(?!\s).*(?<!\w)@[a-z]#isA')) {
$result->warning('Missing space after /** in phpDoc comment', $token[2]);
}
}
}

0 comments on commit d643765

Please sign in to comment.