Closed NickSdot closed 6 months ago
I think it's caused by the Laravel installer being installed globally. It depends on Prompts, which effectively makes it installed globally as well. With the auto_prepend_file
setting in place, there are effectively two copies of Prompts installed.
Prompts didn't previously have the function_exists
guard like other Laravel helpers because they are namespaced functions rather than global, but I don't see any issues adding it.
To make packages like
symfony/var-dumper
available globally you prepend the global Composerautoload.php
like so:From: https://symfony.com/doc/current/components/var_dumper.html
To reproduce, at least these must be installed.
Then run PhpStan in a project.
Result.
Notes
helper.php
functions, I think they should be protected against redeclaration. This PR adds the required checks.Amazing work here btw, Jess. Thank you! 🫡❤️