Skip to content

Commit

Permalink
Adjust comment_to_phpdoc fixer to exclude PHPStan error supression tags
Browse files Browse the repository at this point in the history
  • Loading branch information
erickskrauch committed Jul 21, 2023
1 parent 7c4ed0f commit e6bac9d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [Unreleased]
### Changed
- `comment_to_phpdoc` no longer fixes PHPStan error suppression and the `todo` tag.

## [1.0.0] - 2023-05-17
### Added
Expand Down
10 changes: 9 additions & 1 deletion src/Rules.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,15 @@ public static function create(array $overwrittenRules = []): array {
'visibility_required' => true,

// Comment
'comment_to_phpdoc' => true,
'comment_to_phpdoc' => [
'ignored_tags' => [
'todo',
// https://phpstan.org/user-guide/ignoring-errors
'phpstan-ignore',
'phpstan-ignore-line',
'phpstan-ignore-next-line',
],
],
'multiline_comment_opening_closing' => true,
'no_empty_comment' => true,
'single_line_comment_spacing' => true,
Expand Down

0 comments on commit e6bac9d

Please sign in to comment.