-
-
Notifications
You must be signed in to change notification settings - Fork 147
Closed
Description
Version: 3.6.4
Bug Description
When loading from the code (PhpFile::fromCode($content)), attribute arguments are not loaded as expected: arguments are "duplicated".
For instance, with this attribute:
#[AnAttribute(foo: 'bar')]The loaded arguments will be:
$args = ['foo' => new Literal("foo: 'bar'")];Expected Behavior
The loaded arguments should be:
$args = ['foo' => new Literal("'bar'")];Possible Solution
The issue comes from the call to getReformattedContents which gets everything inside the attribute as raw. It shouldn't be the case when loading content.
Metadata
Metadata
Assignees
Labels
No labels