Skip to content

Commit

Permalink
Updated Rector to commit 18fbe1d
Browse files Browse the repository at this point in the history
rectorphp/rector-src@18fbe1d [Downgrade PHP 7.4] Add false to downgraded typed property (#1596)
  • Loading branch information
TomasVotruba committed Dec 30, 2021
1 parent 825d9bd commit 3110b1c
Show file tree
Hide file tree
Showing 13 changed files with 52 additions and 52 deletions.
4 changes: 2 additions & 2 deletions packages/NodeTypeResolver/PHPStan/Type/TypeFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ public function createMixedPassedOrUnionTypeAndKeepConstant(array $types) : \PHP
/**
* @param Type[] $types
*/
public function createMixedPassedOrUnionType(array $types) : \PHPStan\Type\Type
public function createMixedPassedOrUnionType(array $types, bool $keepConstantTypes = \false) : \PHPStan\Type\Type
{
$types = $this->unwrapUnionedTypes($types);
$types = $this->uniquateTypes($types);
$types = $this->uniquateTypes($types, $keepConstantTypes);
return $this->createUnionOrSingleType($types);
}
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,6 @@ public function mapToPHPStan(\PhpParser\Node $node) : \PHPStan\Type\Type
foreach ($node->types as $unionedType) {
$types[] = $this->phpParserNodeMapper->mapToPHPStanType($unionedType);
}
return $this->typeFactory->createMixedPassedOrUnionType($types);
return $this->typeFactory->createMixedPassedOrUnionType($types, \true);
}
}
4 changes: 2 additions & 2 deletions src/Application/VersionResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ final class VersionResolver
/**
* @var string
*/
public const PACKAGE_VERSION = '8648410c86d2775821b15ee20c3665dc1e34a806';
public const PACKAGE_VERSION = '18fbe1d0ded286436557c3ecc3e91cf553efb6c9';
/**
* @var string
*/
public const RELEASE_DATE = '2021-12-30 15:54:54';
public const RELEASE_DATE = '2021-12-30 16:16:50';
public static function resolvePackageVersion() : string
{
$process = new \RectorPrefix20211230\Symfony\Component\Process\Process(['git', 'log', '--pretty="%H"', '-n1', 'HEAD'], __DIR__);
Expand Down
2 changes: 1 addition & 1 deletion vendor/autoload.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@

require_once __DIR__ . '/composer/autoload_real.php';

return ComposerAutoloaderInit8dcd277f4f9bfb02febf0cacdd15558d::getLoader();
return ComposerAutoloaderInit8203956131c6cfe5b66f36bf3d4dc10e::getLoader();
14 changes: 7 additions & 7 deletions vendor/composer/autoload_real.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

// autoload_real.php @generated by Composer

class ComposerAutoloaderInit8dcd277f4f9bfb02febf0cacdd15558d
class ComposerAutoloaderInit8203956131c6cfe5b66f36bf3d4dc10e
{
private static $loader;

Expand All @@ -22,15 +22,15 @@ public static function getLoader()
return self::$loader;
}

spl_autoload_register(array('ComposerAutoloaderInit8dcd277f4f9bfb02febf0cacdd15558d', 'loadClassLoader'), true, true);
spl_autoload_register(array('ComposerAutoloaderInit8203956131c6cfe5b66f36bf3d4dc10e', 'loadClassLoader'), true, true);
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
spl_autoload_unregister(array('ComposerAutoloaderInit8dcd277f4f9bfb02febf0cacdd15558d', 'loadClassLoader'));
spl_autoload_unregister(array('ComposerAutoloaderInit8203956131c6cfe5b66f36bf3d4dc10e', '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\ComposerStaticInit8dcd277f4f9bfb02febf0cacdd15558d::getInitializer($loader));
call_user_func(\Composer\Autoload\ComposerStaticInit8203956131c6cfe5b66f36bf3d4dc10e::getInitializer($loader));
} else {
$classMap = require __DIR__ . '/autoload_classmap.php';
if ($classMap) {
Expand All @@ -42,12 +42,12 @@ public static function getLoader()
$loader->register(true);

if ($useStaticLoader) {
$includeFiles = Composer\Autoload\ComposerStaticInit8dcd277f4f9bfb02febf0cacdd15558d::$files;
$includeFiles = Composer\Autoload\ComposerStaticInit8203956131c6cfe5b66f36bf3d4dc10e::$files;
} else {
$includeFiles = require __DIR__ . '/autoload_files.php';
}
foreach ($includeFiles as $fileIdentifier => $file) {
composerRequire8dcd277f4f9bfb02febf0cacdd15558d($fileIdentifier, $file);
composerRequire8203956131c6cfe5b66f36bf3d4dc10e($fileIdentifier, $file);
}

return $loader;
Expand All @@ -59,7 +59,7 @@ public static function getLoader()
* @param string $file
* @return void
*/
function composerRequire8dcd277f4f9bfb02febf0cacdd15558d($fileIdentifier, $file)
function composerRequire8203956131c6cfe5b66f36bf3d4dc10e($fileIdentifier, $file)
{
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
Expand Down
8 changes: 4 additions & 4 deletions vendor/composer/autoload_static.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Composer\Autoload;

class ComposerStaticInit8dcd277f4f9bfb02febf0cacdd15558d
class ComposerStaticInit8203956131c6cfe5b66f36bf3d4dc10e
{
public static $files = array (
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php',
Expand Down Expand Up @@ -3844,9 +3844,9 @@ class ComposerStaticInit8dcd277f4f9bfb02febf0cacdd15558d
public static function getInitializer(ClassLoader $loader)
{
return \Closure::bind(function () use ($loader) {
$loader->prefixLengthsPsr4 = ComposerStaticInit8dcd277f4f9bfb02febf0cacdd15558d::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInit8dcd277f4f9bfb02febf0cacdd15558d::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInit8dcd277f4f9bfb02febf0cacdd15558d::$classMap;
$loader->prefixLengthsPsr4 = ComposerStaticInit8203956131c6cfe5b66f36bf3d4dc10e::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInit8203956131c6cfe5b66f36bf3d4dc10e::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInit8203956131c6cfe5b66f36bf3d4dc10e::$classMap;

}, null, ClassLoader::class);
}
Expand Down
10 changes: 5 additions & 5 deletions vendor/scoper-autoload.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
if (!class_exists('AutoloadIncluder', false) && !interface_exists('AutoloadIncluder', false) && !trait_exists('AutoloadIncluder', false)) {
spl_autoload_call('RectorPrefix20211230\AutoloadIncluder');
}
if (!class_exists('ComposerAutoloaderInit8dcd277f4f9bfb02febf0cacdd15558d', false) && !interface_exists('ComposerAutoloaderInit8dcd277f4f9bfb02febf0cacdd15558d', false) && !trait_exists('ComposerAutoloaderInit8dcd277f4f9bfb02febf0cacdd15558d', false)) {
spl_autoload_call('RectorPrefix20211230\ComposerAutoloaderInit8dcd277f4f9bfb02febf0cacdd15558d');
if (!class_exists('ComposerAutoloaderInit8203956131c6cfe5b66f36bf3d4dc10e', false) && !interface_exists('ComposerAutoloaderInit8203956131c6cfe5b66f36bf3d4dc10e', false) && !trait_exists('ComposerAutoloaderInit8203956131c6cfe5b66f36bf3d4dc10e', false)) {
spl_autoload_call('RectorPrefix20211230\ComposerAutoloaderInit8203956131c6cfe5b66f36bf3d4dc10e');
}
if (!class_exists('Helmich\TypoScriptParser\Parser\AST\Statement', false) && !interface_exists('Helmich\TypoScriptParser\Parser\AST\Statement', false) && !trait_exists('Helmich\TypoScriptParser\Parser\AST\Statement', false)) {
spl_autoload_call('RectorPrefix20211230\Helmich\TypoScriptParser\Parser\AST\Statement');
Expand Down Expand Up @@ -78,9 +78,9 @@ function print_node() {
return \RectorPrefix20211230\print_node(...func_get_args());
}
}
if (!function_exists('composerRequire8dcd277f4f9bfb02febf0cacdd15558d')) {
function composerRequire8dcd277f4f9bfb02febf0cacdd15558d() {
return \RectorPrefix20211230\composerRequire8dcd277f4f9bfb02febf0cacdd15558d(...func_get_args());
if (!function_exists('composerRequire8203956131c6cfe5b66f36bf3d4dc10e')) {
function composerRequire8203956131c6cfe5b66f36bf3d4dc10e() {
return \RectorPrefix20211230\composerRequire8203956131c6cfe5b66f36bf3d4dc10e(...func_get_args());
}
}
if (!function_exists('scanPath')) {
Expand Down
6 changes: 3 additions & 3 deletions vendor/symfony/console/Helper/QuestionHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ private function isInteractiveInput($inputStream) : bool
*
* @param resource $inputStream The handler resource
* @param Question $question The question being asked
* @return bool|string
* @return string|true
*/
private function readInput($inputStream, \RectorPrefix20211230\Symfony\Component\Console\Question\Question $question)
{
Expand Down Expand Up @@ -450,8 +450,8 @@ private function setIOCodepage() : int
}
/**
* Sets console I/O to the specified code page and converts the user input.
* @param bool|string $input
* @return bool|string
* @param string|true $input
* @return string|true
*/
private function resetIOCodepage(int $cp, $input)
{
Expand Down
2 changes: 1 addition & 1 deletion vendor/symfony/finder/Finder.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ class Finder implements \IteratorAggregate, \Countable
*/
private $reverseSorting = \false;
/**
* @var bool|\Closure|int
* @var \Closure|int|true
*/
private $sort = \false;
/**
Expand Down
18 changes: 9 additions & 9 deletions vendor/symfony/polyfill-intl-grapheme/bootstrap80.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
}
if (!\function_exists('grapheme_extract')) {
/**
* @return bool|string
* @return string|true
*/
function grapheme_extract(?string $haystack, ?int $size, ?int $type = \GRAPHEME_EXTR_COUNT, ?int $offset = 0, &$next = null)
{
Expand All @@ -31,7 +31,7 @@ function grapheme_extract(?string $haystack, ?int $size, ?int $type = \GRAPHEME_
}
if (!\function_exists('grapheme_stripos')) {
/**
* @return bool|int
* @return int|true
*/
function grapheme_stripos(?string $haystack, ?string $needle, ?int $offset = 0)
{
Expand All @@ -40,7 +40,7 @@ function grapheme_stripos(?string $haystack, ?string $needle, ?int $offset = 0)
}
if (!\function_exists('grapheme_stristr')) {
/**
* @return bool|string
* @return string|true
*/
function grapheme_stristr(?string $haystack, ?string $needle, ?bool $beforeNeedle = \false)
{
Expand All @@ -49,7 +49,7 @@ function grapheme_stristr(?string $haystack, ?string $needle, ?bool $beforeNeedl
}
if (!\function_exists('grapheme_strlen')) {
/**
* @return bool|int|null
* @return int|true|null
*/
function grapheme_strlen(?string $string)
{
Expand All @@ -58,7 +58,7 @@ function grapheme_strlen(?string $string)
}
if (!\function_exists('grapheme_strpos')) {
/**
* @return bool|int
* @return int|true
*/
function grapheme_strpos(?string $haystack, ?string $needle, ?int $offset = 0)
{
Expand All @@ -67,7 +67,7 @@ function grapheme_strpos(?string $haystack, ?string $needle, ?int $offset = 0)
}
if (!\function_exists('grapheme_strripos')) {
/**
* @return bool|int
* @return int|true
*/
function grapheme_strripos(?string $haystack, ?string $needle, ?int $offset = 0)
{
Expand All @@ -76,7 +76,7 @@ function grapheme_strripos(?string $haystack, ?string $needle, ?int $offset = 0)
}
if (!\function_exists('grapheme_strrpos')) {
/**
* @return bool|int
* @return int|true
*/
function grapheme_strrpos(?string $haystack, ?string $needle, ?int $offset = 0)
{
Expand All @@ -85,7 +85,7 @@ function grapheme_strrpos(?string $haystack, ?string $needle, ?int $offset = 0)
}
if (!\function_exists('grapheme_strstr')) {
/**
* @return bool|string
* @return string|true
*/
function grapheme_strstr(?string $haystack, ?string $needle, ?bool $beforeNeedle = \false)
{
Expand All @@ -94,7 +94,7 @@ function grapheme_strstr(?string $haystack, ?string $needle, ?bool $beforeNeedle
}
if (!\function_exists('grapheme_substr')) {
/**
* @return bool|string
* @return string|true
*/
function grapheme_substr(?string $string, ?int $offset, ?int $length = null)
{
Expand Down
2 changes: 1 addition & 1 deletion vendor/symfony/polyfill-intl-normalizer/bootstrap80.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ function normalizer_is_normalized(?string $string, ?int $form = \RectorPrefix202
}
if (!\function_exists('normalizer_normalize')) {
/**
* @return bool|string
* @return string|true
*/
function normalizer_normalize(?string $string, ?int $form = \RectorPrefix20211230\Symfony\Polyfill\Intl\Normalizer\Normalizer::FORM_C)
{
Expand Down
30 changes: 15 additions & 15 deletions vendor/symfony/polyfill-mbstring/bootstrap80.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
/**
* @param mixed[]|string|null $string
* @param mixed[]|string|null $from_encoding
* @return mixed[]|bool|string
* @return mixed[]|string|true
*/
function mb_convert_encoding($string, ?string $to_encoding, $from_encoding = null)
{
Expand Down Expand Up @@ -94,7 +94,7 @@ function mb_check_encoding($value = null, ?string $encoding = null) : bool
if (!\function_exists('mb_detect_encoding')) {
/**
* @param mixed[]|string|null $encodings
* @return bool|string
* @return string|true
*/
function mb_detect_encoding(?string $string, $encodings = null, ?bool $strict = \false)
{
Expand Down Expand Up @@ -126,7 +126,7 @@ function mb_strlen(?string $string, ?string $encoding = null) : int
}
if (!\function_exists('mb_strpos')) {
/**
* @return bool|int
* @return int|true
*/
function mb_strpos(?string $haystack, ?string $needle, ?int $offset = 0, ?string $encoding = null)
{
Expand Down Expand Up @@ -163,7 +163,7 @@ function mb_substr(?string $string, ?int $start, ?int $length = null, ?string $e
}
if (!\function_exists('mb_stripos')) {
/**
* @return bool|int
* @return int|true
*/
function mb_stripos(?string $haystack, ?string $needle, ?int $offset = 0, ?string $encoding = null)
{
Expand All @@ -172,7 +172,7 @@ function mb_stripos(?string $haystack, ?string $needle, ?int $offset = 0, ?strin
}
if (!\function_exists('mb_stristr')) {
/**
* @return bool|string
* @return string|true
*/
function mb_stristr(?string $haystack, ?string $needle, ?bool $before_needle = \false, ?string $encoding = null)
{
Expand All @@ -181,7 +181,7 @@ function mb_stristr(?string $haystack, ?string $needle, ?bool $before_needle = \
}
if (!\function_exists('mb_strrchr')) {
/**
* @return bool|string
* @return string|true
*/
function mb_strrchr(?string $haystack, ?string $needle, ?bool $before_needle = \false, ?string $encoding = null)
{
Expand All @@ -190,7 +190,7 @@ function mb_strrchr(?string $haystack, ?string $needle, ?bool $before_needle = \
}
if (!\function_exists('mb_strrichr')) {
/**
* @return bool|string
* @return string|true
*/
function mb_strrichr(?string $haystack, ?string $needle, ?bool $before_needle = \false, ?string $encoding = null)
{
Expand All @@ -199,7 +199,7 @@ function mb_strrichr(?string $haystack, ?string $needle, ?bool $before_needle =
}
if (!\function_exists('mb_strripos')) {
/**
* @return bool|int
* @return int|true
*/
function mb_strripos(?string $haystack, ?string $needle, ?int $offset = 0, ?string $encoding = null)
{
Expand All @@ -208,7 +208,7 @@ function mb_strripos(?string $haystack, ?string $needle, ?int $offset = 0, ?stri
}
if (!\function_exists('mb_strrpos')) {
/**
* @return bool|int
* @return int|true
*/
function mb_strrpos(?string $haystack, ?string $needle, ?int $offset = 0, ?string $encoding = null)
{
Expand All @@ -217,7 +217,7 @@ function mb_strrpos(?string $haystack, ?string $needle, ?int $offset = 0, ?strin
}
if (!\function_exists('mb_strstr')) {
/**
* @return bool|string
* @return string|true
*/
function mb_strstr(?string $haystack, ?string $needle, ?bool $before_needle = \false, ?string $encoding = null)
{
Expand All @@ -226,7 +226,7 @@ function mb_strstr(?string $haystack, ?string $needle, ?bool $before_needle = \f
}
if (!\function_exists('mb_get_info')) {
/**
* @return mixed[]|bool|int|string
* @return mixed[]|int|string|true
*/
function mb_get_info(?string $type = 'all')
{
Expand Down Expand Up @@ -262,7 +262,7 @@ function mb_output_handler(?string $string, ?int $status) : string
}
if (!\function_exists('mb_http_input')) {
/**
* @return mixed[]|bool|string
* @return mixed[]|string|true
*/
function mb_http_input(?string $type = null)
{
Expand All @@ -272,7 +272,7 @@ function mb_http_input(?string $type = null)
if (!\function_exists('mb_convert_variables')) {
/**
* @param mixed[]|string|null $from_encoding
* @return bool|string
* @return string|true
* @param mixed $var
* @param mixed ...$vars
*/
Expand All @@ -283,7 +283,7 @@ function mb_convert_variables(?string $to_encoding, $from_encoding, &$var, &...$
}
if (!\function_exists('mb_ord')) {
/**
* @return bool|int
* @return int|true
*/
function mb_ord(?string $string, ?string $encoding = null)
{
Expand All @@ -292,7 +292,7 @@ function mb_ord(?string $string, ?string $encoding = null)
}
if (!\function_exists('mb_chr')) {
/**
* @return bool|string
* @return string|true
*/
function mb_chr(?int $codepoint, ?string $encoding = null)
{
Expand Down
Loading

0 comments on commit 3110b1c

Please sign in to comment.