Updated Rector to commit 23bf1ca771

23bf1ca771 static fixes (#578)
This commit is contained in:
Tomas Votruba 2021-08-02 19:35:36 +00:00
parent 9f06a1c1d2
commit b1a34f7f49
11 changed files with 31 additions and 28 deletions

View File

@ -3,14 +3,14 @@
declare (strict_types=1);
namespace Rector\Caching;
use Rector\Caching\ValueObject\Storage\CacheStorageInterface;
use Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface;
final class Cache
{
/**
* @var \Rector\Caching\ValueObject\Storage\CacheStorageInterface
* @var \Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface
*/
private $cacheStorage;
public function __construct(\Rector\Caching\ValueObject\Storage\CacheStorageInterface $cacheStorage)
public function __construct(\Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface $cacheStorage)
{
$this->cacheStorage = $cacheStorage;
}

View File

@ -1,10 +1,11 @@
<?php
declare (strict_types=1);
namespace Rector\Caching\ValueObject\Storage;
namespace Rector\Caching\Contract\ValueObject\Storage;
/**
* inspired by https://github.com/phpstan/phpstan-src/blob/560652088406d7461c2c4ad4897784e33f8ab312/src/Cache/CacheStorage.php
* @internal
*/
interface CacheStorageInterface
{

View File

@ -5,6 +5,7 @@ namespace Rector\Caching\ValueObject\Storage;
use RectorPrefix20210802\Nette\Utils\Random;
use PHPStan\File\FileWriter;
use Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface;
use Rector\Caching\ValueObject\CacheFilePaths;
use Rector\Caching\ValueObject\CacheItem;
use RectorPrefix20210802\Symplify\EasyCodingStandard\Caching\Exception\CachingException;
@ -12,7 +13,7 @@ use RectorPrefix20210802\Symplify\SmartFileSystem\SmartFileSystem;
/**
* Inspired by https://github.com/phpstan/phpstan-src/blob/1e7ceae933f07e5a250b61ed94799e6c2ea8daa2/src/Cache/FileCacheStorage.php
*/
final class FileCacheStorage implements \Rector\Caching\ValueObject\Storage\CacheStorageInterface
final class FileCacheStorage implements \Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface
{
/**
* @var string

View File

@ -3,11 +3,12 @@
declare (strict_types=1);
namespace Rector\Caching\ValueObject\Storage;
use Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface;
use Rector\Caching\ValueObject\CacheItem;
/**
* inspired by https://github.com/phpstan/phpstan-src/blob/560652088406d7461c2c4ad4897784e33f8ab312/src/Cache/MemoryCacheStorage.php
*/
final class MemoryCacheStorage implements \Rector\Caching\ValueObject\Storage\CacheStorageInterface
final class MemoryCacheStorage implements \Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface
{
/**
* @var array<string, CacheItem>

View File

@ -16,11 +16,11 @@ final class VersionResolver
/**
* @var string
*/
public const PACKAGE_VERSION = 'd936944aedeaa6687e4eeca55aab8148e9104436';
public const PACKAGE_VERSION = '23bf1ca7716bc88387095b541df97b5f7ae28b83';
/**
* @var string
*/
public const RELEASE_DATE = '2021-08-02 19:12:49';
public const RELEASE_DATE = '2021-08-02 19:24:42';
public static function resolvePackageVersion() : string
{
$process = new \RectorPrefix20210802\Symfony\Component\Process\Process(['git', 'log', '--pretty="%H"', '-n1', 'HEAD'], __DIR__);

View File

@ -4,7 +4,7 @@ declare (strict_types=1);
namespace Rector\Core\Configuration;
use RectorPrefix20210802\JetBrains\PhpStorm\Immutable;
use Rector\Caching\ValueObject\Storage\CacheStorageInterface;
use Rector\Caching\Contract\ValueObject\Storage\CacheStorageInterface;
use Rector\Caching\ValueObject\Storage\FileCacheStorage;
use RectorPrefix20210802\Symplify\Skipper\ValueObject\Option as SkipperOption;
#[Immutable]

2
vendor/autoload.php vendored
View File

@ -4,4 +4,4 @@
require_once __DIR__ . '/composer/autoload_real.php';
return ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f::getLoader();
return ComposerAutoloaderInitd8a9aaa2b52fb9b102bd3cacf27931d6::getLoader();

View File

@ -1563,13 +1563,13 @@ return array(
'Rector\\Caching\\Cache' => $baseDir . '/packages/Caching/Cache.php',
'Rector\\Caching\\CacheFactory' => $baseDir . '/packages/Caching/CacheFactory.php',
'Rector\\Caching\\Config\\FileHashComputer' => $baseDir . '/packages/Caching/Config/FileHashComputer.php',
'Rector\\Caching\\Contract\\ValueObject\\Storage\\CacheStorageInterface' => $baseDir . '/packages/Caching/Contract/ValueObject/Storage/CacheStorageInterface.php',
'Rector\\Caching\\Detector\\ChangedFilesDetector' => $baseDir . '/packages/Caching/Detector/ChangedFilesDetector.php',
'Rector\\Caching\\Enum\\CacheKey' => $baseDir . '/packages/Caching/Enum/CacheKey.php',
'Rector\\Caching\\FileSystem\\DependencyResolver' => $baseDir . '/packages/Caching/FileSystem/DependencyResolver.php',
'Rector\\Caching\\UnchangedFilesFilter' => $baseDir . '/packages/Caching/UnchangedFilesFilter.php',
'Rector\\Caching\\ValueObject\\CacheFilePaths' => $baseDir . '/packages/Caching/ValueObject/CacheFilePaths.php',
'Rector\\Caching\\ValueObject\\CacheItem' => $baseDir . '/packages/Caching/ValueObject/CacheItem.php',
'Rector\\Caching\\ValueObject\\Storage\\CacheStorageInterface' => $baseDir . '/packages/Caching/ValueObject/Storage/CacheStorageInterface.php',
'Rector\\Caching\\ValueObject\\Storage\\FileCacheStorage' => $baseDir . '/packages/Caching/ValueObject/Storage/FileCacheStorage.php',
'Rector\\Caching\\ValueObject\\Storage\\MemoryCacheStorage' => $baseDir . '/packages/Caching/ValueObject/Storage/MemoryCacheStorage.php',
'Rector\\CakePHP\\ImplicitNameResolver' => $vendorDir . '/rector/rector-cakephp/src/ImplicitNameResolver.php',

View File

@ -2,7 +2,7 @@
// autoload_real.php @generated by Composer
class ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f
class ComposerAutoloaderInitd8a9aaa2b52fb9b102bd3cacf27931d6
{
private static $loader;
@ -22,15 +22,15 @@ class ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f
return self::$loader;
}
spl_autoload_register(array('ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f', 'loadClassLoader'), true, true);
spl_autoload_register(array('ComposerAutoloaderInitd8a9aaa2b52fb9b102bd3cacf27931d6', 'loadClassLoader'), true, true);
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
spl_autoload_unregister(array('ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f', 'loadClassLoader'));
spl_autoload_unregister(array('ComposerAutoloaderInitd8a9aaa2b52fb9b102bd3cacf27931d6', 'loadClassLoader'));
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
if ($useStaticLoader) {
require __DIR__ . '/autoload_static.php';
call_user_func(\Composer\Autoload\ComposerStaticInit9d1c3a2b12d28540451b5b97491e8b4f::getInitializer($loader));
call_user_func(\Composer\Autoload\ComposerStaticInitd8a9aaa2b52fb9b102bd3cacf27931d6::getInitializer($loader));
} else {
$classMap = require __DIR__ . '/autoload_classmap.php';
if ($classMap) {
@ -42,19 +42,19 @@ class ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f
$loader->register(true);
if ($useStaticLoader) {
$includeFiles = Composer\Autoload\ComposerStaticInit9d1c3a2b12d28540451b5b97491e8b4f::$files;
$includeFiles = Composer\Autoload\ComposerStaticInitd8a9aaa2b52fb9b102bd3cacf27931d6::$files;
} else {
$includeFiles = require __DIR__ . '/autoload_files.php';
}
foreach ($includeFiles as $fileIdentifier => $file) {
composerRequire9d1c3a2b12d28540451b5b97491e8b4f($fileIdentifier, $file);
composerRequired8a9aaa2b52fb9b102bd3cacf27931d6($fileIdentifier, $file);
}
return $loader;
}
}
function composerRequire9d1c3a2b12d28540451b5b97491e8b4f($fileIdentifier, $file)
function composerRequired8a9aaa2b52fb9b102bd3cacf27931d6($fileIdentifier, $file)
{
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
require $file;

View File

@ -4,7 +4,7 @@
namespace Composer\Autoload;
class ComposerStaticInit9d1c3a2b12d28540451b5b97491e8b4f
class ComposerStaticInitd8a9aaa2b52fb9b102bd3cacf27931d6
{
public static $files = array (
'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php',
@ -1923,13 +1923,13 @@ class ComposerStaticInit9d1c3a2b12d28540451b5b97491e8b4f
'Rector\\Caching\\Cache' => __DIR__ . '/../..' . '/packages/Caching/Cache.php',
'Rector\\Caching\\CacheFactory' => __DIR__ . '/../..' . '/packages/Caching/CacheFactory.php',
'Rector\\Caching\\Config\\FileHashComputer' => __DIR__ . '/../..' . '/packages/Caching/Config/FileHashComputer.php',
'Rector\\Caching\\Contract\\ValueObject\\Storage\\CacheStorageInterface' => __DIR__ . '/../..' . '/packages/Caching/Contract/ValueObject/Storage/CacheStorageInterface.php',
'Rector\\Caching\\Detector\\ChangedFilesDetector' => __DIR__ . '/../..' . '/packages/Caching/Detector/ChangedFilesDetector.php',
'Rector\\Caching\\Enum\\CacheKey' => __DIR__ . '/../..' . '/packages/Caching/Enum/CacheKey.php',
'Rector\\Caching\\FileSystem\\DependencyResolver' => __DIR__ . '/../..' . '/packages/Caching/FileSystem/DependencyResolver.php',
'Rector\\Caching\\UnchangedFilesFilter' => __DIR__ . '/../..' . '/packages/Caching/UnchangedFilesFilter.php',
'Rector\\Caching\\ValueObject\\CacheFilePaths' => __DIR__ . '/../..' . '/packages/Caching/ValueObject/CacheFilePaths.php',
'Rector\\Caching\\ValueObject\\CacheItem' => __DIR__ . '/../..' . '/packages/Caching/ValueObject/CacheItem.php',
'Rector\\Caching\\ValueObject\\Storage\\CacheStorageInterface' => __DIR__ . '/../..' . '/packages/Caching/ValueObject/Storage/CacheStorageInterface.php',
'Rector\\Caching\\ValueObject\\Storage\\FileCacheStorage' => __DIR__ . '/../..' . '/packages/Caching/ValueObject/Storage/FileCacheStorage.php',
'Rector\\Caching\\ValueObject\\Storage\\MemoryCacheStorage' => __DIR__ . '/../..' . '/packages/Caching/ValueObject/Storage/MemoryCacheStorage.php',
'Rector\\CakePHP\\ImplicitNameResolver' => __DIR__ . '/..' . '/rector/rector-cakephp/src/ImplicitNameResolver.php',
@ -3847,9 +3847,9 @@ class ComposerStaticInit9d1c3a2b12d28540451b5b97491e8b4f
public static function getInitializer(ClassLoader $loader)
{
return \Closure::bind(function () use ($loader) {
$loader->prefixLengthsPsr4 = ComposerStaticInit9d1c3a2b12d28540451b5b97491e8b4f::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInit9d1c3a2b12d28540451b5b97491e8b4f::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInit9d1c3a2b12d28540451b5b97491e8b4f::$classMap;
$loader->prefixLengthsPsr4 = ComposerStaticInitd8a9aaa2b52fb9b102bd3cacf27931d6::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInitd8a9aaa2b52fb9b102bd3cacf27931d6::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInitd8a9aaa2b52fb9b102bd3cacf27931d6::$classMap;
}, null, ClassLoader::class);
}

View File

@ -9,8 +9,8 @@ $loader = require_once __DIR__.'/autoload.php';
if (!class_exists('AutoloadIncluder', false) && !interface_exists('AutoloadIncluder', false) && !trait_exists('AutoloadIncluder', false)) {
spl_autoload_call('RectorPrefix20210802\AutoloadIncluder');
}
if (!class_exists('ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f', false) && !interface_exists('ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f', false) && !trait_exists('ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f', false)) {
spl_autoload_call('RectorPrefix20210802\ComposerAutoloaderInit9d1c3a2b12d28540451b5b97491e8b4f');
if (!class_exists('ComposerAutoloaderInitd8a9aaa2b52fb9b102bd3cacf27931d6', false) && !interface_exists('ComposerAutoloaderInitd8a9aaa2b52fb9b102bd3cacf27931d6', false) && !trait_exists('ComposerAutoloaderInitd8a9aaa2b52fb9b102bd3cacf27931d6', false)) {
spl_autoload_call('RectorPrefix20210802\ComposerAutoloaderInitd8a9aaa2b52fb9b102bd3cacf27931d6');
}
if (!class_exists('Doctrine\Inflector\Inflector', false) && !interface_exists('Doctrine\Inflector\Inflector', false) && !trait_exists('Doctrine\Inflector\Inflector', false)) {
spl_autoload_call('RectorPrefix20210802\Doctrine\Inflector\Inflector');
@ -3308,9 +3308,9 @@ if (!function_exists('print_node')) {
return \RectorPrefix20210802\print_node(...func_get_args());
}
}
if (!function_exists('composerRequire9d1c3a2b12d28540451b5b97491e8b4f')) {
function composerRequire9d1c3a2b12d28540451b5b97491e8b4f() {
return \RectorPrefix20210802\composerRequire9d1c3a2b12d28540451b5b97491e8b4f(...func_get_args());
if (!function_exists('composerRequired8a9aaa2b52fb9b102bd3cacf27931d6')) {
function composerRequired8a9aaa2b52fb9b102bd3cacf27931d6() {
return \RectorPrefix20210802\composerRequired8a9aaa2b52fb9b102bd3cacf27931d6(...func_get_args());
}
}
if (!function_exists('parseArgs')) {