Skip to content

Commit

Permalink
SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameInAnnotation…
Browse files Browse the repository at this point in the history
…: Fixed false positive with self::CONSTANT
  • Loading branch information
kukulich committed Oct 22, 2022
1 parent 71dddfe commit 080f592
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Expand Up @@ -109,6 +109,10 @@ public function process(File $phpcsFile, $docCommentOpenPointer): void
? $constantFetchNode->className
: $constantFetchNode->name;

if ($typeHint === 'self') {
continue;
}

$fullyQualifiedTypeHint = $isClassConstant
? NamespaceHelper::resolveClassName(
$phpcsFile,
Expand Down
Expand Up @@ -178,7 +178,7 @@ public function withNever()
}

/**
* @method sortBy(callable $path, int $order = \SORT_DESC, int $sort = \SORT_NUMERIC)
* @method sortBy(callable $path, int $order = \SORT_DESC, int $sort = \SORT_NUMERIC, int $flags = self::FLAG)
*/
class ConstantExpression
{
Expand Down

0 comments on commit 080f592

Please sign in to comment.