You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
run composer install && composer prefix-namespaces to replicate issue.
go to dependencies/symfony/polyfill-php80/Resources/stubs/Attribute.php and see that class declaration has unwanted classmap prefix
I was able to narrow this error down to the vendor/symfony/console/CHANGELOG.md file which contains class final.
FileScanner@find method regexp recognizes this as valid class name (I guess), adds it as class symbol and then uses it to replace word final.
Solution
Simplest solution would be to scan only .php files for class discovery. Locally I did simple check that solved this issue, but I guess that for some reason scanning is not limited only to PHP files.
The text was updated successfully, but these errors were encountered:
I don't think there was any intent to scan more than just PHP files, rather it hasn't been an issue until now.
There are potentially other file types that could have replacements made in them, e.g. the Authorize.net SDK uses (used?) a SOAP XML file and it parsed that to know what classes were used for which endpoints. It'd be nice to have but hasn't been an issue for me in years.
Problem
composer install && composer prefix-namespaces
to replicate issue.dependencies/symfony/polyfill-php80/Resources/stubs/Attribute.php
and see that class declaration has unwanted classmap prefixI was able to narrow this error down to the
vendor/symfony/console/CHANGELOG.md
file which containsclass final
.FileScanner@find
method regexp recognizes this as valid class name (I guess), adds it as class symbol and then uses it to replace wordfinal
.Solution
Simplest solution would be to scan only
.php
files for class discovery. Locally I did simple check that solved this issue, but I guess that for some reason scanning is not limited only to PHP files.The text was updated successfully, but these errors were encountered: