Problem/Motivation
Currently ModuleHandler contains a number of properties and parameters that only have an "array" doc without further specifity.
This is bad for static analysis (phpstan, IDEs) and when reading the code.
Developers who are familiar with advanced phpdoc/phpstan/psalm syntax don't want to read the textual explanations.
As a baseline for other issues that touch ModuleHandler, we can improve that documentation now.
This will also help when reviewing future merge requests.
Steps to reproduce
Proposed resolution
Add phpstan-like array docs.
See also #3468236: Adopt phpstan phpdoc types as canonical reference of allowed types.
Remaining tasks
User interface changes
Introduced terminology
API changes
Data model changes
Release notes snippet
Issue fork drupal-3522788
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3522788-ModuleHandler-array-shapes
changes, plain diff MR !12044
Comments
Comment #2
donquixote commentedComment #4
bbralaFailure is unrelated, yay for build errors. Changes look good, al comply with the description of the variable. Its not NR, so cant do much more than this?
Comment #5
donquixote commentedsorry :)
Comment #6
bbralaAh thanks. Changes look good as i said earlier.
Comment #7
nicxvan commentedJust moving to the right component.
Comment #9
larowlanCommitted to 11.x - thanks!
Comment #11
donquixote commentedThanks!