You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to the phpcs --standard=Joomla one should NOT have a single blank line before a comment or a block, if the comment is the first line of a code structure. (I.e, when the newline would appear after a '{' line, don't add it). Otherwise phpcs will complain with "Blank line found at start of control structure"
Copy file name to clipboardExpand all lines: manual/en-US/coding-standards/chapters/inline-comments.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,7 +16,7 @@ Comments should precede the code they refer to. As a corollary, comments should
16
16
17
17
Don’t use a blank line between comments and the code they refer to (no space underneath a comment block).
18
18
19
-
Always have a single blank line before a comment or block of comments.
19
+
Always have a single blank line before a comment or block of comments unless the comment (or block) is at the beginning of a code structure. ( You should not have a blank line after a '{' line )
20
20
21
21
Comments should align with the code they refer to, using the same indenting as the line that follows the comment.
0 commit comments