lint/phpdoc/no-misplaced
In the coding-style set. Safe fix.
What it does
Docblocks should only be used on structural elements.
Configuration
[lint.rules]
"phpdoc/no-misplaced" = "error"
To skip it in some files, add an override or a @pun-ignore-file comment.
Options
| Name | Type | Allowed values | Default | Upstream name |
|---|---|---|---|---|
allow-before-return-statement |
bool |
Any | false |
allow_before_return_statement |
ignored-tags |
list |
Any | [] |
ignored_tags |
Replaces
phpdoc_to_comment(php-cs-fixer)