Skip to content

Parse error when processing phpDoc of Symfony Translator 2.8 #5

@JanTvrdik

Description

@JanTvrdik

Symfony Translator contains @return array[array] indexed by catalog which is processed into

MessageSelector::__PHPSTAN_CLASS_REFLECTION_CONSTANT__;
ConfigCacheFactoryInterface::__PHPSTAN_CLASS_REFLECTION_CONSTANT__;
MessageSelector::__PHPSTAN_CLASS_REFLECTION_CONSTANT__;
ConfigCacheFactoryInterface::__PHPSTAN_CLASS_REFLECTION_CONSTANT__;
LoaderInterface::__PHPSTAN_CLASS_REFLECTION_CONSTANT__;
array[array]::__PHPSTAN_CLASS_REFLECTION_CONSTANT__;                   <--- this is line 30
ConfigCacheFactoryInterface::__PHPSTAN_CLASS_REFLECTION_CONSTANT__;

which php-parser fails to parse with error „Syntax error, unexpected '[', expecting '(' on line 30“

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions