[wp-trac] [WordPress Trac] #63272: Remove redundant access tags from DocBlocks

WordPress Trac noreply at wordpress.org
Sun Apr 13 02:16:16 UTC 2025


#63272: Remove redundant access tags from DocBlocks
-------------------------+-----------------------------
 Reporter:  marian1      |      Owner:  (none)
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  General      |    Version:
 Severity:  trivial      |   Keywords:
  Focuses:  docs         |
-------------------------+-----------------------------
 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
 [https://developer.wordpress.org/coding-standards/inline-documentation-
 standards/php/#phpdoc-tags 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).

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/63272>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list