proget-hq / phpstan-yii2

Yii2 extension for PHPStan
MIT License
52 stars 18 forks source link

Argument 1 passed to PHPStan\Analyser\MutatingScope::resolveName() must be an instance of PhpParser\Node\Name #52

Open lesha724 opened 1 year ago

lesha724 commented 1 year ago

Hello, I have next error on latest version phpstan:

Internal error: Argument 1 passed to PHPStan\Analyser\MutatingScope::resolveName() must be an instance of PhpParser\Node\Name, instance of PhpParser\Node\Expr\PropertyFetch given, called in \vendor\proget-hq\phpstan-yii2\src\Type\ActiveRecordDynamicStaticMethodReturnTypeExtension.php  on line 51 
fernando2amigos commented 8 months ago

Hello. Any update on this?

Also facing wrong type params errors all around.

Argument 1 passed to PHPStan\Analyser\MutatingScope::resolveName() must be an instance of PhpParser\Node\Name, instance of PhpParser\Node\Expr\Variable given, called in
     /var/www/vendor/proget-hq/phpstan-yii2/src/Type/ActiveRecordDynamicStaticMethodReturnTypeExtension.php on line 51 while analysing file /var/www/common/components/controllers/BaseController.php

Yii: 2.0.49 PHP: 7.4 PHPStan: 1.10.59 phpstan-yii2: 0.8.0