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
PhpdocAnnotationWithoutDotFixer - Handle empty line in comment #3882
PhpdocAnnotationWithoutDotFixer - Handle empty line in comment #3882
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Learning from all the comments I've gotten before, I don't think this is the way to go, it indeed feels a bit hacky.
Also, @SpacePossum said in #3857 he considers this case a priority-issue, for which I made #3879 which should fix not only PhpdocAnnotationWithoutDotFixer
but all Phpdoc*Fixer
s
'<?php | ||
/** | ||
* This is a broken phpdoc | ||
* @param string string Surprisingly, it is a string. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can see that the fixer works by the removal of the dot, but this should be string $str
instead of string string
, and then Surprisingly
will be lowercased as well.
The solutions, this one and resolving the priority, don't have to be exclusive, sorry if I caused confusion about that. For this PR, I like the direction 👍
be fixed in the new situation? |
@SpacePossum not nicely - |
can you add this to the tests?
If the fixer removes the dot after |
Thanks for the test, this PR looks good to me. |
@kubawerlos , can you rebase please ? we have some conflicts due to recent merging session |
Thank you @kubawerlos. |
…mment (kubawerlos) This PR was merged into the 2.12 branch. Discussion ---------- PhpdocAnnotationWithoutDotFixer - Handle empty line in comment Solves #3857 (comment) - yet, feels too easy - I'm pessimistic about this one - can we easily trick it? @SpacePossum @dmvdbrugge what do you think? Commits ------- 14190a4 PhpdocAnnotationWithoutDotFixer - Handle empty line in comment
This PR was squashed before being merged into the 2.12 branch (closes #4027). Discussion ---------- PhpdocAnnotationWithoutDotFixer - add failing cases introduced in #3882 ref symfony/symfony#28814 ref symfony/symfony#28817 Commits ------- 330fe39 PhpdocAnnotationWithoutDotFixer - add failing cases
Solves #3857 (comment) - yet, feels too easy - I'm pessimistic about this one - can we easily trick it? @SpacePossum @dmvdbrugge what do you think?