Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no_superfluous_phpdoc_tags removes phpdoc entry if ... used in method signature #6240

Closed
sakarikl opened this issue Jan 14, 2022 · 3 comments
Labels

Comments

@sakarikl
Copy link

Bug report

PHP CS Fixer 3.5.0 The Creation by Fabien Potencier and Dariusz Ruminski.
PHP runtime: 8.0.14

Code snippet that reproduces the problem

<?php

/**
 * @param int    $value This is a comment.
 * @param string ...$values This is information.
 */
function test(int $value, string ...$values)
{
}

is changed to

<?php

/**
 * @param int $value This is a comment.
 */
function test(int $value, string ...$values)
{
}
@sakarikl
Copy link
Author

<?php

/**
 * @param int $value  This is a comment.
 * @param $second This is information.
 */
function test($value, &$second)
{
}

is also converted to

<?php

/**
 * @param int $value This is a comment.
 */
function test($value, &$second)
{
}

@donatj
Copy link

donatj commented Jan 14, 2022

Just hit this myself just now. It's doing the same thing for &$param

image

@kubawerlos
Copy link
Contributor

Indeed, #6241 addresses both, reference and splat operator.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants