phpdoc-parser icon indicating copy to clipboard operation
phpdoc-parser copied to clipboard

Next-gen phpDoc parser with support for intersection types and generics

Results 37 phpdoc-parser issues
Sort by recently updated
recently updated
newest added

This PR adds support for comments inside type definitions, e.g.: ```php /** @return array { // Array with comments. * // Comments can be placed on their own line. *...

[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [phpunit/phpunit](https://phpunit.de/) ([source](https://togithub.com/sebastianbergmann/phpunit)) | require-dev | major | `^9.5` -> `^10.0` |...

A few times a day, I am getting following exception in symfony project. Clearing symfony cache fixes it - any ideas what could be the issue since it's random? ```...

Like normal methods the method tag might return by reference. This fix introduces the support of reference return types. However in a real world implementation it not very likely one...

Per https://github.com/phpstan/phpdoc-parser/pull/143#issuecomment-1281099895

tl;dr: ``` (object|array){ foo: int, bar: string } ``` Several function parameters in WordPress can be passed as an associative array or a `stdClass`. This is an unfortunate result of...

# Feature request For types that involve more complex associative arrays, it is nice to know what each of key/value pairs are for. Does there exist a way to have...

Original issue: https://github.com/phpstan/phpstan/issues/9019 When we have a type defined such as ```php /** * @phpstan-type FactoriesConfigurationType = array< * string, * (class-string|Factory\FactoryInterface) * |callable(ContainerInterface,?string,?array|null):object * > */ ``` We get...

### Description It would be cool to see the extension for custom tags. We have our own tags that describe [Array shapes](https://phpstan.org/writing-php-code/phpdoc-types#array-shapes) as in PhpStan: ```php /** * @param tuple(T1,...