NewMethodCallWithoutParenthesesRector

Remove parentheses on new method call with parentheses

-(new Request())->withMethod('GET')->withUri('/hello-world');
+new Request()->withMethod('GET')->withUri('/hello-world');

Configure your rector.php:

<?php

use Rector\Config\RectorConfig;
use Rector\Php84\Rector\MethodCall\NewMethodCallWithoutParenthesesRector;

return RectorConfig::configure()
    ->withRules([
        NewMethodCallWithoutParenthesesRector::class,
    ]);
SETS:  PHP 8.4