Skip to content

Commit

Permalink
Vendor-Updates (#5903)
Browse files Browse the repository at this point in the history
  • Loading branch information
gharlan committed Feb 7, 2024
1 parent 2c37a5e commit 9ee297c
Show file tree
Hide file tree
Showing 10 changed files with 158 additions and 29 deletions.
4 changes: 2 additions & 2 deletions composer.json
Expand Up @@ -22,7 +22,7 @@
"phpunit/phpunit": "^10.0.7",
"psalm/plugin-phpunit": "0.18.4",
"psalm/plugin-symfony": "v5.1.0",
"rector/rector": "0.19.6",
"rector/rector": "1.0.0",
"redaxo/php-cs-fixer-config": "2.5.0",
"redaxo/psalm-plugin": "2.0.0",
"vimeo/psalm": "5.21.1"
Expand All @@ -47,7 +47,7 @@
"symfony/polyfill-ctype": "*",
"symfony/polyfill-php80": "*",
"symfony/polyfill-php81": "*",
"symfony/polyfill-php83": "v1.28.0",
"symfony/polyfill-php83": "v1.29.0",
"symfony/service-contracts": "v3.4.1",
"symfony/string": "v6.4.3",
"symfony/var-dumper": "v6.4.3",
Expand Down
15 changes: 6 additions & 9 deletions redaxo/src/core/composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions redaxo/src/core/vendor/composer/autoload_classmap.php
Expand Up @@ -85,6 +85,7 @@
'Ramsey\\Http\\Range\\Unit\\UnitInterface' => $vendorDir . '/ramsey/http-range/src/Unit/UnitInterface.php',
'Ramsey\\Http\\Range\\Unit\\UnitRangeInterface' => $vendorDir . '/ramsey/http-range/src/Unit/UnitRangeInterface.php',
'Ramsey\\Http\\Range\\Unit\\UnitRangesCollection' => $vendorDir . '/ramsey/http-range/src/Unit/UnitRangesCollection.php',
'SQLite3Exception' => $vendorDir . '/symfony/polyfill-php83/Resources/stubs/SQLite3Exception.php',
'Symfony\\Component\\Console\\Application' => $vendorDir . '/symfony/console/Application.php',
'Symfony\\Component\\Console\\Attribute\\AsCommand' => $vendorDir . '/symfony/console/Attribute/AsCommand.php',
'Symfony\\Component\\Console\\CI\\GithubActionReporter' => $vendorDir . '/symfony/console/CI/GithubActionReporter.php',
Expand Down
1 change: 1 addition & 0 deletions redaxo/src/core/vendor/composer/autoload_static.php
Expand Up @@ -213,6 +213,7 @@ class ComposerStaticInitRedaxoCore
'Ramsey\\Http\\Range\\Unit\\UnitInterface' => __DIR__ . '/..' . '/ramsey/http-range/src/Unit/UnitInterface.php',
'Ramsey\\Http\\Range\\Unit\\UnitRangeInterface' => __DIR__ . '/..' . '/ramsey/http-range/src/Unit/UnitRangeInterface.php',
'Ramsey\\Http\\Range\\Unit\\UnitRangesCollection' => __DIR__ . '/..' . '/ramsey/http-range/src/Unit/UnitRangesCollection.php',
'SQLite3Exception' => __DIR__ . '/..' . '/symfony/polyfill-php83/Resources/stubs/SQLite3Exception.php',
'Symfony\\Component\\Console\\Application' => __DIR__ . '/..' . '/symfony/console/Application.php',
'Symfony\\Component\\Console\\Attribute\\AsCommand' => __DIR__ . '/..' . '/symfony/console/Attribute/AsCommand.php',
'Symfony\\Component\\Console\\CI\\GithubActionReporter' => __DIR__ . '/..' . '/symfony/console/CI/GithubActionReporter.php',
Expand Down
17 changes: 7 additions & 10 deletions redaxo/src/core/vendor/composer/installed.json
Expand Up @@ -811,29 +811,26 @@
},
{
"name": "symfony/polyfill-php83",
"version": "v1.28.0",
"version_normalized": "1.28.0.0",
"version": "v1.29.0",
"version_normalized": "1.29.0.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-php83.git",
"reference": "b0f46ebbeeeda3e9d2faebdfbf4b4eae9b59fa11"
"reference": "86fcae159633351e5fd145d1c47de6c528f8caff"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php83/zipball/b0f46ebbeeeda3e9d2faebdfbf4b4eae9b59fa11",
"reference": "b0f46ebbeeeda3e9d2faebdfbf4b4eae9b59fa11",
"url": "https://api.github.com/repos/symfony/polyfill-php83/zipball/86fcae159633351e5fd145d1c47de6c528f8caff",
"reference": "86fcae159633351e5fd145d1c47de6c528f8caff",
"shasum": ""
},
"require": {
"php": ">=7.1",
"symfony/polyfill-php80": "^1.14"
},
"time": "2023-08-16T06:22:46+00:00",
"time": "2024-01-29T20:11:03+00:00",
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
Expand Down Expand Up @@ -874,7 +871,7 @@
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-php83/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-php83/tree/v1.29.0"
},
"funding": [
{
Expand Down
10 changes: 5 additions & 5 deletions redaxo/src/core/vendor/composer/installed.php
Expand Up @@ -3,7 +3,7 @@
'name' => '__root__',
'pretty_version' => 'dev-main',
'version' => 'dev-main',
'reference' => '86578d2766aee282c2d9c773ff0260c671c0f393',
'reference' => '2c37a5e7c80520fcc9da2b1f88d33ff431a6a887',
'type' => 'library',
'install_path' => __DIR__ . '/../../',
'aliases' => array(),
Expand All @@ -13,7 +13,7 @@
'__root__' => array(
'pretty_version' => 'dev-main',
'version' => 'dev-main',
'reference' => '86578d2766aee282c2d9c773ff0260c671c0f393',
'reference' => '2c37a5e7c80520fcc9da2b1f88d33ff431a6a887',
'type' => 'library',
'install_path' => __DIR__ . '/../../',
'aliases' => array(),
Expand Down Expand Up @@ -194,9 +194,9 @@
),
),
'symfony/polyfill-php83' => array(
'pretty_version' => 'v1.28.0',
'version' => '1.28.0.0',
'reference' => 'b0f46ebbeeeda3e9d2faebdfbf4b4eae9b59fa11',
'pretty_version' => 'v1.29.0',
'version' => '1.29.0.0',
'reference' => '86fcae159633351e5fd145d1c47de6c528f8caff',
'type' => 'library',
'install_path' => __DIR__ . '/../symfony/polyfill-php83',
'aliases' => array(),
Expand Down
112 changes: 112 additions & 0 deletions redaxo/src/core/vendor/symfony/polyfill-php83/Php83.php
Expand Up @@ -13,6 +13,7 @@

/**
* @author Ion Bazan <ion.bazan@gmail.com>
* @author Pierre Ambroise <pierre27.ambroise@gmail.com>
*
* @internal
*/
Expand Down Expand Up @@ -82,4 +83,115 @@ public static function mb_str_pad(string $string, int $length, string $pad_strin
return mb_substr(str_repeat($pad_string, $leftPaddingLength), 0, $leftPaddingLength, $encoding).$string.mb_substr(str_repeat($pad_string, $rightPaddingLength), 0, $rightPaddingLength, $encoding);
}
}

public static function str_increment(string $string): string
{
if ('' === $string) {
throw new \ValueError('str_increment(): Argument #1 ($string) cannot be empty');
}

if (!\preg_match("/^[a-zA-Z0-9]+$/", $string)) {
throw new \ValueError('str_increment(): Argument #1 ($string) must be composed only of alphanumeric ASCII characters');
}

if (\is_numeric($string)) {
$offset = stripos($string, 'e');
if ($offset !== false) {
$char = $string[$offset];
$char++;
$string[$offset] = $char;
$string++;

switch ($string[$offset]) {
case 'f':
$string[$offset] = 'e';
break;
case 'F':
$string[$offset] = 'E';
break;
case 'g':
$string[$offset] = 'f';
break;
case 'G':
$string[$offset] = 'F';
break;
}

return $string;
}
}

return ++$string;
}

public static function str_decrement(string $string): string
{
if ('' === $string) {
throw new \ValueError('str_decrement(): Argument #1 ($string) cannot be empty');
}

if (!\preg_match("/^[a-zA-Z0-9]+$/", $string)) {
throw new \ValueError('str_decrement(): Argument #1 ($string) must be composed only of alphanumeric ASCII characters');
}

if (\preg_match('/\A(?:0[aA0]?|[aA])\z/', $string)) {
throw new \ValueError(sprintf('str_decrement(): Argument #1 ($string) "%s" is out of decrement range', $string));
}

if (!\in_array(substr($string, -1), ['A', 'a', '0'], true)) {
return join('', array_slice(str_split($string), 0, -1)) . chr(ord(substr($string, -1)) - 1);
}

$carry = '';
$decremented = '';

for ($i = strlen($string) - 1; $i >= 0; $i--) {
$char = $string[$i];

switch ($char) {
case 'A':
if ('' !== $carry) {
$decremented = $carry . $decremented;
$carry = '';
}
$carry = 'Z';

break;
case 'a':
if ('' !== $carry) {
$decremented = $carry . $decremented;
$carry = '';
}
$carry = 'z';

break;
case '0':
if ('' !== $carry) {
$decremented = $carry . $decremented;
$carry = '';
}
$carry = '9';

break;
case '1':
if ('' !== $carry) {
$decremented = $carry . $decremented;
$carry = '';
}

break;
default:
if ('' !== $carry) {
$decremented = $carry . $decremented;
$carry = '';
}

if (!\in_array($char, ['A', 'a', '0'], true)) {
$decremented = chr(ord($char) - 1) . $decremented;
}
}
}

return $decremented;
}
}
@@ -0,0 +1,16 @@
<?php

/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <fabien@symfony.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/

if (\PHP_VERSION_ID < 80300) {
class SQLite3Exception extends Exception
{
}
}
8 changes: 8 additions & 0 deletions redaxo/src/core/vendor/symfony/polyfill-php83/bootstrap.php
Expand Up @@ -27,6 +27,14 @@ function mb_str_pad(string $string, int $length, string $pad_string = ' ', int $
function stream_context_set_options($context, array $options): bool { return stream_context_set_option($context, $options); }
}

if (!function_exists('str_increment')) {
function str_increment(string $string): string { return p\Php83::str_increment($string); }
}

if (!function_exists('str_decrement')) {
function str_decrement(string $string): string { return p\Php83::str_decrement($string); }
}

if (\PHP_VERSION_ID >= 80100) {
return require __DIR__.'/bootstrap81.php';
}
Expand Down
3 changes: 0 additions & 3 deletions redaxo/src/core/vendor/symfony/polyfill-php83/composer.json
Expand Up @@ -26,9 +26,6 @@
},
"minimum-stability": "dev",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
Expand Down

0 comments on commit 9ee297c

Please sign in to comment.