Updated Rector to commit 335cc6fe7b141951a7cc3cc0cf4eaaf3711edf96

335cc6fe7b [BetterPhpDocParser] Reduce regex on opening docblock check on PhpDocInfoPrinter (#4962)
This commit is contained in:
Tomas Votruba 2023-09-10 04:56:06 +00:00
parent 6c9ddbbc05
commit 561662bcb2
5 changed files with 13 additions and 18 deletions

View File

@ -51,11 +51,6 @@ final class PhpDocInfoPrinter
* @see https://regex101.com/r/Ab0Vey/1
*/
private const CLOSING_DOCBLOCK_REGEX = '#\\*\\/(\\s+)?$#';
/**
* @var string
* @see https://regex101.com/r/mVmOCY/2
*/
private const OPENING_DOCBLOCK_REGEX = '#^(/\\*\\*)#';
/**
* @var string
* @see https://regex101.com/r/5fJyws/1
@ -168,7 +163,7 @@ final class PhpDocInfoPrinter
$output = '/**' . $output;
}
// fix missing end
if (StringUtils::isMatch($output, self::OPENING_DOCBLOCK_REGEX) && !StringUtils::isMatch($output, self::CLOSING_DOCBLOCK_REGEX)) {
if (\strncmp($output, '/**', \strlen('/**')) === 0 && !StringUtils::isMatch($output, self::CLOSING_DOCBLOCK_REGEX)) {
$output .= ' */';
}
return \str_replace(" \n", "\n", $output);

View File

@ -19,12 +19,12 @@ final class VersionResolver
* @api
* @var string
*/
public const PACKAGE_VERSION = '57772d141822690d98070403e486e6c43c73f2cd';
public const PACKAGE_VERSION = '335cc6fe7b141951a7cc3cc0cf4eaaf3711edf96';
/**
* @api
* @var string
*/
public const RELEASE_DATE = '2023-09-10 11:25:19';
public const RELEASE_DATE = '2023-09-10 11:53:30';
/**
* @var int
*/

2
vendor/autoload.php vendored
View File

@ -22,4 +22,4 @@ if (PHP_VERSION_ID < 50600) {
require_once __DIR__ . '/composer/autoload_real.php';
return ComposerAutoloaderInit436e53f56b5b255878ebce9e364acbed::getLoader();
return ComposerAutoloaderInitb3ef4525e65899edc071ae676c678403::getLoader();

View File

@ -2,7 +2,7 @@
// autoload_real.php @generated by Composer
class ComposerAutoloaderInit436e53f56b5b255878ebce9e364acbed
class ComposerAutoloaderInitb3ef4525e65899edc071ae676c678403
{
private static $loader;
@ -22,17 +22,17 @@ class ComposerAutoloaderInit436e53f56b5b255878ebce9e364acbed
return self::$loader;
}
spl_autoload_register(array('ComposerAutoloaderInit436e53f56b5b255878ebce9e364acbed', 'loadClassLoader'), true, true);
spl_autoload_register(array('ComposerAutoloaderInitb3ef4525e65899edc071ae676c678403', 'loadClassLoader'), true, true);
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
spl_autoload_unregister(array('ComposerAutoloaderInit436e53f56b5b255878ebce9e364acbed', 'loadClassLoader'));
spl_autoload_unregister(array('ComposerAutoloaderInitb3ef4525e65899edc071ae676c678403', 'loadClassLoader'));
require __DIR__ . '/autoload_static.php';
call_user_func(\Composer\Autoload\ComposerStaticInit436e53f56b5b255878ebce9e364acbed::getInitializer($loader));
call_user_func(\Composer\Autoload\ComposerStaticInitb3ef4525e65899edc071ae676c678403::getInitializer($loader));
$loader->setClassMapAuthoritative(true);
$loader->register(true);
$filesToLoad = \Composer\Autoload\ComposerStaticInit436e53f56b5b255878ebce9e364acbed::$files;
$filesToLoad = \Composer\Autoload\ComposerStaticInitb3ef4525e65899edc071ae676c678403::$files;
$requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;

View File

@ -4,7 +4,7 @@
namespace Composer\Autoload;
class ComposerStaticInit436e53f56b5b255878ebce9e364acbed
class ComposerStaticInitb3ef4525e65899edc071ae676c678403
{
public static $files = array (
'ad155f8f1cf0d418fe49e248db8c661b' => __DIR__ . '/..' . '/react/promise/src/functions_include.php',
@ -2599,9 +2599,9 @@ class ComposerStaticInit436e53f56b5b255878ebce9e364acbed
public static function getInitializer(ClassLoader $loader)
{
return \Closure::bind(function () use ($loader) {
$loader->prefixLengthsPsr4 = ComposerStaticInit436e53f56b5b255878ebce9e364acbed::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInit436e53f56b5b255878ebce9e364acbed::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInit436e53f56b5b255878ebce9e364acbed::$classMap;
$loader->prefixLengthsPsr4 = ComposerStaticInitb3ef4525e65899edc071ae676c678403::$prefixLengthsPsr4;
$loader->prefixDirsPsr4 = ComposerStaticInitb3ef4525e65899edc071ae676c678403::$prefixDirsPsr4;
$loader->classMap = ComposerStaticInitb3ef4525e65899edc071ae676c678403::$classMap;
}, null, ClassLoader::class);
}