RealToFloatTypeCastRector

Change deprecated (real) to (float)

 class SomeClass
 {
     public function run()
     {
-        $number = (real) 5;
+        $number = (float) 5;
         $number = (float) 5;
         $number = (double) 5;
     }
 }

Configure your rector.php:

<?php

use Rector\Config\RectorConfig;
use Rector\Php74\Rector\Double\RealToFloatTypeCastRector;

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