Skip to content

Conversation

arshidkv12
Copy link
Contributor

$result = trim(strtoupper("Hello World"));
$result = strtoupper(Hello World) |> trim(...);


public function getNodeTypes(): array
{
return [Assign::class, FuncCall::class];
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should use StmtsAwareInterface, loop and break/skip when extra vars is used or in the middle per example at https://amitmerchant.com/everything-that-is-coming-in-php-85/

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok

if (! $node->expr instanceof FuncCall) {
return null;
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

skip $node->firstClassCallable()

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok. vendor/bin/phpstan analyse --ansi not working.

vendor/bin/phpstan analyse --ansi                                                                  
Note: Using configuration file /Users/arshid/Downloads/rector-src/phpstan.neon.

In Resolver.php line 482:
                                                                                                                                                      
  Service 'rules.0' (type of Symplify\PHPStanRules\Rules\NoDynamicNameRule): Service of type Symplify\PHPStanRules\TypeAnalyzer\CallableTypeAnalyzer  
   required by $callableTypeAnalyzer in NoDynamicNameRule::__construct() not found. Did you add it to configuration file?                             
                                  

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't reproduce, you may have vendor/ issue, probably remove and run composer update:

rm -rf vendor
composer update

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants