Opened 5 weeks ago
Last modified 12 days ago
#63272 reviewing enhancement
Remove redundant access tags from DocBlocks
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 6.9 | Priority: | normal |
Severity: | trivial | Version: | |
Component: | General | Keywords: | has-patch |
Focuses: | docs | Cc: |
Description
A number of methods include an @access
tag in their DocBlocks, even though the visibility is already declared in the function signature. These tags are redundant and add no new information.
I propose removing these tags to reduce redundancy and to align with the WordPress PHP Documentation Standards, which state that @access
should be used only in limited circumstances — specifically, when visibility modifiers cannot be used in the code and only when referring to private visibility (e.g., for core-only functions or core classes implementing private APIs).
Change History (3)
Note: See
TracTickets for help on using
tickets.
This patch removes
@access
tags from DocBlocks when the visibility is already defined in the method declaration. In such cases, the tags are redundant and do not provide additional value. This change is consistent with the WordPress PHP documentation standards.This patch does not modify affected methods in
WP_User_Search
(which is deprecated), or inSimplePie_Decode_HTML_Entities
,SimplePie\Parse\Date
, andSimplePie\XML\Declaration\Parser
.Trac ticket: https://core.trac.wordpress.org/ticket/63272