#63616 closed enhancement (duplicate)
do_blocks(): Document optimization from #63588
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | 6.9 |
| Component: | Editor | Keywords: | has-patch close |
| Focuses: | docs | Cc: |
Description
See #63588
When the transient-memory-leak was optimized-away in #63588 it was added without an explanatory comment. This leaves the code prone to accidental removal by someone coming along and thinking that there is extra work being done.
The optimization should be documented so that there’s a stronger guard against accidental and well-intentioned-yet-harmful regression.
Change History (6)
This ticket was mentioned in PR #9052 on WordPress/wordpress-develop by @dmsnell.
6 months ago
#1
- Keywords has-patch added
#2
@
6 months ago
- Focuses docs added; performance removed
- Keywords close added
Can we just reopen the original ticket and link the commit there please? :-)
#3
@
6 months ago
- Milestone Awaiting Review deleted
- Resolution set to duplicate
- Status changed from new to closed
Duplicate of #63588.
Oh sure @swissspidy — sorry I didn’t think to do that.
This ticket was mentioned in Slack in #core-performance by dmsnell. View the logs.
6 months ago
This ticket was mentioned in Slack in #core-performance by dmsnell. View the logs.
6 months ago
6 months ago
#6
@audrasjb I’m open to that, though I would need help with knowing what link you’re referring to. do you mean removing this inline link entirely and adding another PHPDoc token below on a line of its own, * @see parse_blocks()?
This docblock won't be fetched by the docblock, parser as it is not a function or a hook
Right, so I think this only affects an in-IDE experience, for which I was trying to optimize.
providing the link is probably better than using a relative reference
I don’t think I know what you are referring to with “relative reference”. I did some testing an indeed, were this docblock inside a class it would resolve to the class method of the same name. With namespaces it follows the module namespace.
I’ll wait for clarification, but in the meantime I’ve added a leading \ which should resolve all ambiguity in referencing the name.
Trac ticket: Core-63616
See #8999
Adds explanatory comment indicating why the optimization was added and guarding against accidental removal.
This is a documentation-only change and should include no functional or visual changes.