Skip to content

Commit

Permalink
Updated Rector to commit 643c444d936e692a8a0224b7e7c81a74be40d398
Browse files Browse the repository at this point in the history
rectorphp/rector-src@643c444 [automated] Re-Generate Nodes/Rectors Documentation (#2956)
  • Loading branch information
TomasVotruba committed Sep 25, 2022
1 parent debee17 commit 0c28bef
Show file tree
Hide file tree
Showing 5 changed files with 75 additions and 16 deletions.
63 changes: 61 additions & 2 deletions docs/rector_rules_overview.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# 395 Rules Overview
# 398 Rules Overview

<br>

## Categories

- [Arguments](#arguments) (5)

- [CodeQuality](#codequality) (72)
- [CodeQuality](#codequality) (75)

- [CodingStyle](#codingstyle) (36)

Expand Down Expand Up @@ -385,6 +385,25 @@ Negated identical boolean compare to not identical compare (does not apply to no

<br>

### BoolvalToTypeCastRector

Change `boolval()` to faster and readable (bool) `$value`

- class: [`Rector\CodeQuality\Rector\FuncCall\BoolvalToTypeCastRector`](../rules/CodeQuality/Rector/FuncCall/BoolvalToTypeCastRector.php)

```diff
class SomeClass
{
public function run($value)
{
- return boolval($value);
+ return (bool) $value;
}
}
```

<br>

### CallUserFuncWithArrowFunctionToInlineRector

Refactor `call_user_func()` with arrow function to direct call
Expand Down Expand Up @@ -674,6 +693,27 @@ Flip type control to use exclusive type

<br>

### FloatvalToTypeCastRector

Change `floatval()` and `doubleval()` to faster and readable (float) `$value`

- class: [`Rector\CodeQuality\Rector\FuncCall\FloatvalToTypeCastRector`](../rules/CodeQuality/Rector/FuncCall/FloatvalToTypeCastRector.php)

```diff
class SomeClass
{
public function run($value)
{
- $a = floatval($value);
- $b = doubleval($value);
+ $a = (float) $value;
+ $b = (float) $value;
}
}
```

<br>

### ForRepeatedCountToOwnVariableRector

Change `count()` in for function to own variable
Expand Down Expand Up @@ -1539,6 +1579,25 @@ Changes strlen comparison to 0 to direct empty string compare

<br>

### StrvalToTypeCastRector

Change `strval()` to faster and readable (string) `$value`

- class: [`Rector\CodeQuality\Rector\FuncCall\StrvalToTypeCastRector`](../rules/CodeQuality/Rector/FuncCall/StrvalToTypeCastRector.php)

```diff
class SomeClass
{
public function run($value)
{
- return strval($value);
+ return (string) $value;
}
}
```

<br>

### SwitchNegatedTernaryRector

Switch negated ternary condition rector
Expand Down
4 changes: 2 additions & 2 deletions src/Application/VersionResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ final class VersionResolver
* @api
* @var string
*/
public const PACKAGE_VERSION = '6b3ce0af37a7fbae87d06e43bc485616bf81be3e';
public const PACKAGE_VERSION = '643c444d936e692a8a0224b7e7c81a74be40d398';
/**
* @api
* @var string
*/
public const RELEASE_DATE = '2022-09-24 22:10:53';
public const RELEASE_DATE = '2022-09-25 00:32:52';
/**
* @var int
*/
Expand Down
2 changes: 1 addition & 1 deletion vendor/autoload.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@

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

return ComposerAutoloaderInitea4ec46d1ab136189f61540ac43e5d68::getLoader();
return ComposerAutoloaderInit6f996a84018146e04a5217d95e34e960::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 ComposerAutoloaderInitea4ec46d1ab136189f61540ac43e5d68
class ComposerAutoloaderInit6f996a84018146e04a5217d95e34e960
{
private static $loader;

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

spl_autoload_register(array('ComposerAutoloaderInitea4ec46d1ab136189f61540ac43e5d68', 'loadClassLoader'), true, true);
spl_autoload_register(array('ComposerAutoloaderInit6f996a84018146e04a5217d95e34e960', 'loadClassLoader'), true, true);
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
spl_autoload_unregister(array('ComposerAutoloaderInitea4ec46d1ab136189f61540ac43e5d68', 'loadClassLoader'));
spl_autoload_unregister(array('ComposerAutoloaderInit6f996a84018146e04a5217d95e34e960', 'loadClassLoader'));

require __DIR__ . '/autoload_static.php';
call_user_func(\Composer\Autoload\ComposerStaticInitea4ec46d1ab136189f61540ac43e5d68::getInitializer($loader));
call_user_func(\Composer\Autoload\ComposerStaticInit6f996a84018146e04a5217d95e34e960::getInitializer($loader));

$loader->setClassMapAuthoritative(true);
$loader->register(true);

$includeFiles = \Composer\Autoload\ComposerStaticInitea4ec46d1ab136189f61540ac43e5d68::$files;
$includeFiles = \Composer\Autoload\ComposerStaticInit6f996a84018146e04a5217d95e34e960::$files;
foreach ($includeFiles as $fileIdentifier => $file) {
composerRequireea4ec46d1ab136189f61540ac43e5d68($fileIdentifier, $file);
composerRequire6f996a84018146e04a5217d95e34e960($fileIdentifier, $file);
}

return $loader;
Expand All @@ -46,7 +46,7 @@ public static function getLoader()
* @param string $file
* @return void
*/
function composerRequireea4ec46d1ab136189f61540ac43e5d68($fileIdentifier, $file)
function composerRequire6f996a84018146e04a5217d95e34e960($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 ComposerStaticInitea4ec46d1ab136189f61540ac43e5d68
class ComposerStaticInit6f996a84018146e04a5217d95e34e960
{
public static $files = array (
'ad155f8f1cf0d418fe49e248db8c661b' => __DIR__ . '/..' . '/react/promise/src/functions_include.php',
Expand Down Expand Up @@ -3107,9 +3107,9 @@ class ComposerStaticInitea4ec46d1ab136189f61540ac43e5d68
public static function getInitializer(ClassLoader $loader)
{
return \Closure::bind(function () use ($loader) {
$loader->prefixLengthsPsr4 = ComposerStaticInitea4ec46d1ab136189f61540ac43e5d68::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInitea4ec46d1ab136189f61540ac43e5d68::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInitea4ec46d1ab136189f61540ac43e5d68::$classMap;
$loader->prefixLengthsPsr4 = ComposerStaticInit6f996a84018146e04a5217d95e34e960::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInit6f996a84018146e04a5217d95e34e960::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInit6f996a84018146e04a5217d95e34e960::$classMap;

}, null, ClassLoader::class);
}
Expand Down

0 comments on commit 0c28bef

Please sign in to comment.