-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bug #5385 SingleLineCommentStyleFixer- run before NoUselessReturnFixe…
…r (kubawerlos) This PR was merged into the 2.17 branch. Discussion ---------- SingleLineCommentStyleFixer- run before NoUselessReturnFixer Fixes #5382 Ping @mvorisek for review (as a reporter of bug). Commits ------- c262d5c Make single_line_comment_style runs after no_useless_return
- Loading branch information
Showing
4 changed files
with
29 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
tests/Fixtures/Integration/priority/no_useless_return,single_line_comment_style.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--TEST-- | ||
Integration of fixers: no_useless_return,single_line_comment_style. | ||
--RULESET-- | ||
{ "no_useless_return": true, "single_line_comment_style": true } | ||
--EXPECT-- | ||
<?php | ||
function foo() | ||
{ | ||
// foo | ||
} | ||
|
||
--INPUT-- | ||
<?php | ||
function foo() | ||
{ | ||
return/* foo */; | ||
} |