Skip to content

Conversation

@staabm
Copy link
Contributor

@staabm staabm commented Jun 26, 2025

@staabm staabm changed the title Playground: Implement NonPhpdocCommentRule Playground: Implement PhpdocCommentRule Jun 26, 2025
@clxmstaab clxmstaab force-pushed the NonPhpdocCommentRule branch from c033db6 to c495d3d Compare June 26, 2025 14:07
@staabm staabm marked this pull request as ready for review June 26, 2025 14:14
@phpstan-bot
Copy link
Collaborator

This pull request has been marked as ready for review.

@staabm staabm force-pushed the NonPhpdocCommentRule branch from 1c8c478 to 36d28d7 Compare July 11, 2025 09:54

public function getNodeType(): string
{
return Node::class;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd do it only for Node\Stmt.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tbh there are so many different node types, that I don't know what the differences are in this case.

adjusted it per request :)

use function str_starts_with;

/**
* @implements Rule<Node>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not synced with getNodeType

@ondrejmirtes ondrejmirtes merged commit 8ece074 into phpstan:2.1.x Jul 17, 2025
402 of 421 checks passed
@ondrejmirtes
Copy link
Member

Thank you. Please add it to https://github.com/phpstan/phpstan/blob/2.1.x/playground-runner/playground.neon once it's built.

@staabm staabm deleted the NonPhpdocCommentRule branch July 17, 2025 11:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants