Skip to content

conflict with AnnotationFileLoader and PHP8 attributes #40225

@nlhommet

Description

@nlhommet

Symfony version(s) affected: 5.2.x

PHP version: 8.x

Description
When an attribute has a parameter named class before the class declaration, the script tries to load the content of that parameter.

...
#[ParamConverter(
    'availability',
    class: Table\Availability::class,
    options: ['id' => 'ida']
)]
...
class EditController
{
...

How to reproduce
See issue https://github.com/sensiolabs/SensioFrameworkExtraBundle/issues/713 for more detail

Possible Solution
See here https://github.com/sensiolabs/SensioFrameworkExtraBundle/issues/713#issuecomment-780669307

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions