DeprecatedAnnotationToDeprecatedAttributeRector

Change @deprecated annotation to Deprecated attribute

-/**
- * @deprecated 1.0.0 Use SomeOtherClass instead
- */
+#[\Deprecated(message: 'Use SomeOtherClass instead', since: '1.0.0')]
 class SomeClass
 {
 }

Configure your rector.php:

<?php

use Rector\Config\RectorConfig;
use Rector\Php84\Rector\Class_\DeprecatedAnnotationToDeprecatedAttributeRector;

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