Opened 3 years ago
Closed 2 years ago
#54746 closed task (blessed) (fixed)
Comment Error in wp-login.php
Reported by: | alkesh7 | Owned by: | SergeyBiryukov |
---|---|---|---|
Milestone: | 6.0 | Priority: | normal |
Severity: | minor | Version: | |
Component: | Login and Registration | Keywords: | |
Focuses: | docs, coding-standards | Cc: |
Description
Hello WordPress Team,
I have seen that WordPress have issue in the comment structure.
WordPress follow a comment structure. See the Comment Standard link: https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#5-inline-comments
In the WordPress 5.9 Release Candidate Version. There is a Comment structure issue in file "wp-login.php" in root folder. See the issue in the below screenshot.
https://prnt.sc/263q9qs
Kindly take a look on my request and fix it.
Thank you!
Attachments (3)
Change History (14)
This ticket was mentioned in Slack in #docs by presskopp. View the logs.
3 years ago
This ticket was mentioned in Slack in #core-coding-standards by presskopp. View the logs.
3 years ago
#5
@
3 years ago
- Component changed from Comments to Login and Registration
- Focuses docs added
- Version trunk deleted
#6
@
3 years ago
@Presskopp Yes, it's in several places in core. I found it in 49 files but some of those were third party libraries.
For the purposes of this ticket, let's focus on wp-login.php and any further fixes can go on the generic coding standards fixes ticket #54728.
#7
@
3 years ago
- Owner set to peterwilsoncc
- Resolution set to fixed
- Status changed from new to closed
In 52945:
#8
follow-up:
↓ 9
@
3 years ago
- Resolution fixed deleted
- Status changed from closed to reopened
I think comments like "Main" have some benefit, as they denote various parts of the file, in this case separating function declarations from the main part.
Instead of removing them, I think we can convert them to the multi-line format per the documentation standards:
/* * Main. */
#9
in reply to:
↑ 8
@
3 years ago
- Keywords has-patch removed
- Owner changed from peterwilsoncc to SergeyBiryukov
- Status changed from reopened to assigned
Replying to SergeyBiryukov:
I think comments like "Main" have some benefit, as they denote various parts of the file, in this case separating function declarations from the main part.
With the additional context they do, on it's own the word main is meaningless.
Instead of removing them, I think we can convert them to the multi-line format per the documentation standards:
/* * Main. */
The point is to meet the coding standards by avoiding single line comments of that format. Given that the additional context is needed for the comment to make sense, I think it best revised as a multi-line comment anyway.
Hello and welcome back to Trac!
As we entered release candidate cycle for 5.9, let's address this in 6.0.