Plugin Directory

Changeset 3420880


Ignore:
Timestamp:
12/16/2025 10:29:00 AM (4 months ago)
Author:
stuartmcalpine
Message:

Deploy version 6.0.3

Location:
speechkit
Files:
407 added
2 deleted
48 edited

Legend:

Unmodified
Added
Removed
  • speechkit/trunk/composer.json

    r3393083 r3420880  
    1212    "require-dev": {
    1313        "automattic/vipwpcs": "^3.0.1",
    14         "behat/behat": "^3.24",
     14        "behat/behat": "^3.13",
    1515        "bordoni/phpass": "^0.3.6",
    1616        "dealerdirect/phpcodesniffer-composer-installer": "^1.1.2",
    17         "doctrine/instantiator": "^2.0",
     17        "doctrine/instantiator": "^1.5",
    1818        "ergebnis/composer-normalize": "^2.48.2",
    1919        "php-parallel-lint/php-parallel-lint": "^1.4",
    2020        "phpmd/phpmd": "^2.15",
    21         "phpro/grumphp": "^2.15",
     21        "phpro/grumphp": "^1.16",
    2222        "phpunit/phpunit": "^9.6",
    2323        "rector/rector": "^2.2",
    2424        "rregeer/phpunit-coverage-check": "^0.3.1",
    2525        "squizlabs/php_codesniffer": "^3.9.2",
    26         "symfony/css-selector": "^7.3",
    27         "symfony/error-handler": "^7.3",
    28         "symfony/filesystem": "^7.3",
    29         "symfony/finder": "^7.3",
    30         "symfony/http-client": "^7.3",
     26        "symfony/css-selector": "^5.4",
     27        "symfony/error-handler": "^5.4",
     28        "symfony/filesystem": "^5.4",
     29        "symfony/finder": "^5.4",
     30        "symfony/http-client": "^5.4",
    3131        "symfony/polyfill-mbstring": "^1.33",
    32         "symfony/string": "^7.3",
    33         "symfony/translation-contracts": "^3.6",
    34         "symfony/var-exporter": "^7.3",
     32        "symfony/string": "^5.4",
     33        "symfony/translation-contracts": "^2.5",
     34        "symfony/var-exporter": "^5.4",
    3535        "vlucas/phpdotenv": "^5.6",
    3636        "wp-cli/wp-cli-bundle": "^2.12",
  • speechkit/trunk/languages/speechkit.pot

    r3409610 r3420880  
    33msgid ""
    44msgstr ""
    5 "Project-Id-Version: BeyondWords - Text-to-Speech 6.0.2\n"
     5"Project-Id-Version: BeyondWords - Text-to-Speech 6.0.3\n"
    66"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/speechkit\n"
    77"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
     
    1010"Content-Type: text/plain; charset=UTF-8\n"
    1111"Content-Transfer-Encoding: 8bit\n"
    12 "POT-Creation-Date: 2025-12-03T13:35:04+00:00\n"
     12"POT-Creation-Date: 2025-12-16T10:06:48+00:00\n"
    1313"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
    1414"X-Generator: WP-CLI 2.12.0\n"
  • speechkit/trunk/readme.txt

    r3409610 r3420880  
    44Donate link: https://beyondwords.io
    55Tags: text-to-speech, tts, audio, AI, voice cloning
    6 Stable tag: 6.0.2
    7 Requires PHP: 8.1
     6Stable tag: 6.0.3
     7Requires PHP: 8.0
    88Tested up to: 6.9
    99License: GPLv2 or later
     
    7777== Changelog ==
    7878
     79= 6.0.3 =
     80
     81Release date: 16th December 2025
     82
     83**Compatibility**
     84
     85* [#473](https://github.com/beyondwords-io/wordpress-plugin/pull/473) Reintroduce support for **PHP 8.0**.
     86
    7987= 6.0.2 =
    8088
     
    134142**Compatibility**
    135143
    136 * **PHP 8.1** is now our minimum supported version.
     144* ~~**PHP 8.1** is now our minimum supported version.~~
    137145
    138146--------
  • speechkit/trunk/speechkit.php

    r3409610 r3420880  
    1616 * Author:            BeyondWords
    1717 * Author URI:        https://beyondwords.io
    18  * Version:           6.0.2
     18 * Version:           6.0.3
    1919 * License:           GPL-2.0+
    2020 * License URI:       http://www.gnu.org/licenses/gpl-2.0.txt
    2121 * Text Domain:       speechkit
    2222 * Domain Path:       /languages
    23  * Requires PHP:      8.1
     23 * Requires PHP:      8.0
    2424 * Requires at least: 5.8
    2525 */
     
    3636// Define constants
    3737// phpcs:disable
    38 define('BEYONDWORDS__PLUGIN_VERSION', '6.0.2');
     38define('BEYONDWORDS__PLUGIN_VERSION', '6.0.3');
    3939define('BEYONDWORDS__PLUGIN_DIR',     plugin_dir_path(__FILE__));
    4040define('BEYONDWORDS__PLUGIN_URI',     plugin_dir_url(__FILE__));
  • speechkit/trunk/src/Component/Settings/Sync.php

    r3393083 r3420880  
    152152     * @since 5.0.0
    153153     * @since 6.0.0 Make static.
     154     * @since 6.0.3 Check path is readable before getting value.
    154155     *
    155156     * @return boolean
     
    174175
    175176        foreach (self::MAP_SETTINGS as $optionName => $path) {
    176             $value = $propertyAccessor->getValue($responses, $path);
    177 
    178             if ($value !== null) {
    179                 update_option($optionName, $value, false);
    180                 $updated = true;
     177            if ($propertyAccessor->isReadable($responses, $path)) {
     178                $value = $propertyAccessor->getValue($responses, $path);
     179                if ($value !== null) {
     180                    update_option($optionName, $value, false);
     181                    $updated = true;
     182                }
    181183            }
    182184        }
  • speechkit/trunk/vendor/autoload.php

    r3393083 r3420880  
    2020require_once __DIR__ . '/composer/autoload_real.php';
    2121
    22 return ComposerAutoloaderInit871f668f3d5222a0e58403030261d782::getLoader();
     22return ComposerAutoloaderInit5e43b82cc73cdb7142c707a11e389a7d::getLoader();
  • speechkit/trunk/vendor/composer/autoload_classmap.php

    r3393083 r3420880  
    145145    'Symfony\\Component\\String\\Inflector\\FrenchInflector' => $vendorDir . '/symfony/string/Inflector/FrenchInflector.php',
    146146    'Symfony\\Component\\String\\Inflector\\InflectorInterface' => $vendorDir . '/symfony/string/Inflector/InflectorInterface.php',
    147     'Symfony\\Component\\String\\Inflector\\SpanishInflector' => $vendorDir . '/symfony/string/Inflector/SpanishInflector.php',
    148147    'Symfony\\Component\\String\\LazyString' => $vendorDir . '/symfony/string/LazyString.php',
    149148    'Symfony\\Component\\String\\Slugger\\AsciiSlugger' => $vendorDir . '/symfony/string/Slugger/AsciiSlugger.php',
    150149    'Symfony\\Component\\String\\Slugger\\SluggerInterface' => $vendorDir . '/symfony/string/Slugger/SluggerInterface.php',
    151     'Symfony\\Component\\String\\TruncateMode' => $vendorDir . '/symfony/string/TruncateMode.php',
    152150    'Symfony\\Component\\String\\UnicodeString' => $vendorDir . '/symfony/string/UnicodeString.php',
    153151    'Symfony\\Polyfill\\Ctype\\Ctype' => $vendorDir . '/symfony/polyfill-ctype/Ctype.php',
  • speechkit/trunk/vendor/composer/autoload_files.php

    r3393083 r3420880  
    77
    88return array(
     9    'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php',
    910    '320cde22f66dd4f5d3fd621d3e88b98f' => $vendorDir . '/symfony/polyfill-ctype/bootstrap.php',
    1011    '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php',
     
    1213    'e69f7f6ee287b969198c3c9d6777bd38' => $vendorDir . '/symfony/polyfill-intl-normalizer/bootstrap.php',
    1314    '6e3fae29631ef280660b3cdad06f25a8' => $vendorDir . '/symfony/deprecation-contracts/function.php',
    14     'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php',
    1515    'b6b991a57620e2fb6b2f66f03fe9ddc2' => $vendorDir . '/symfony/string/Resources/functions.php',
    1616);
  • speechkit/trunk/vendor/composer/autoload_real.php

    r3393083 r3420880  
    33// autoload_real.php @generated by Composer
    44
    5 class ComposerAutoloaderInit871f668f3d5222a0e58403030261d782
     5class ComposerAutoloaderInit5e43b82cc73cdb7142c707a11e389a7d
    66{
    77    private static $loader;
     
    2323        }
    2424
    25         spl_autoload_register(array('ComposerAutoloaderInit871f668f3d5222a0e58403030261d782', 'loadClassLoader'), true, true);
     25        spl_autoload_register(array('ComposerAutoloaderInit5e43b82cc73cdb7142c707a11e389a7d', 'loadClassLoader'), true, true);
    2626        self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
    27         spl_autoload_unregister(array('ComposerAutoloaderInit871f668f3d5222a0e58403030261d782', 'loadClassLoader'));
     27        spl_autoload_unregister(array('ComposerAutoloaderInit5e43b82cc73cdb7142c707a11e389a7d', 'loadClassLoader'));
    2828
    2929        require __DIR__ . '/autoload_static.php';
    30         call_user_func(\Composer\Autoload\ComposerStaticInit871f668f3d5222a0e58403030261d782::getInitializer($loader));
     30        call_user_func(\Composer\Autoload\ComposerStaticInit5e43b82cc73cdb7142c707a11e389a7d::getInitializer($loader));
    3131
    3232        $loader->setClassMapAuthoritative(true);
    3333        $loader->register(true);
    3434
    35         $filesToLoad = \Composer\Autoload\ComposerStaticInit871f668f3d5222a0e58403030261d782::$files;
     35        $filesToLoad = \Composer\Autoload\ComposerStaticInit5e43b82cc73cdb7142c707a11e389a7d::$files;
    3636        $requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
    3737            if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
  • speechkit/trunk/vendor/composer/autoload_static.php

    r3403395 r3420880  
    55namespace Composer\Autoload;
    66
    7 class ComposerStaticInit871f668f3d5222a0e58403030261d782
     7class ComposerStaticInit5e43b82cc73cdb7142c707a11e389a7d
    88{
    99    public static $files = array (
     10        'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php',
    1011        '320cde22f66dd4f5d3fd621d3e88b98f' => __DIR__ . '/..' . '/symfony/polyfill-ctype/bootstrap.php',
    1112        '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php',
     
    1314        'e69f7f6ee287b969198c3c9d6777bd38' => __DIR__ . '/..' . '/symfony/polyfill-intl-normalizer/bootstrap.php',
    1415        '6e3fae29631ef280660b3cdad06f25a8' => __DIR__ . '/..' . '/symfony/deprecation-contracts/function.php',
    15         'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php',
    1616        'b6b991a57620e2fb6b2f66f03fe9ddc2' => __DIR__ . '/..' . '/symfony/string/Resources/functions.php',
    1717    );
     
    218218        'Symfony\\Component\\String\\Inflector\\FrenchInflector' => __DIR__ . '/..' . '/symfony/string/Inflector/FrenchInflector.php',
    219219        'Symfony\\Component\\String\\Inflector\\InflectorInterface' => __DIR__ . '/..' . '/symfony/string/Inflector/InflectorInterface.php',
    220         'Symfony\\Component\\String\\Inflector\\SpanishInflector' => __DIR__ . '/..' . '/symfony/string/Inflector/SpanishInflector.php',
    221220        'Symfony\\Component\\String\\LazyString' => __DIR__ . '/..' . '/symfony/string/LazyString.php',
    222221        'Symfony\\Component\\String\\Slugger\\AsciiSlugger' => __DIR__ . '/..' . '/symfony/string/Slugger/AsciiSlugger.php',
    223222        'Symfony\\Component\\String\\Slugger\\SluggerInterface' => __DIR__ . '/..' . '/symfony/string/Slugger/SluggerInterface.php',
    224         'Symfony\\Component\\String\\TruncateMode' => __DIR__ . '/..' . '/symfony/string/TruncateMode.php',
    225223        'Symfony\\Component\\String\\UnicodeString' => __DIR__ . '/..' . '/symfony/string/UnicodeString.php',
    226224        'Symfony\\Polyfill\\Ctype\\Ctype' => __DIR__ . '/..' . '/symfony/polyfill-ctype/Ctype.php',
     
    237235    {
    238236        return \Closure::bind(function () use ($loader) {
    239             $loader->prefixLengthsPsr4 = ComposerStaticInit871f668f3d5222a0e58403030261d782::$prefixLengthsPsr4;
    240             $loader->prefixDirsPsr4 = ComposerStaticInit871f668f3d5222a0e58403030261d782::$prefixDirsPsr4;
    241             $loader->classMap = ComposerStaticInit871f668f3d5222a0e58403030261d782::$classMap;
     237            $loader->prefixLengthsPsr4 = ComposerStaticInit5e43b82cc73cdb7142c707a11e389a7d::$prefixLengthsPsr4;
     238            $loader->prefixDirsPsr4 = ComposerStaticInit5e43b82cc73cdb7142c707a11e389a7d::$prefixDirsPsr4;
     239            $loader->classMap = ComposerStaticInit5e43b82cc73cdb7142c707a11e389a7d::$classMap;
    242240
    243241        }, null, ClassLoader::class);
  • speechkit/trunk/vendor/composer/installed.json

    r3393083 r3420880  
    33        {
    44            "name": "symfony/deprecation-contracts",
    5             "version": "v3.6.0",
    6             "version_normalized": "3.6.0.0",
     5            "version": "v3.0.2",
     6            "version_normalized": "3.0.2.0",
    77            "source": {
    88                "type": "git",
    99                "url": "https://github.com/symfony/deprecation-contracts.git",
    10                 "reference": "63afe740e99a13ba87ec199bb07bbdee937a5b62"
    11             },
    12             "dist": {
    13                 "type": "zip",
    14                 "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/63afe740e99a13ba87ec199bb07bbdee937a5b62",
    15                 "reference": "63afe740e99a13ba87ec199bb07bbdee937a5b62",
    16                 "shasum": ""
    17             },
    18             "require": {
    19                 "php": ">=8.1"
    20             },
    21             "time": "2024-09-25T14:21:43+00:00",
     10                "reference": "26954b3d62a6c5fd0ea8a2a00c0353a14978d05c"
     11            },
     12            "dist": {
     13                "type": "zip",
     14                "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/26954b3d62a6c5fd0ea8a2a00c0353a14978d05c",
     15                "reference": "26954b3d62a6c5fd0ea8a2a00c0353a14978d05c",
     16                "shasum": ""
     17            },
     18            "require": {
     19                "php": ">=8.0.2"
     20            },
     21            "time": "2022-01-02T09:55:41+00:00",
    2222            "type": "library",
    2323            "extra": {
     
    2727                },
    2828                "branch-alias": {
    29                     "dev-main": "3.6-dev"
     29                    "dev-main": "3.0-dev"
    3030                }
    3131            },
     
    5353            "homepage": "https://symfony.com",
    5454            "support": {
    55                 "source": "https://github.com/symfony/deprecation-contracts/tree/v3.6.0"
     55                "source": "https://github.com/symfony/deprecation-contracts/tree/v3.0.2"
    5656            },
    5757            "funding": [
     
    669669        {
    670670            "name": "symfony/property-info",
    671             "version": "v6.4.24",
    672             "version_normalized": "6.4.24.0",
     671            "version": "v6.0.19",
     672            "version_normalized": "6.0.19.0",
    673673            "source": {
    674674                "type": "git",
    675675                "url": "https://github.com/symfony/property-info.git",
    676                 "reference": "1056ae3621eeddd78d7c5ec074f1c1784324eec6"
    677             },
    678             "dist": {
    679                 "type": "zip",
    680                 "url": "https://api.github.com/repos/symfony/property-info/zipball/1056ae3621eeddd78d7c5ec074f1c1784324eec6",
    681                 "reference": "1056ae3621eeddd78d7c5ec074f1c1784324eec6",
    682                 "shasum": ""
    683             },
    684             "require": {
    685                 "php": ">=8.1",
    686                 "symfony/string": "^5.4|^6.0|^7.0"
     676                "reference": "e6dfb2223b21768d3b2ae033a5e1f9d205184d45"
     677            },
     678            "dist": {
     679                "type": "zip",
     680                "url": "https://api.github.com/repos/symfony/property-info/zipball/e6dfb2223b21768d3b2ae033a5e1f9d205184d45",
     681                "reference": "e6dfb2223b21768d3b2ae033a5e1f9d205184d45",
     682                "shasum": ""
     683            },
     684            "require": {
     685                "php": ">=8.0.2",
     686                "symfony/string": "^5.4|^6.0"
    687687            },
    688688            "conflict": {
    689                 "doctrine/annotations": "<1.12",
    690689                "phpdocumentor/reflection-docblock": "<5.2",
    691                 "phpdocumentor/type-resolver": "<1.5.1",
    692                 "symfony/cache": "<5.4",
    693                 "symfony/dependency-injection": "<5.4|>=6.0,<6.4",
    694                 "symfony/serializer": "<5.4"
     690                "phpdocumentor/type-resolver": "<1.4.0",
     691                "symfony/dependency-injection": "<5.4"
    695692            },
    696693            "require-dev": {
    697                 "doctrine/annotations": "^1.12|^2",
     694                "doctrine/annotations": "^1.10.4|^2",
    698695                "phpdocumentor/reflection-docblock": "^5.2",
    699                 "phpstan/phpdoc-parser": "^1.0|^2.0",
    700                 "symfony/cache": "^5.4|^6.0|^7.0",
    701                 "symfony/dependency-injection": "^5.4|^6.0|^7.0",
    702                 "symfony/serializer": "^5.4|^6.4|^7.0"
    703             },
    704             "time": "2025-07-14T16:38:25+00:00",
     696                "phpstan/phpdoc-parser": "^1.0",
     697                "symfony/cache": "^5.4|^6.0",
     698                "symfony/dependency-injection": "^5.4|^6.0",
     699                "symfony/serializer": "^5.4|^6.0"
     700            },
     701            "suggest": {
     702                "phpdocumentor/reflection-docblock": "To use the PHPDoc",
     703                "psr/cache-implementation": "To cache results",
     704                "symfony/doctrine-bridge": "To use Doctrine metadata",
     705                "symfony/serializer": "To use Serializer metadata"
     706            },
     707            "time": "2023-01-15T17:21:41+00:00",
    705708            "type": "library",
    706709            "installation-source": "dist",
     
    738741            ],
    739742            "support": {
    740                 "source": "https://github.com/symfony/property-info/tree/v6.4.24"
    741             },
    742             "funding": [
    743                 {
    744                     "url": "https://symfony.com/sponsor",
    745                     "type": "custom"
    746                 },
    747                 {
    748                     "url": "https://github.com/fabpot",
    749                     "type": "github"
    750                 },
    751                 {
    752                     "url": "https://github.com/nicolas-grekas",
     743                "source": "https://github.com/symfony/property-info/tree/v6.0.19"
     744            },
     745            "funding": [
     746                {
     747                    "url": "https://symfony.com/sponsor",
     748                    "type": "custom"
     749                },
     750                {
     751                    "url": "https://github.com/fabpot",
    753752                    "type": "github"
    754753                },
     
    762761        {
    763762            "name": "symfony/string",
    764             "version": "v7.3.4",
    765             "version_normalized": "7.3.4.0",
     763            "version": "v5.4.47",
     764            "version_normalized": "5.4.47.0",
    766765            "source": {
    767766                "type": "git",
    768767                "url": "https://github.com/symfony/string.git",
    769                 "reference": "f96476035142921000338bad71e5247fbc138872"
    770             },
    771             "dist": {
    772                 "type": "zip",
    773                 "url": "https://api.github.com/repos/symfony/string/zipball/f96476035142921000338bad71e5247fbc138872",
    774                 "reference": "f96476035142921000338bad71e5247fbc138872",
    775                 "shasum": ""
    776             },
    777             "require": {
    778                 "php": ">=8.2",
     768                "reference": "136ca7d72f72b599f2631aca474a4f8e26719799"
     769            },
     770            "dist": {
     771                "type": "zip",
     772                "url": "https://api.github.com/repos/symfony/string/zipball/136ca7d72f72b599f2631aca474a4f8e26719799",
     773                "reference": "136ca7d72f72b599f2631aca474a4f8e26719799",
     774                "shasum": ""
     775            },
     776            "require": {
     777                "php": ">=7.2.5",
    779778                "symfony/polyfill-ctype": "~1.8",
    780779                "symfony/polyfill-intl-grapheme": "~1.0",
    781780                "symfony/polyfill-intl-normalizer": "~1.0",
    782                 "symfony/polyfill-mbstring": "~1.0"
     781                "symfony/polyfill-mbstring": "~1.0",
     782                "symfony/polyfill-php80": "~1.15"
    783783            },
    784784            "conflict": {
    785                 "symfony/translation-contracts": "<2.5"
     785                "symfony/translation-contracts": ">=3.0"
    786786            },
    787787            "require-dev": {
    788                 "symfony/emoji": "^7.1",
    789                 "symfony/http-client": "^6.4|^7.0",
    790                 "symfony/intl": "^6.4|^7.0",
    791                 "symfony/translation-contracts": "^2.5|^3.0",
    792                 "symfony/var-exporter": "^6.4|^7.0"
    793             },
    794             "time": "2025-09-11T14:36:48+00:00",
     788                "symfony/error-handler": "^4.4|^5.0|^6.0",
     789                "symfony/http-client": "^4.4|^5.0|^6.0",
     790                "symfony/translation-contracts": "^1.1|^2",
     791                "symfony/var-exporter": "^4.4|^5.0|^6.0"
     792            },
     793            "time": "2024-11-10T20:33:58+00:00",
    795794            "type": "library",
    796795            "installation-source": "dist",
     
    831830            ],
    832831            "support": {
    833                 "source": "https://github.com/symfony/string/tree/v7.3.4"
    834             },
    835             "funding": [
    836                 {
    837                     "url": "https://symfony.com/sponsor",
    838                     "type": "custom"
    839                 },
    840                 {
    841                     "url": "https://github.com/fabpot",
    842                     "type": "github"
    843                 },
    844                 {
    845                     "url": "https://github.com/nicolas-grekas",
     832                "source": "https://github.com/symfony/string/tree/v5.4.47"
     833            },
     834            "funding": [
     835                {
     836                    "url": "https://symfony.com/sponsor",
     837                    "type": "custom"
     838                },
     839                {
     840                    "url": "https://github.com/fabpot",
    846841                    "type": "github"
    847842                },
  • speechkit/trunk/vendor/composer/installed.php

    r3409610 r3420880  
    22    'root' => array(
    33        'name' => 'beyondwords/wordpress',
    4         'pretty_version' => 'v6.0.2',
    5         'version' => '6.0.2.0',
    6         'reference' => '288c1c84ef0d24436a2a1fbae43422644783aa8a',
     4        'pretty_version' => 'v6.0.3',
     5        'version' => '6.0.3.0',
     6        'reference' => '33b10a56962d32e32c8f742469c937f483589233',
    77        'type' => 'project',
    88        'install_path' => __DIR__ . '/../../',
     
    1212    'versions' => array(
    1313        'beyondwords/wordpress' => array(
    14             'pretty_version' => 'v6.0.2',
    15             'version' => '6.0.2.0',
    16             'reference' => '288c1c84ef0d24436a2a1fbae43422644783aa8a',
     14            'pretty_version' => 'v6.0.3',
     15            'version' => '6.0.3.0',
     16            'reference' => '33b10a56962d32e32c8f742469c937f483589233',
    1717            'type' => 'project',
    1818            'install_path' => __DIR__ . '/../../',
     
    2121        ),
    2222        'symfony/deprecation-contracts' => array(
    23             'pretty_version' => 'v3.6.0',
    24             'version' => '3.6.0.0',
    25             'reference' => '63afe740e99a13ba87ec199bb07bbdee937a5b62',
     23            'pretty_version' => 'v3.0.2',
     24            'version' => '3.0.2.0',
     25            'reference' => '26954b3d62a6c5fd0ea8a2a00c0353a14978d05c',
    2626            'type' => 'library',
    2727            'install_path' => __DIR__ . '/../symfony/deprecation-contracts',
     
    9393        ),
    9494        'symfony/property-info' => array(
    95             'pretty_version' => 'v6.4.24',
    96             'version' => '6.4.24.0',
    97             'reference' => '1056ae3621eeddd78d7c5ec074f1c1784324eec6',
     95            'pretty_version' => 'v6.0.19',
     96            'version' => '6.0.19.0',
     97            'reference' => 'e6dfb2223b21768d3b2ae033a5e1f9d205184d45',
    9898            'type' => 'library',
    9999            'install_path' => __DIR__ . '/../symfony/property-info',
     
    102102        ),
    103103        'symfony/string' => array(
    104             'pretty_version' => 'v7.3.4',
    105             'version' => '7.3.4.0',
    106             'reference' => 'f96476035142921000338bad71e5247fbc138872',
     104            'pretty_version' => 'v5.4.47',
     105            'version' => '5.4.47.0',
     106            'reference' => '136ca7d72f72b599f2631aca474a4f8e26719799',
    107107            'type' => 'library',
    108108            'install_path' => __DIR__ . '/../symfony/string',
  • speechkit/trunk/vendor/symfony/deprecation-contracts/LICENSE

    r3169191 r3420880  
    1 Copyright (c) 2020-present Fabien Potencier
     1Copyright (c) 2020-2022 Fabien Potencier
    22
    33Permission is hereby granted, free of charge, to any person obtaining a copy
  • speechkit/trunk/vendor/symfony/deprecation-contracts/README.md

    r3169191 r3420880  
    2323`Since symfony/blockchain 8.9: Using "bitcoin" is deprecated, use "fabcoin" instead.`
    2424
    25 While not recommended, the deprecation notices can be completely ignored by declaring an empty
     25While not necessarily recommended, the deprecation notices can be completely ignored by declaring an empty
    2626`function trigger_deprecation() {}` in your application.
  • speechkit/trunk/vendor/symfony/deprecation-contracts/composer.json

    r3393083 r3420880  
    1616    ],
    1717    "require": {
    18         "php": ">=8.1"
     18        "php": ">=8.0.2"
    1919    },
    2020    "autoload": {
     
    2626    "extra": {
    2727        "branch-alias": {
    28             "dev-main": "3.6-dev"
     28            "dev-main": "3.0-dev"
    2929        },
    3030        "thanks": {
  • speechkit/trunk/vendor/symfony/property-info/CHANGELOG.md

    r3169191 r3420880  
    11CHANGELOG
    22=========
    3 
    4 6.4
    5 ---
    6 
    7  * Make properties writable when a setter in camelCase exists, similar to the camelCase getter
    8 
    9 6.1
    10 ---
    11 
    12  * Add support for phpDocumentor and PHPStan pseudo-types
    13  * Add PHP 8.0 promoted properties `@param` mutation support to `PhpDocExtractor`
    14  * Add PHP 8.0 promoted properties `@param` mutation support to `PhpStanExtractor`
    153
    1646.0
  • speechkit/trunk/vendor/symfony/property-info/DependencyInjection/PropertyInfoConstructorPass.php

    r3169191 r3420880  
    2626    use PriorityTaggedServiceTrait;
    2727
    28     public function process(ContainerBuilder $container): void
     28    /**
     29     * {@inheritdoc}
     30     */
     31    public function process(ContainerBuilder $container)
    2932    {
    3033        if (!$container->hasDefinition('property_info.constructor_extractor')) {
  • speechkit/trunk/vendor/symfony/property-info/DependencyInjection/PropertyInfoPass.php

    r3169191 r3420880  
    2727
    2828    /**
    29      * @return void
     29     * {@inheritdoc}
    3030     */
    3131    public function process(ContainerBuilder $container)
  • speechkit/trunk/vendor/symfony/property-info/Extractor/ConstructorExtractor.php

    r3169191 r3420880  
    2121final class ConstructorExtractor implements PropertyTypeExtractorInterface
    2222{
     23    private $extractors;
     24
    2325    /**
    2426     * @param iterable<int, ConstructorArgumentTypeExtractorInterface> $extractors
    2527     */
    26     public function __construct(
    27         private readonly iterable $extractors = [],
    28     ) {
     28    public function __construct(iterable $extractors = [])
     29    {
     30        $this->extractors = $extractors;
    2931    }
    3032
     33    /**
     34     * {@inheritdoc}
     35     */
    3136    public function getTypes(string $class, string $property, array $context = []): ?array
    3237    {
  • speechkit/trunk/vendor/symfony/property-info/Extractor/PhpDocExtractor.php

    r3393083 r3420880  
    3939     * @var array<string, array{DocBlock|null, int|null, string|null}>
    4040     */
    41     private array $docBlocks = [];
     41    private $docBlocks = [];
    4242
    4343    /**
    4444     * @var Context[]
    4545     */
    46     private array $contexts = [];
    47 
    48     private DocBlockFactoryInterface $docBlockFactory;
    49     private ContextFactory $contextFactory;
    50     private PhpDocTypeHelper $phpDocTypeHelper;
    51     private array $mutatorPrefixes;
    52     private array $accessorPrefixes;
    53     private array $arrayMutatorPrefixes;
     46    private $contexts = [];
     47
     48    private $docBlockFactory;
     49    private $contextFactory;
     50    private $phpDocTypeHelper;
     51    private $mutatorPrefixes;
     52    private $accessorPrefixes;
     53    private $arrayMutatorPrefixes;
    5454
    5555    /**
     
    5858     * @param string[]|null $arrayMutatorPrefixes
    5959     */
    60     public function __construct(?DocBlockFactoryInterface $docBlockFactory = null, ?array $mutatorPrefixes = null, ?array $accessorPrefixes = null, ?array $arrayMutatorPrefixes = null)
     60    public function __construct(DocBlockFactoryInterface $docBlockFactory = null, array $mutatorPrefixes = null, array $accessorPrefixes = null, array $arrayMutatorPrefixes = null)
    6161    {
    6262        if (!class_exists(DocBlockFactory::class)) {
    63             throw new \LogicException(\sprintf('Unable to use the "%s" class as the "phpdocumentor/reflection-docblock" package is not installed. Try running composer require "phpdocumentor/reflection-docblock".', __CLASS__));
     63            throw new \LogicException(sprintf('Unable to use the "%s" class as the "phpdocumentor/reflection-docblock" package is not installed.', __CLASS__));
    6464        }
    6565
     
    7272    }
    7373
     74    /**
     75     * {@inheritdoc}
     76     */
    7477    public function getShortDescription(string $class, string $property, array $context = []): ?string
    7578    {
    76         /** @var DocBlock $docBlock */
     79        /** @var $docBlock DocBlock */
    7780        [$docBlock] = $this->getDocBlock($class, $property);
    7881        if (!$docBlock) {
     
    99102    }
    100103
     104    /**
     105     * {@inheritdoc}
     106     */
    101107    public function getLongDescription(string $class, string $property, array $context = []): ?string
    102108    {
    103         /** @var DocBlock $docBlock */
     109        /** @var $docBlock DocBlock */
    104110        [$docBlock] = $this->getDocBlock($class, $property);
    105111        if (!$docBlock) {
     
    112118    }
    113119
     120    /**
     121     * {@inheritdoc}
     122     */
    114123    public function getTypes(string $class, string $property, array $context = []): ?array
    115124    {
    116         /** @var DocBlock $docBlock */
     125        /** @var $docBlock DocBlock */
    117126        [$docBlock, $source, $prefix] = $this->getDocBlock($class, $property);
    118127        if (!$docBlock) {
     
    120129        }
    121130
    122         $tag = match ($source) {
    123             self::PROPERTY => 'var',
    124             self::ACCESSOR => 'return',
    125             self::MUTATOR => 'param',
    126         };
     131        switch ($source) {
     132            case self::PROPERTY:
     133                $tag = 'var';
     134                break;
     135
     136            case self::ACCESSOR:
     137                $tag = 'return';
     138                break;
     139
     140            case self::MUTATOR:
     141                $tag = 'param';
     142                break;
     143        }
    127144
    128145        $parentClass = null;
     
    139156
    140157                        case 'parent':
    141                             if (false !== $resolvedClass = $parentClass ??= get_parent_class($class)) {
     158                            if (false !== $resolvedClass = $parentClass ?? $parentClass = get_parent_class($class)) {
    142159                                break;
    143160                            }
     
    165182    }
    166183
     184    /**
     185     * {@inheritdoc}
     186     */
    167187    public function getTypesFromConstructor(string $class, string $property): ?array
    168188    {
     
    192212        try {
    193213            $reflectionClass = new \ReflectionClass($class);
    194         } catch (\ReflectionException) {
     214        } catch (\ReflectionException $e) {
    195215            return null;
    196216        }
     
    204224
    205225            return $this->filterDocBlockParams($docBlock, $property);
    206         } catch (\InvalidArgumentException) {
     226        } catch (\InvalidArgumentException $e) {
    207227            return null;
    208228        }
     
    211231    private function filterDocBlockParams(DocBlock $docBlock, string $allowedParam): DocBlock
    212232    {
    213         $tags = array_values(array_filter($docBlock->getTagsByName('param'), fn ($tag) => $tag instanceof DocBlock\Tags\Param && $allowedParam === $tag->getVariableName()));
     233        $tags = array_values(array_filter($docBlock->getTagsByName('param'), function ($tag) use ($allowedParam) {
     234            return $tag instanceof DocBlock\Tags\Param && $allowedParam === $tag->getVariableName();
     235        }));
    214236
    215237        return new DocBlock($docBlock->getSummary(), $docBlock->getDescription(), $tags, $docBlock->getContext(),
     
    222244    private function getDocBlock(string $class, string $property): array
    223245    {
    224         $propertyHash = \sprintf('%s::%s', $class, $property);
     246        $propertyHash = sprintf('%s::%s', $class, $property);
    225247
    226248        if (isset($this->docBlocks[$propertyHash])) {
     
    228250        }
    229251
    230         try {
    231             $reflectionProperty = new \ReflectionProperty($class, $property);
    232         } catch (\ReflectionException) {
    233             $reflectionProperty = null;
    234         }
    235 
    236252        $ucFirstProperty = ucfirst($property);
    237253
    238254        switch (true) {
    239             case $reflectionProperty?->isPromoted() && $docBlock = $this->getDocBlockFromConstructor($class, $property):
    240                 $data = [$docBlock, self::MUTATOR, null];
    241                 break;
    242 
    243255            case $docBlock = $this->getDocBlockFromProperty($class, $property):
    244256                $data = [$docBlock, self::PROPERTY, null];
     
    265277        try {
    266278            $reflectionProperty = new \ReflectionProperty($class, $property);
    267         } catch (\ReflectionException) {
     279        } catch (\ReflectionException $e) {
    268280            return null;
    269281        }
     
    279291        try {
    280292            return $this->docBlockFactory->create($reflectionProperty, $this->createFromReflector($reflector));
    281         } catch (\InvalidArgumentException|\RuntimeException) {
     293        } catch (\InvalidArgumentException|\RuntimeException $e) {
    282294            return null;
    283295        }
     
    302314
    303315                if (
    304                     (self::ACCESSOR === $type && 0 === $reflectionMethod->getNumberOfRequiredParameters())
    305                     || (self::MUTATOR === $type && $reflectionMethod->getNumberOfParameters() >= 1)
     316                    (self::ACCESSOR === $type && 0 === $reflectionMethod->getNumberOfRequiredParameters()) ||
     317                    (self::MUTATOR === $type && $reflectionMethod->getNumberOfParameters() >= 1)
    306318                ) {
    307319                    break;
    308320                }
    309             } catch (\ReflectionException) {
     321            } catch (\ReflectionException $e) {
    310322                // Try the next prefix if the method doesn't exist
    311323            }
     
    326338        try {
    327339            return [$this->docBlockFactory->create($reflectionMethod, $this->createFromReflector($reflector)), $prefix];
    328         } catch (\InvalidArgumentException|\RuntimeException) {
     340        } catch (\InvalidArgumentException|\RuntimeException $e) {
    329341            return null;
    330342        }
  • speechkit/trunk/vendor/symfony/property-info/Extractor/PhpStanExtractor.php

    r3393083 r3420880  
    1212namespace Symfony\Component\PropertyInfo\Extractor;
    1313
    14 use phpDocumentor\Reflection\Types\ContextFactory;
    1514use PHPStan\PhpDocParser\Ast\PhpDoc\InvalidTagValueNode;
    1615use PHPStan\PhpDocParser\Ast\PhpDoc\ParamTagValueNode;
     
    2221use PHPStan\PhpDocParser\Parser\TokenIterator;
    2322use PHPStan\PhpDocParser\Parser\TypeParser;
    24 use PHPStan\PhpDocParser\ParserConfig;
    2523use Symfony\Component\PropertyInfo\PhpStan\NameScopeFactory;
    2624use Symfony\Component\PropertyInfo\PropertyTypeExtractorInterface;
     
    3937    private const MUTATOR = 2;
    4038
    41     private PhpDocParser $phpDocParser;
    42     private Lexer $lexer;
    43     private NameScopeFactory $nameScopeFactory;
     39    /** @var PhpDocParser */
     40    private $phpDocParser;
     41
     42    /** @var Lexer */
     43    private $lexer;
     44
     45    /** @var NameScopeFactory */
     46    private $nameScopeFactory;
    4447
    4548    /** @var array<string, array{PhpDocNode|null, int|null, string|null, string|null}> */
    46     private array $docBlocks = [];
    47     private PhpStanTypeHelper $phpStanTypeHelper;
    48     private array $mutatorPrefixes;
    49     private array $accessorPrefixes;
    50     private array $arrayMutatorPrefixes;
     49    private $docBlocks = [];
     50    private $phpStanTypeHelper;
     51    private $mutatorPrefixes;
     52    private $accessorPrefixes;
     53    private $arrayMutatorPrefixes;
    5154
    5255    /**
     
    5558     * @param list<string>|null $arrayMutatorPrefixes
    5659     */
    57     public function __construct(?array $mutatorPrefixes = null, ?array $accessorPrefixes = null, ?array $arrayMutatorPrefixes = null)
    58     {
    59         if (!class_exists(ContextFactory::class)) {
    60             throw new \LogicException(\sprintf('Unable to use the "%s" class as the "phpdocumentor/type-resolver" package is not installed. Try running composer require "phpdocumentor/type-resolver".', __CLASS__));
    61         }
    62 
    63         if (!class_exists(PhpDocParser::class)) {
    64             throw new \LogicException(\sprintf('Unable to use the "%s" class as the "phpstan/phpdoc-parser" package is not installed. Try running composer require "phpstan/phpdoc-parser".', __CLASS__));
    65         }
    66 
     60    public function __construct(array $mutatorPrefixes = null, array $accessorPrefixes = null, array $arrayMutatorPrefixes = null)
     61    {
    6762        $this->phpStanTypeHelper = new PhpStanTypeHelper();
    6863        $this->mutatorPrefixes = $mutatorPrefixes ?? ReflectionExtractor::$defaultMutatorPrefixes;
     
    7065        $this->arrayMutatorPrefixes = $arrayMutatorPrefixes ?? ReflectionExtractor::$defaultArrayMutatorPrefixes;
    7166
    72         if (class_exists(ParserConfig::class)) {
    73             $parserConfig = new ParserConfig([]);
    74             $this->phpDocParser = new PhpDocParser($parserConfig, new TypeParser($parserConfig, new ConstExprParser($parserConfig)), new ConstExprParser($parserConfig));
    75             $this->lexer = new Lexer($parserConfig);
    76         } else {
    77             $this->phpDocParser = new PhpDocParser(new TypeParser(new ConstExprParser()), new ConstExprParser());
    78             $this->lexer = new Lexer();
    79         }
     67        $this->phpDocParser = new PhpDocParser(new TypeParser(new ConstExprParser()), new ConstExprParser());
     68        $this->lexer = new Lexer();
    8069        $this->nameScopeFactory = new NameScopeFactory();
    8170    }
     
    111100            }
    112101
    113             if (
    114                 $tagDocNode->value instanceof ParamTagValueNode
    115                 && null === $prefix
    116                 && $tagDocNode->value->parameterName !== '$'.$property
    117             ) {
    118                 continue;
    119             }
    120 
    121102            foreach ($this->phpStanTypeHelper->getTypes($tagDocNode->value, $nameScope) as $type) {
    122103                switch ($type->getClassName()) {
     
    127108
    128109                    case 'parent':
    129                         if (false !== $resolvedClass = $parentClass ??= get_parent_class($class)) {
     110                        if (false !== $resolvedClass = $parentClass ?? $parentClass = get_parent_class($class)) {
    130111                            break;
    131112                        }
     
    174155        try {
    175156            $reflectionClass = new \ReflectionClass($class);
    176         } catch (\ReflectionException) {
     157        } catch (\ReflectionException $e) {
    177158            return null;
    178159        }
     
    182163        }
    183164
    184         if (!$rawDocNode = $reflectionConstructor->getDocComment()) {
    185             return null;
    186         }
    187 
    188         $phpDocNode = $this->getPhpDocNode($rawDocNode);
     165        $rawDocNode = $reflectionConstructor->getDocComment();
     166        $tokens = new TokenIterator($this->lexer->tokenize($rawDocNode));
     167        $phpDocNode = $this->phpDocParser->parse($tokens);
     168        $tokens->consumeTokenType(Lexer::TOKEN_END);
    189169
    190170        return $this->filterDocBlockParams($phpDocNode, $property);
     
    193173    private function filterDocBlockParams(PhpDocNode $docNode, string $allowedParam): ?ParamTagValueNode
    194174    {
    195         $tags = array_values(array_filter($docNode->getTagsByName('@param'), fn ($tagNode) => $tagNode instanceof PhpDocTagNode && ('$'.$allowedParam) === $tagNode->value->parameterName));
     175        $tags = array_values(array_filter($docNode->getTagsByName('@param'), function ($tagNode) use ($allowedParam) {
     176            return $tagNode instanceof PhpDocTagNode && ('$'.$allowedParam) === $tagNode->value->parameterName;
     177        }));
    196178
    197179        if (!$tags) {
     
    215197        $ucFirstProperty = ucfirst($property);
    216198
    217         if ([$docBlock, $source, $declaringClass] = $this->getDocBlockFromProperty($class, $property)) {
    218             $data = [$docBlock, $source, null, $declaringClass];
     199        if ([$docBlock, $declaringClass] = $this->getDocBlockFromProperty($class, $property)) {
     200            $data = [$docBlock, self::PROPERTY, null, $declaringClass];
    219201        } elseif ([$docBlock, $_, $declaringClass] = $this->getDocBlockFromMethod($class, $ucFirstProperty, self::ACCESSOR)) {
    220202            $data = [$docBlock, self::ACCESSOR, null, $declaringClass];
     
    229211
    230212    /**
    231      * @return array{PhpDocNode, int, string}|null
     213     * @return array{PhpDocNode, string}|null
    232214     */
    233215    private function getDocBlockFromProperty(string $class, string $property): ?array
     
    236218        try {
    237219            $reflectionProperty = new \ReflectionProperty($class, $property);
    238         } catch (\ReflectionException) {
    239             return null;
    240         }
    241 
    242         $reflector = $reflectionProperty->getDeclaringClass();
    243 
    244         foreach ($reflector->getTraits() as $trait) {
    245             if ($trait->hasProperty($property)) {
    246                 return $this->getDocBlockFromProperty($trait->getName(), $property);
    247             }
    248         }
    249 
    250         // Type can be inside property docblock as `@var`
    251         $rawDocNode = $reflectionProperty->getDocComment();
    252         $phpDocNode = $rawDocNode ? $this->getPhpDocNode($rawDocNode) : null;
    253         $source = self::PROPERTY;
    254 
    255         if (!$phpDocNode?->getTagsByName('@var')) {
    256             $phpDocNode = null;
    257         }
    258 
    259         // or in the constructor as `@param` for promoted properties
    260         if (!$phpDocNode && $reflectionProperty->isPromoted()) {
    261             $constructor = new \ReflectionMethod($class, '__construct');
    262             $rawDocNode = $constructor->getDocComment();
    263             $phpDocNode = $rawDocNode ? $this->getPhpDocNode($rawDocNode) : null;
    264             $source = self::MUTATOR;
    265         }
    266 
    267         if (!$phpDocNode) {
    268             return null;
    269         }
    270 
    271         return [$phpDocNode, $source, $reflectionProperty->class];
     220        } catch (\ReflectionException $e) {
     221            return null;
     222        }
     223
     224        if (null === $rawDocNode = $reflectionProperty->getDocComment() ?: null) {
     225            return null;
     226        }
     227
     228        $tokens = new TokenIterator($this->lexer->tokenize($rawDocNode));
     229        $phpDocNode = $this->phpDocParser->parse($tokens);
     230        $tokens->consumeTokenType(Lexer::TOKEN_END);
     231
     232        return [$phpDocNode, $reflectionProperty->class];
    272233    }
    273234
     
    295256                    break;
    296257                }
    297             } catch (\ReflectionException) {
     258            } catch (\ReflectionException $e) {
    298259                // Try the next prefix if the method doesn't exist
    299260            }
     
    308269        }
    309270
    310         $phpDocNode = $this->getPhpDocNode($rawDocNode);
    311 
    312         return [$phpDocNode, $prefix, $reflectionMethod->class];
    313     }
    314 
    315     private function getPhpDocNode(string $rawDocNode): PhpDocNode
    316     {
    317271        $tokens = new TokenIterator($this->lexer->tokenize($rawDocNode));
    318272        $phpDocNode = $this->phpDocParser->parse($tokens);
    319273        $tokens->consumeTokenType(Lexer::TOKEN_END);
    320274
    321         return $phpDocNode;
     275        return [$phpDocNode, $prefix, $reflectionMethod->class];
    322276    }
    323277}
  • speechkit/trunk/vendor/symfony/property-info/Extractor/ReflectionExtractor.php

    r3393083 r3420880  
    6767    ];
    6868
    69     private array $mutatorPrefixes;
    70     private array $accessorPrefixes;
    71     private array $arrayMutatorPrefixes;
    72     private bool $enableConstructorExtraction;
    73     private int $methodReflectionFlags;
    74     private int $magicMethodsFlags;
    75     private int $propertyReflectionFlags;
    76     private InflectorInterface $inflector;
    77     private array $arrayMutatorPrefixesFirst;
    78     private array $arrayMutatorPrefixesLast;
     69    private $mutatorPrefixes;
     70    private $accessorPrefixes;
     71    private $arrayMutatorPrefixes;
     72    private $enableConstructorExtraction;
     73    private $methodReflectionFlags;
     74    private $magicMethodsFlags;
     75    private $propertyReflectionFlags;
     76    private $inflector;
     77
     78    private $arrayMutatorPrefixesFirst;
     79    private $arrayMutatorPrefixesLast;
    7980
    8081    /**
     
    8384     * @param string[]|null $arrayMutatorPrefixes
    8485     */
    85     public function __construct(?array $mutatorPrefixes = null, ?array $accessorPrefixes = null, ?array $arrayMutatorPrefixes = null, bool $enableConstructorExtraction = true, int $accessFlags = self::ALLOW_PUBLIC, ?InflectorInterface $inflector = null, int $magicMethodsFlags = self::ALLOW_MAGIC_GET | self::ALLOW_MAGIC_SET)
     86    public function __construct(array $mutatorPrefixes = null, array $accessorPrefixes = null, array $arrayMutatorPrefixes = null, bool $enableConstructorExtraction = true, int $accessFlags = self::ALLOW_PUBLIC, InflectorInterface $inflector = null, int $magicMethodsFlags = self::ALLOW_MAGIC_GET | self::ALLOW_MAGIC_SET)
    8687    {
    8788        $this->mutatorPrefixes = $mutatorPrefixes ?? self::$defaultMutatorPrefixes;
     
    9899    }
    99100
     101    /**
     102     * {@inheritdoc}
     103     */
    100104    public function getProperties(string $class, array $context = []): ?array
    101105    {
    102106        try {
    103107            $reflectionClass = new \ReflectionClass($class);
    104         } catch (\ReflectionException) {
     108        } catch (\ReflectionException $e) {
    105109            return null;
    106110        }
     
    133137    }
    134138
     139    /**
     140     * {@inheritdoc}
     141     */
    135142    public function getTypes(string $class, string $property, array $context = []): ?array
    136143    {
     
    144151
    145152        if (
    146             ($context['enable_constructor_extraction'] ?? $this->enableConstructorExtraction)
    147             && $fromConstructor = $this->extractFromConstructor($class, $property)
     153            ($context['enable_constructor_extraction'] ?? $this->enableConstructorExtraction) &&
     154            $fromConstructor = $this->extractFromConstructor($class, $property)
    148155        ) {
    149156            return $fromConstructor;
     
    157164    }
    158165
     166    /**
     167     * {@inheritdoc}
     168     */
    159169    public function getTypesFromConstructor(string $class, string $property): ?array
    160170    {
    161171        try {
    162172            $reflection = new \ReflectionClass($class);
    163         } catch (\ReflectionException) {
     173        } catch (\ReflectionException $e) {
    164174            return null;
    165175        }
     
    182192    private function getReflectionParameterFromConstructor(string $property, \ReflectionMethod $reflectionConstructor): ?\ReflectionParameter
    183193    {
     194        $reflectionParameter = null;
    184195        foreach ($reflectionConstructor->getParameters() as $reflectionParameter) {
    185196            if ($reflectionParameter->getName() === $property) {
     
    191202    }
    192203
     204    /**
     205     * {@inheritdoc}
     206     */
    193207    public function isReadable(string $class, string $property, array $context = []): ?bool
    194208    {
     
    200214    }
    201215
     216    /**
     217     * {@inheritdoc}
     218     */
    202219    public function isWritable(string $class, string $property, array $context = []): ?bool
    203220    {
     
    206223        }
    207224
    208         // First test with the camelized property name
    209         [$reflectionMethod] = $this->getMutatorMethod($class, $this->camelize($property));
    210         if (null !== $reflectionMethod) {
    211             return true;
    212         }
    213 
    214         // Otherwise check for the old way
    215225        [$reflectionMethod] = $this->getMutatorMethod($class, $property);
    216226
     
    218228    }
    219229
     230    /**
     231     * {@inheritdoc}
     232     */
    220233    public function isInitializable(string $class, string $property, array $context = []): ?bool
    221234    {
    222235        try {
    223236            $reflectionClass = new \ReflectionClass($class);
    224         } catch (\ReflectionException) {
     237        } catch (\ReflectionException $e) {
    225238            return null;
    226239        }
     
    243256    }
    244257
     258    /**
     259     * {@inheritdoc}
     260     */
    245261    public function getReadInfo(string $class, string $property, array $context = []): ?PropertyReadInfo
    246262    {
    247263        try {
    248264            $reflClass = new \ReflectionClass($class);
    249         } catch (\ReflectionException) {
     265        } catch (\ReflectionException $e) {
    250266            return null;
    251267        }
     
    275291        }
    276292
    277         if ($allowMagicGet && $reflClass->hasMethod('__get') && (($r = $reflClass->getMethod('__get'))->getModifiers() & $this->methodReflectionFlags)) {
    278             return new PropertyReadInfo(PropertyReadInfo::TYPE_PROPERTY, $property, PropertyReadInfo::VISIBILITY_PUBLIC, false, $r->returnsReference());
    279         }
    280 
    281         if ($hasProperty && (($r = $reflClass->getProperty($property))->getModifiers() & $this->propertyReflectionFlags)) {
    282             return new PropertyReadInfo(PropertyReadInfo::TYPE_PROPERTY, $property, $this->getReadVisiblityForProperty($r), $r->isStatic(), true);
     293        if ($allowMagicGet && $reflClass->hasMethod('__get') && ($reflClass->getMethod('__get')->getModifiers() & $this->methodReflectionFlags)) {
     294            return new PropertyReadInfo(PropertyReadInfo::TYPE_PROPERTY, $property, PropertyReadInfo::VISIBILITY_PUBLIC, false, false);
     295        }
     296
     297        if ($hasProperty && ($reflClass->getProperty($property)->getModifiers() & $this->propertyReflectionFlags)) {
     298            $reflProperty = $reflClass->getProperty($property);
     299
     300            return new PropertyReadInfo(PropertyReadInfo::TYPE_PROPERTY, $property, $this->getReadVisiblityForProperty($reflProperty), $reflProperty->isStatic(), true);
    283301        }
    284302
     
    290308    }
    291309
     310    /**
     311     * {@inheritdoc}
     312     */
    292313    public function getWriteInfo(string $class, string $property, array $context = []): ?PropertyWriteInfo
    293314    {
    294315        try {
    295316            $reflClass = new \ReflectionClass($class);
    296         } catch (\ReflectionException) {
     317        } catch (\ReflectionException $e) {
    297318            return null;
    298319        }
     
    363384        if ($reflClass->hasProperty($property) && ($reflClass->getProperty($property)->getModifiers() & $this->propertyReflectionFlags)) {
    364385            $reflProperty = $reflClass->getProperty($property);
    365             if (!$reflProperty->isReadOnly()) {
    366                 return new PropertyWriteInfo(PropertyWriteInfo::TYPE_PROPERTY, $property, $this->getWriteVisiblityForProperty($reflProperty), $reflProperty->isStatic());
    367             }
    368 
    369             $errors[] = [\sprintf('The property "%s" in class "%s" is a promoted readonly property.', $property, $reflClass->getName())];
    370             $allowMagicSet = $allowMagicCall = false;
     386
     387            return new PropertyWriteInfo(PropertyWriteInfo::TYPE_PROPERTY, $property, $this->getWriteVisiblityForProperty($reflProperty), $reflProperty->isStatic());
    371388        }
    372389
     
    390407
    391408        if (!$allowAdderRemover && null !== $adderAccessName && null !== $removerAccessName) {
    392             $errors[] = [\sprintf(
     409            $errors[] = [sprintf(
    393410                'The property "%s" in class "%s" can be defined with the methods "%s()" but '.
    394411                'the new value must be an array or an instance of \Traversable',
     
    424441
    425442        if (1 === \count($type) && \in_array($prefix, $this->arrayMutatorPrefixes)) {
    426             $type = [new Type(Type::BUILTIN_TYPE_ARRAY, $this->isNullableProperty($class, $property), null, true, new Type(Type::BUILTIN_TYPE_INT), $type[0])];
     443            $type = [new Type(Type::BUILTIN_TYPE_ARRAY, false, null, true, new Type(Type::BUILTIN_TYPE_INT), $type[0])];
    427444        }
    428445
     
    462479        try {
    463480            $reflectionClass = new \ReflectionClass($class);
    464         } catch (\ReflectionException) {
     481        } catch (\ReflectionException $e) {
    465482            return null;
    466483        }
     
    499516                return $types;
    500517            }
    501         } catch (\ReflectionException) {
     518        } catch (\ReflectionException $e) {
    502519            return null;
    503520        }
     
    565582
    566583            return null !== $reflectionPropertyType && $reflectionPropertyType->allowsNull();
    567         } catch (\ReflectionException) {
     584        } catch (\ReflectionException $e) {
    568585            // Return false if the property doesn't exist
    569586        }
     
    577594            $reflectionProperty = new \ReflectionProperty($class, $property);
    578595
    579             if ($writeAccessRequired) {
    580                 if ($reflectionProperty->isReadOnly()) {
    581                     return false;
    582                 }
    583 
    584                 if (\PHP_VERSION_ID >= 80400 && $reflectionProperty->isProtectedSet()) {
    585                     return (bool) ($this->propertyReflectionFlags & \ReflectionProperty::IS_PROTECTED);
    586                 }
    587 
    588                 if (\PHP_VERSION_ID >= 80400 && $reflectionProperty->isPrivateSet()) {
    589                     return (bool) ($this->propertyReflectionFlags & \ReflectionProperty::IS_PRIVATE);
    590                 }
    591 
    592                 if (\PHP_VERSION_ID >= 80400 && $reflectionProperty->isVirtual() && !$reflectionProperty->hasHook(\PropertyHookType::Set)) {
    593                     return false;
    594                 }
     596            if (\PHP_VERSION_ID >= 80100 && $writeAccessRequired && $reflectionProperty->isReadOnly()) {
     597                return false;
    595598            }
    596599
    597600            return (bool) ($reflectionProperty->getModifiers() & $this->propertyReflectionFlags);
    598         } catch (\ReflectionException) {
     601        } catch (\ReflectionException $e) {
    599602            // Return false if the property doesn't exist
    600603        }
     
    623626                    return [$reflectionMethod, $prefix];
    624627                }
    625             } catch (\ReflectionException) {
     628            } catch (\ReflectionException $e) {
    626629                // Return null if the property doesn't exist
    627630            }
     
    655658                    }
    656659
    657                     // Parameter can be optional to allow things like: method(?array $foo = null)
     660                    // Parameter can be optional to allow things like: method(array $foo = null)
    658661                    if ($reflectionMethod->getNumberOfParameters() >= 1) {
    659662                        return [$reflectionMethod, $prefix];
    660663                    }
    661                 } catch (\ReflectionException) {
     664                } catch (\ReflectionException $e) {
    662665                    // Try the next prefix if the method doesn't exist
    663666                }
     
    722725
    723726            if ($addMethodFound && !$removeMethodFound) {
    724                 $errors[] = [\sprintf('The add method "%s" in class "%s" was found, but the corresponding remove method "%s" was not found', $addMethod, $reflClass->getName(), $removeMethod)];
     727                $errors[] = [sprintf('The add method "%s" in class "%s" was found, but the corresponding remove method "%s" was not found', $addMethod, $reflClass->getName(), $removeMethod)];
    725728            } elseif (!$addMethodFound && $removeMethodFound) {
    726                 $errors[] = [\sprintf('The remove method "%s" in class "%s" was found, but the corresponding add method "%s" was not found', $removeMethod, $reflClass->getName(), $addMethod)];
     729                $errors[] = [sprintf('The remove method "%s" in class "%s" was found, but the corresponding add method "%s" was not found', $removeMethod, $reflClass->getName(), $addMethod)];
    727730            }
    728731        }
     
    742745
    743746            if (\ReflectionMethod::IS_PUBLIC === $this->methodReflectionFlags && !$method->isPublic()) {
    744                 $errors[] = \sprintf('The method "%s" in class "%s" was found but does not have public access.', $methodName, $class->getName());
     747                $errors[] = sprintf('The method "%s" in class "%s" was found but does not have public access.', $methodName, $class->getName());
    745748            } elseif ($method->getNumberOfRequiredParameters() > $parameters || $method->getNumberOfParameters() < $parameters) {
    746                 $errors[] = \sprintf('The method "%s" in class "%s" requires %d arguments, but should accept only %d.', $methodName, $class->getName(), $method->getNumberOfRequiredParameters(), $parameters);
     749                $errors[] = sprintf('The method "%s" in class "%s" requires %d arguments, but should accept only %d.', $methodName, $class->getName(), $method->getNumberOfRequiredParameters(), $parameters);
    747750            } else {
    748751                return [true, $errors];
     
    833836    private function getWriteVisiblityForProperty(\ReflectionProperty $reflectionProperty): string
    834837    {
    835         if (\PHP_VERSION_ID >= 80400) {
    836             if ($reflectionProperty->isVirtual() && !$reflectionProperty->hasHook(\PropertyHookType::Set)) {
    837                 return PropertyWriteInfo::VISIBILITY_PRIVATE;
    838             }
    839 
    840             if ($reflectionProperty->isPrivateSet()) {
    841                 return PropertyWriteInfo::VISIBILITY_PRIVATE;
    842             }
    843 
    844             if ($reflectionProperty->isProtectedSet()) {
    845                 return PropertyWriteInfo::VISIBILITY_PROTECTED;
    846             }
    847         }
    848 
    849838        if ($reflectionProperty->isPrivate()) {
    850839            return PropertyWriteInfo::VISIBILITY_PRIVATE;
  • speechkit/trunk/vendor/symfony/property-info/Extractor/SerializerExtractor.php

    r3393083 r3420880  
    2424class SerializerExtractor implements PropertyListExtractorInterface
    2525{
    26     public function __construct(
    27         private readonly ClassMetadataFactoryInterface $classMetadataFactory,
    28     ) {
     26    private $classMetadataFactory;
     27
     28    public function __construct(ClassMetadataFactoryInterface $classMetadataFactory)
     29    {
     30        $this->classMetadataFactory = $classMetadataFactory;
    2931    }
    3032
     33    /**
     34     * {@inheritdoc}
     35     */
    3136    public function getProperties(string $class, array $context = []): ?array
    3237    {
     
    3540        }
    3641
    37         if (!$this->classMetadataFactory->hasMetadataFor($class)) {
     42        if (!$this->classMetadataFactory->getMetadataFor($class)) {
    3843            return null;
    3944        }
     
    4348
    4449        foreach ($serializerClassMetadata->getAttributesMetadata() as $serializerAttributeMetadata) {
    45             if (!$serializerAttributeMetadata->isIgnored() && (null === $context['serializer_groups'] || array_intersect($context['serializer_groups'], $serializerAttributeMetadata->getGroups()))) {
     50            $ignored = method_exists($serializerAttributeMetadata, 'isIgnored') && $serializerAttributeMetadata->isIgnored();
     51            if (!$ignored && (null === $context['serializer_groups'] || array_intersect($context['serializer_groups'], $serializerAttributeMetadata->getGroups()))) {
    4652                $properties[] = $serializerAttributeMetadata->getName();
    4753            }
  • speechkit/trunk/vendor/symfony/property-info/LICENSE

    r3169191 r3420880  
    1 Copyright (c) 2015-present Fabien Potencier
     1Copyright (c) 2015-2023 Fabien Potencier
    22
    33Permission is hereby granted, free of charge, to any person obtaining a copy
  • speechkit/trunk/vendor/symfony/property-info/PhpStan/NameScope.php

    r3393083 r3420880  
    2323final class NameScope
    2424{
    25     private string $calledClassName;
    26     private string $namespace;
     25    private $calledClassName;
     26    private $namespace;
    2727    /** @var array<string, string> alias(string) => fullName(string) */
    28     private array $uses;
     28    private $uses;
    2929
    3030    public function __construct(string $calledClassName, string $namespace, array $uses = [])
     
    3737    public function resolveStringName(string $name): string
    3838    {
    39         if (str_starts_with($name, '\\')) {
     39        if (0 === strpos($name, '\\')) {
    4040            return ltrim($name, '\\');
    4141        }
     
    4949            array_shift($nameParts);
    5050
    51             return \sprintf('%s\\%s', $this->uses[$firstNamePart], implode('\\', $nameParts));
     51            return sprintf('%s\\%s', $this->uses[$firstNamePart], implode('\\', $nameParts));
    5252        }
    5353
    5454        if (null !== $this->namespace) {
    55             return \sprintf('%s\\%s', $this->namespace, $name);
     55            return sprintf('%s\\%s', $this->namespace, $name);
    5656        }
    5757
  • speechkit/trunk/vendor/symfony/property-info/PhpStan/NameScopeFactory.php

    r3393083 r3420880  
    2121final class NameScopeFactory
    2222{
    23     public function create(string $calledClassName, ?string $declaringClassName = null): NameScope
     23    public function create(string $calledClassName, string $declaringClassName = null): NameScope
    2424    {
    25         $declaringClassName ??= $calledClassName;
     25        $declaringClassName = $declaringClassName ?? $calledClassName;
    2626
    2727        $path = explode('\\', $calledClassName);
     
    5757        if (\is_string($fileName) && is_file($fileName)) {
    5858            if (false === $contents = file_get_contents($fileName)) {
    59                 throw new \RuntimeException(\sprintf('Unable to read file "%s".', $fileName));
     59                throw new \RuntimeException(sprintf('Unable to read file "%s".', $fileName));
    6060            }
    6161
  • speechkit/trunk/vendor/symfony/property-info/PropertyInfoCacheExtractor.php

    r3169191 r3420880  
    2323class PropertyInfoCacheExtractor implements PropertyInfoExtractorInterface, PropertyInitializableExtractorInterface
    2424{
    25     private array $arrayCache = [];
     25    private $propertyInfoExtractor;
     26    private $cacheItemPool;
     27    private $arrayCache = [];
    2628
    27     public function __construct(
    28         private readonly PropertyInfoExtractorInterface $propertyInfoExtractor,
    29         private readonly CacheItemPoolInterface $cacheItemPool,
    30     ) {
     29    public function __construct(PropertyInfoExtractorInterface $propertyInfoExtractor, CacheItemPoolInterface $cacheItemPool)
     30    {
     31        $this->propertyInfoExtractor = $propertyInfoExtractor;
     32        $this->cacheItemPool = $cacheItemPool;
    3133    }
    3234
     35    /**
     36     * {@inheritdoc}
     37     */
    3338    public function isReadable(string $class, string $property, array $context = []): ?bool
    3439    {
     
    3641    }
    3742
     43    /**
     44     * {@inheritdoc}
     45     */
    3846    public function isWritable(string $class, string $property, array $context = []): ?bool
    3947    {
     
    4149    }
    4250
     51    /**
     52     * {@inheritdoc}
     53     */
    4354    public function getShortDescription(string $class, string $property, array $context = []): ?string
    4455    {
     
    4657    }
    4758
     59    /**
     60     * {@inheritdoc}
     61     */
    4862    public function getLongDescription(string $class, string $property, array $context = []): ?string
    4963    {
     
    5165    }
    5266
     67    /**
     68     * {@inheritdoc}
     69     */
    5370    public function getProperties(string $class, array $context = []): ?array
    5471    {
     
    5673    }
    5774
     75    /**
     76     * {@inheritdoc}
     77     */
    5878    public function getTypes(string $class, string $property, array $context = []): ?array
    5979    {
     
    6181    }
    6282
     83    /**
     84     * {@inheritdoc}
     85     */
    6386    public function isInitializable(string $class, string $property, array $context = []): ?bool
    6487    {
     
    7396        try {
    7497            $serializedArguments = serialize($arguments);
    75         } catch (\Exception) {
     98        } catch (\Exception $exception) {
    7699            // If arguments are not serializable, skip the cache
    77100            return $this->propertyInfoExtractor->{$method}(...$arguments);
  • speechkit/trunk/vendor/symfony/property-info/PropertyInfoExtractor.php

    r3169191 r3420880  
    2121class PropertyInfoExtractor implements PropertyInfoExtractorInterface, PropertyInitializableExtractorInterface
    2222{
     23    private $listExtractors;
     24    private $typeExtractors;
     25    private $descriptionExtractors;
     26    private $accessExtractors;
     27    private $initializableExtractors;
     28
    2329    /**
    2430     * @param iterable<mixed, PropertyListExtractorInterface>          $listExtractors
     
    2834     * @param iterable<mixed, PropertyInitializableExtractorInterface> $initializableExtractors
    2935     */
    30     public function __construct(
    31         private readonly iterable $listExtractors = [],
    32         private readonly iterable $typeExtractors = [],
    33         private readonly iterable $descriptionExtractors = [],
    34         private readonly iterable $accessExtractors = [],
    35         private readonly iterable $initializableExtractors = [],
    36     ) {
     36    public function __construct(iterable $listExtractors = [], iterable $typeExtractors = [], iterable $descriptionExtractors = [], iterable $accessExtractors = [], iterable $initializableExtractors = [])
     37    {
     38        $this->listExtractors = $listExtractors;
     39        $this->typeExtractors = $typeExtractors;
     40        $this->descriptionExtractors = $descriptionExtractors;
     41        $this->accessExtractors = $accessExtractors;
     42        $this->initializableExtractors = $initializableExtractors;
    3743    }
    3844
     45    /**
     46     * {@inheritdoc}
     47     */
    3948    public function getProperties(string $class, array $context = []): ?array
    4049    {
     
    4251    }
    4352
     53    /**
     54     * {@inheritdoc}
     55     */
    4456    public function getShortDescription(string $class, string $property, array $context = []): ?string
    4557    {
     
    4759    }
    4860
     61    /**
     62     * {@inheritdoc}
     63     */
    4964    public function getLongDescription(string $class, string $property, array $context = []): ?string
    5065    {
     
    5267    }
    5368
     69    /**
     70     * {@inheritdoc}
     71     */
    5472    public function getTypes(string $class, string $property, array $context = []): ?array
    5573    {
     
    5775    }
    5876
     77    /**
     78     * {@inheritdoc}
     79     */
    5980    public function isReadable(string $class, string $property, array $context = []): ?bool
    6081    {
     
    6283    }
    6384
     85    /**
     86     * {@inheritdoc}
     87     */
    6488    public function isWritable(string $class, string $property, array $context = []): ?bool
    6589    {
     
    6791    }
    6892
     93    /**
     94     * {@inheritdoc}
     95     */
    6996    public function isInitializable(string $class, string $property, array $context = []): ?bool
    7097    {
  • speechkit/trunk/vendor/symfony/property-info/PropertyReadInfo.php

    r3233685 r3420880  
    1616 *
    1717 * @author Joel Wurtz <jwurtz@jolicode.com>
     18 *
     19 * @internal
    1820 */
    1921final class PropertyReadInfo
     
    2628    public const VISIBILITY_PRIVATE = 'private';
    2729
    28     public function __construct(
    29         private readonly string $type,
    30         private readonly string $name,
    31         private readonly string $visibility,
    32         private readonly bool $static,
    33         private readonly bool $byRef,
    34     ) {
     30    private $type;
     31
     32    private $name;
     33
     34    private $visibility;
     35
     36    private $static;
     37
     38    private $byRef;
     39
     40    public function __construct(string $type, string $name, string $visibility, bool $static, bool $byRef)
     41    {
     42        $this->type = $type;
     43        $this->name = $name;
     44        $this->visibility = $visibility;
     45        $this->static = $static;
     46        $this->byRef = $byRef;
    3547    }
    3648
  • speechkit/trunk/vendor/symfony/property-info/PropertyWriteInfo.php

    r3233685 r3420880  
    1616 *
    1717 * @author Joel Wurtz <jwurtz@jolicode.com>
     18 *
     19 * @internal
    1820 */
    1921final class PropertyWriteInfo
     
    2931    public const VISIBILITY_PRIVATE = 'private';
    3032
    31     private ?self $adderInfo = null;
    32     private ?self $removerInfo = null;
    33     private array $errors = [];
     33    private $type;
     34    private $name;
     35    private $visibility;
     36    private $static;
     37    private $adderInfo;
     38    private $removerInfo;
     39    private $errors = [];
    3440
    35     public function __construct(
    36         private readonly string $type = self::TYPE_NONE,
    37         private readonly ?string $name = null,
    38         private readonly ?string $visibility = null,
    39         private readonly ?bool $static = null,
    40     ) {
     41    public function __construct(string $type = self::TYPE_NONE, string $name = null, string $visibility = null, bool $static = null)
     42    {
     43        $this->type = $type;
     44        $this->name = $name;
     45        $this->visibility = $visibility;
     46        $this->static = $static;
    4147    }
    4248
  • speechkit/trunk/vendor/symfony/property-info/Type.php

    r3393083 r3420880  
    6464    ];
    6565
    66     private string $builtinType;
    67     private bool $nullable;
    68     private ?string $class;
    69     private bool $collection;
    70     private array $collectionKeyType;
    71     private array $collectionValueType;
     66    private $builtinType;
     67    private $nullable;
     68    private $class;
     69    private $collection;
     70    private $collectionKeyType;
     71    private $collectionValueType;
    7272
    7373    /**
     
    7777     * @throws \InvalidArgumentException
    7878     */
    79     public function __construct(string $builtinType, bool $nullable = false, ?string $class = null, bool $collection = false, array|self|null $collectionKeyType = null, array|self|null $collectionValueType = null)
     79    public function __construct(string $builtinType, bool $nullable = false, string $class = null, bool $collection = false, array|Type $collectionKeyType = null, array|Type $collectionValueType = null)
    8080    {
    8181        if (!\in_array($builtinType, self::$builtinTypes)) {
    82             throw new \InvalidArgumentException(\sprintf('"%s" is not a valid PHP type.', $builtinType));
     82            throw new \InvalidArgumentException(sprintf('"%s" is not a valid PHP type.', $builtinType));
    8383        }
    8484
     
    9191    }
    9292
    93     private function validateCollectionArgument(array|self|null $collectionArgument, int $argumentIndex, string $argumentName): ?array
     93    private function validateCollectionArgument(array|Type|null $collectionArgument, int $argumentIndex, string $argumentName): ?array
    9494    {
    9595        if (null === $collectionArgument) {
     
    100100            foreach ($collectionArgument as $type) {
    101101                if (!$type instanceof self) {
    102                     throw new \TypeError(\sprintf('"%s()": Argument #%d (%s) must be of type "%s[]", "%s" or "null", array value "%s" given.', __METHOD__, $argumentIndex, $argumentName, self::class, self::class, get_debug_type($collectionArgument)));
     102                    throw new \TypeError(sprintf('"%s()": Argument #%d (%s) must be of type "%s[]", "%s" or "null", array value "%s" given.', __METHOD__, $argumentIndex, $argumentName, self::class, self::class, get_debug_type($collectionArgument)));
    103103                }
    104104            }
  • speechkit/trunk/vendor/symfony/property-info/Util/PhpDocTypeHelper.php

    r3393083 r3420880  
    1212namespace Symfony\Component\PropertyInfo\Util;
    1313
    14 use phpDocumentor\Reflection\PseudoType;
    1514use phpDocumentor\Reflection\PseudoTypes\ConstExpression;
    1615use phpDocumentor\Reflection\PseudoTypes\List_;
     
    1918use phpDocumentor\Reflection\Types\Collection;
    2019use phpDocumentor\Reflection\Types\Compound;
    21 use phpDocumentor\Reflection\Types\Integer;
    2220use phpDocumentor\Reflection\Types\Null_;
    2321use phpDocumentor\Reflection\Types\Nullable;
    24 use phpDocumentor\Reflection\Types\String_;
    2522use Symfony\Component\PropertyInfo\Type;
    2623
     
    106103     * Creates a {@see Type} from a PHPDoc type.
    107104     */
    108     private function createType(DocType $type, bool $nullable): ?Type
    109     {
    110         $docType = (string) $type;
     105    private function createType(DocType $type, bool $nullable, string $docType = null): ?Type
     106    {
     107        $docType = $docType ?? (string) $type;
    111108
    112109        if ($type instanceof Collection) {
     
    119116            [$phpType, $class] = $this->getPhpTypeAndClass((string) $fqsen);
    120117
    121             $collection = is_a($class, \Traversable::class, true) || is_a($class, \ArrayAccess::class, true);
    122 
    123             // it's safer to fall back to other extractors if the generic type is too abstract
    124             if (!$collection && !class_exists($class)) {
    125                 return null;
    126             }
    127 
    128             $keys = $this->getTypes($type->getKeyType());
    129             $values = $this->getTypes($type->getValueType());
    130 
    131             return new Type($phpType, $nullable, $class, $collection, $keys, $values);
     118            $key = $this->getTypes($type->getKeyType());
     119            $value = $this->getTypes($type->getValueType());
     120
     121            // More than 1 type returned means it is a Compound type, which is
     122            // not handled by Type, so better use a null value.
     123            $key = 1 === \count($key) ? $key[0] : null;
     124            $value = 1 === \count($value) ? $value[0] : null;
     125
     126            return new Type($phpType, $nullable, $class, true, $key, $value);
    132127        }
    133128
     
    137132        }
    138133
    139         if (str_ends_with($docType, '[]') && $type instanceof Array_) {
    140             $collectionKeyTypes = new Type(Type::BUILTIN_TYPE_INT);
    141             $collectionValueTypes = $this->getTypes($type->getValueType());
    142 
    143             return new Type(Type::BUILTIN_TYPE_ARRAY, $nullable, null, true, $collectionKeyTypes, $collectionValueTypes);
     134        if (str_ends_with($docType, '[]')) {
     135            $collectionKeyType = new Type(Type::BUILTIN_TYPE_INT);
     136            $collectionValueType = $this->createType($type, false, substr($docType, 0, -2));
     137
     138            return new Type(Type::BUILTIN_TYPE_ARRAY, $nullable, null, true, $collectionKeyType, $collectionValueType);
    144139        }
    145140
     
    147142            // array<value> is converted to x[] which is handled above
    148143            // so it's only necessary to handle array<key, value> here
    149             $collectionKeyTypes = $this->getTypes($type->getKeyType());
     144            $collectionKeyType = $this->getTypes($type->getKeyType())[0];
     145
    150146            $collectionValueTypes = $this->getTypes($type->getValueType());
    151 
    152             return new Type(Type::BUILTIN_TYPE_ARRAY, $nullable, null, true, $collectionKeyTypes, $collectionValueTypes);
    153         }
    154 
    155         if ($type instanceof PseudoType) {
    156             if ($type->underlyingType() instanceof Integer) {
    157                 return new Type(Type::BUILTIN_TYPE_INT, $nullable, null);
    158             } elseif ($type->underlyingType() instanceof String_) {
    159                 return new Type(Type::BUILTIN_TYPE_STRING, $nullable, null);
    160             }
     147            if (1 != \count($collectionValueTypes)) {
     148                // the Type class does not support union types yet, so assume that no type was defined
     149                $collectionValueType = null;
     150            } else {
     151                $collectionValueType = $collectionValueTypes[0];
     152            }
     153
     154            return new Type(Type::BUILTIN_TYPE_ARRAY, $nullable, null, true, $collectionKeyType, $collectionValueType);
    161155        }
    162156
     
    173167    private function normalizeType(string $docType): string
    174168    {
    175         return match ($docType) {
    176             'integer' => 'int',
    177             'boolean' => 'bool',
     169        switch ($docType) {
     170            case 'integer':
     171                return 'int';
     172
     173            case 'boolean':
     174                return 'bool';
     175
    178176            // real is not part of the PHPDoc standard, so we ignore it
    179             'double' => 'float',
    180             'callback' => 'callable',
    181             'void' => 'null',
    182             default => $docType,
    183         };
     177            case 'double':
     178                return 'float';
     179
     180            case 'callback':
     181                return 'callable';
     182
     183            case 'void':
     184                return 'null';
     185
     186            default:
     187                return $docType;
     188        }
    184189    }
    185190
  • speechkit/trunk/vendor/symfony/property-info/Util/PhpStanTypeHelper.php

    r3393083 r3420880  
    116116        }
    117117        if ($node instanceof GenericTypeNode) {
    118             if ('class-string' === $node->type->name) {
    119                 return [new Type(Type::BUILTIN_TYPE_STRING)];
    120             }
    121 
    122118            [$mainType] = $this->extractTypes($node->type, $nameScope);
    123119
    124120            if (Type::BUILTIN_TYPE_INT === $mainType->getBuiltinType()) {
    125121                return [$mainType];
    126             }
    127 
    128             $collection = $mainType->isCollection() || is_a($mainType->getClassName(), \Traversable::class, true) || is_a($mainType->getClassName(), \ArrayAccess::class, true);
    129 
    130             // it's safer to fall back to other extractors if the generic type is too abstract
    131             if (!$collection && !class_exists($mainType->getClassName()) && !interface_exists($mainType->getClassName(), false)) {
    132                 return [];
    133122            }
    134123
     
    148137            }
    149138
    150             return [new Type($mainType->getBuiltinType(), $mainType->isNullable(), $mainType->getClassName(), $collection, $collectionKeyTypes, $collectionKeyValues)];
     139            return [new Type($mainType->getBuiltinType(), $mainType->isNullable(), $mainType->getClassName(), true, $collectionKeyTypes, $collectionKeyValues)];
    151140        }
    152141        if ($node instanceof ArrayShapeNode) {
     
    177166            }
    178167
    179             return match ($node->name) {
    180                 'integer',
    181                 'positive-int',
    182                 'negative-int' => [new Type(Type::BUILTIN_TYPE_INT)],
    183                 'double' => [new Type(Type::BUILTIN_TYPE_FLOAT)],
    184                 'list',
    185                 'non-empty-list' => [new Type(Type::BUILTIN_TYPE_ARRAY, false, null, true, new Type(Type::BUILTIN_TYPE_INT))],
    186                 'non-empty-array' => [new Type(Type::BUILTIN_TYPE_ARRAY, false, null, true)],
    187                 'mixed' => [], // mixed seems to be ignored in all other extractors
    188                 'parent' => [new Type(Type::BUILTIN_TYPE_OBJECT, false, $node->name)],
    189                 'static',
    190                 'self' => [new Type(Type::BUILTIN_TYPE_OBJECT, false, $nameScope->resolveRootClass())],
    191                 'class-string',
    192                 'html-escaped-string',
    193                 'lowercase-string',
    194                 'non-empty-lowercase-string',
    195                 'non-empty-string',
    196                 'numeric-string',
    197                 'trait-string',
    198                 'interface-string',
    199                 'literal-string' => [new Type(Type::BUILTIN_TYPE_STRING)],
    200                 'void' => [new Type(Type::BUILTIN_TYPE_NULL)],
    201                 'scalar' => [new Type(Type::BUILTIN_TYPE_INT), new Type(Type::BUILTIN_TYPE_FLOAT), new Type(Type::BUILTIN_TYPE_STRING), new Type(Type::BUILTIN_TYPE_BOOL)],
    202                 'number' => [new Type(Type::BUILTIN_TYPE_INT), new Type(Type::BUILTIN_TYPE_FLOAT)],
    203                 'numeric' => [new Type(Type::BUILTIN_TYPE_INT), new Type(Type::BUILTIN_TYPE_FLOAT), new Type(Type::BUILTIN_TYPE_STRING)],
    204                 'array-key' => [new Type(Type::BUILTIN_TYPE_STRING), new Type(Type::BUILTIN_TYPE_INT)],
    205                 default => [new Type(Type::BUILTIN_TYPE_OBJECT, false, $nameScope->resolveStringName($node->name))],
    206             };
     168            switch ($node->name) {
     169                case 'integer':
     170                    return [new Type(Type::BUILTIN_TYPE_INT)];
     171                case 'list':
     172                case 'non-empty-list':
     173                    return [new Type(Type::BUILTIN_TYPE_ARRAY, false, null, true, new Type(Type::BUILTIN_TYPE_INT))];
     174                case 'non-empty-array':
     175                    return [new Type(Type::BUILTIN_TYPE_ARRAY, false, null, true)];
     176                case 'mixed':
     177                    return []; // mixed seems to be ignored in all other extractors
     178                case 'parent':
     179                    return [new Type(Type::BUILTIN_TYPE_OBJECT, false, $node->name)];
     180                case 'static':
     181                case 'self':
     182                    return [new Type(Type::BUILTIN_TYPE_OBJECT, false, $nameScope->resolveRootClass())];
     183                case 'void':
     184                    return [new Type(Type::BUILTIN_TYPE_NULL)];
     185            }
     186
     187            return [new Type(Type::BUILTIN_TYPE_OBJECT, false, $nameScope->resolveStringName($node->name))];
    207188        }
    208189
  • speechkit/trunk/vendor/symfony/property-info/composer.json

    r3393083 r3420880  
    66        "property",
    77        "type",
    8         "phpdoc",
     8        "PHPDoc",
    99        "symfony",
    1010        "validator",
     
    2424    ],
    2525    "require": {
    26         "php": ">=8.1",
    27         "symfony/string": "^5.4|^6.0|^7.0"
     26        "php": ">=8.0.2",
     27        "symfony/string": "^5.4|^6.0"
    2828    },
    2929    "require-dev": {
    30         "doctrine/annotations": "^1.12|^2",
    31         "symfony/serializer": "^5.4|^6.4|^7.0",
    32         "symfony/cache": "^5.4|^6.0|^7.0",
    33         "symfony/dependency-injection": "^5.4|^6.0|^7.0",
     30        "symfony/serializer": "^5.4|^6.0",
     31        "symfony/cache": "^5.4|^6.0",
     32        "symfony/dependency-injection": "^5.4|^6.0",
    3433        "phpdocumentor/reflection-docblock": "^5.2",
    35         "phpstan/phpdoc-parser": "^1.0|^2.0"
     34        "phpstan/phpdoc-parser": "^1.0",
     35        "doctrine/annotations": "^1.10.4|^2"
    3636    },
    3737    "conflict": {
    38         "doctrine/annotations": "<1.12",
    3938        "phpdocumentor/reflection-docblock": "<5.2",
    40         "phpdocumentor/type-resolver": "<1.5.1",
    41         "symfony/dependency-injection": "<5.4|>=6.0,<6.4",
    42         "symfony/cache": "<5.4",
    43         "symfony/serializer": "<5.4"
     39        "phpdocumentor/type-resolver": "<1.4.0",
     40        "symfony/dependency-injection": "<5.4"
     41    },
     42    "suggest": {
     43        "psr/cache-implementation": "To cache results",
     44        "symfony/doctrine-bridge": "To use Doctrine metadata",
     45        "phpdocumentor/reflection-docblock": "To use the PHPDoc",
     46        "symfony/serializer": "To use Serializer metadata"
    4447    },
    4548    "autoload": {
  • speechkit/trunk/vendor/symfony/string/AbstractString.php

    r3393083 r3420880  
    4040    public const PREG_SPLIT_OFFSET_CAPTURE = \PREG_SPLIT_OFFSET_CAPTURE;
    4141
    42     protected string $string = '';
    43     protected ?bool $ignoreCase = false;
     42    protected $string = '';
     43    protected $ignoreCase = false;
    4444
    4545    abstract public function __construct(string $string = '');
     
    7575        foreach ($values as $k => $v) {
    7676            if (\is_string($k) && '' !== $k && $k !== $j = (string) new static($k)) {
    77                 $keys ??= array_keys($values);
     77                $keys = $keys ?? array_keys($values);
    7878                $keys[$i] = $j;
    7979            }
     
    9393    /**
    9494     * @param string|string[] $needle
    95      */
    96     public function after(string|iterable $needle, bool $includeNeedle = false, int $offset = 0): static
     95     *
     96     * @return static
     97     */
     98    public function after($needle, bool $includeNeedle = false, int $offset = 0): self
    9799    {
    98100        $str = clone $this;
    99101        $i = \PHP_INT_MAX;
    100102
    101         if (\is_string($needle)) {
    102             $needle = [$needle];
    103         }
    104 
    105         foreach ($needle as $n) {
     103        foreach ((array) $needle as $n) {
    106104            $n = (string) $n;
    107105            $j = $this->indexOf($n, $offset);
     
    126124    /**
    127125     * @param string|string[] $needle
    128      */
    129     public function afterLast(string|iterable $needle, bool $includeNeedle = false, int $offset = 0): static
     126     *
     127     * @return static
     128     */
     129    public function afterLast($needle, bool $includeNeedle = false, int $offset = 0): self
    130130    {
    131131        $str = clone $this;
    132132        $i = null;
    133133
    134         if (\is_string($needle)) {
    135             $needle = [$needle];
    136         }
    137 
    138         foreach ($needle as $n) {
     134        foreach ((array) $needle as $n) {
    139135            $n = (string) $n;
    140136            $j = $this->indexOfLast($n, $offset);
     
    157153    }
    158154
    159     abstract public function append(string ...$suffix): static;
     155    /**
     156     * @return static
     157     */
     158    abstract public function append(string ...$suffix): self;
    160159
    161160    /**
    162161     * @param string|string[] $needle
    163      */
    164     public function before(string|iterable $needle, bool $includeNeedle = false, int $offset = 0): static
     162     *
     163     * @return static
     164     */
     165    public function before($needle, bool $includeNeedle = false, int $offset = 0): self
    165166    {
    166167        $str = clone $this;
    167168        $i = \PHP_INT_MAX;
    168169
    169         if (\is_string($needle)) {
    170             $needle = [$needle];
    171         }
    172 
    173         foreach ($needle as $n) {
     170        foreach ((array) $needle as $n) {
    174171            $n = (string) $n;
    175172            $j = $this->indexOf($n, $offset);
     
    194191    /**
    195192     * @param string|string[] $needle
    196      */
    197     public function beforeLast(string|iterable $needle, bool $includeNeedle = false, int $offset = 0): static
     193     *
     194     * @return static
     195     */
     196    public function beforeLast($needle, bool $includeNeedle = false, int $offset = 0): self
    198197    {
    199198        $str = clone $this;
    200199        $i = null;
    201200
    202         if (\is_string($needle)) {
    203             $needle = [$needle];
    204         }
    205 
    206         foreach ($needle as $n) {
     201        foreach ((array) $needle as $n) {
    207202            $n = (string) $n;
    208203            $j = $this->indexOfLast($n, $offset);
     
    235230    }
    236231
    237     abstract public function camel(): static;
     232    /**
     233     * @return static
     234     */
     235    abstract public function camel(): self;
    238236
    239237    /**
     
    242240    abstract public function chunk(int $length = 1): array;
    243241
    244     public function collapseWhitespace(): static
     242    /**
     243     * @return static
     244     */
     245    public function collapseWhitespace(): self
    245246    {
    246247        $str = clone $this;
     
    253254     * @param string|string[] $needle
    254255     */
    255     public function containsAny(string|iterable $needle): bool
     256    public function containsAny($needle): bool
    256257    {
    257258        return null !== $this->indexOf($needle);
     
    261262     * @param string|string[] $suffix
    262263     */
    263     public function endsWith(string|iterable $suffix): bool
    264     {
    265         if (\is_string($suffix)) {
    266             throw new \TypeError(\sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
     264    public function endsWith($suffix): bool
     265    {
     266        if (!\is_array($suffix) && !$suffix instanceof \Traversable) {
     267            throw new \TypeError(sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
    267268        }
    268269
     
    276277    }
    277278
    278     public function ensureEnd(string $suffix): static
     279    /**
     280     * @return static
     281     */
     282    public function ensureEnd(string $suffix): self
    279283    {
    280284        if (!$this->endsWith($suffix)) {
     
    288292    }
    289293
    290     public function ensureStart(string $prefix): static
     294    /**
     295     * @return static
     296     */
     297    public function ensureStart(string $prefix): self
    291298    {
    292299        $prefix = new static($prefix);
     
    310317     * @param string|string[] $string
    311318     */
    312     public function equalsTo(string|iterable $string): bool
    313     {
    314         if (\is_string($string)) {
    315             throw new \TypeError(\sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
     319    public function equalsTo($string): bool
     320    {
     321        if (!\is_array($string) && !$string instanceof \Traversable) {
     322            throw new \TypeError(sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
    316323        }
    317324
     
    325332    }
    326333
    327     abstract public function folded(): static;
    328 
    329     public function ignoreCase(): static
     334    /**
     335     * @return static
     336     */
     337    abstract public function folded(): self;
     338
     339    /**
     340     * @return static
     341     */
     342    public function ignoreCase(): self
    330343    {
    331344        $str = clone $this;
     
    338351     * @param string|string[] $needle
    339352     */
    340     public function indexOf(string|iterable $needle, int $offset = 0): ?int
    341     {
    342         if (\is_string($needle)) {
    343             throw new \TypeError(\sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
     353    public function indexOf($needle, int $offset = 0): ?int
     354    {
     355        if (!\is_array($needle) && !$needle instanceof \Traversable) {
     356            throw new \TypeError(sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
    344357        }
    345358
     
    360373     * @param string|string[] $needle
    361374     */
    362     public function indexOfLast(string|iterable $needle, int $offset = 0): ?int
    363     {
    364         if (\is_string($needle)) {
    365             throw new \TypeError(\sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
     375    public function indexOfLast($needle, int $offset = 0): ?int
     376    {
     377        if (!\is_array($needle) && !$needle instanceof \Traversable) {
     378            throw new \TypeError(sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
    366379        }
    367380
     
    384397    }
    385398
    386     abstract public function join(array $strings, ?string $lastGlue = null): static;
     399    /**
     400     * @return static
     401     */
     402    abstract public function join(array $strings, ?string $lastGlue = null): self;
    387403
    388404    public function jsonSerialize(): string
     
    393409    abstract public function length(): int;
    394410
    395     abstract public function lower(): static;
     411    /**
     412     * @return static
     413     */
     414    abstract public function lower(): self;
    396415
    397416    /**
     
    404423    abstract public function match(string $regexp, int $flags = 0, int $offset = 0): array;
    405424
    406     abstract public function padBoth(int $length, string $padStr = ' '): static;
    407 
    408     abstract public function padEnd(int $length, string $padStr = ' '): static;
    409 
    410     abstract public function padStart(int $length, string $padStr = ' '): static;
    411 
    412     abstract public function prepend(string ...$prefix): static;
    413 
    414     public function repeat(int $multiplier): static
     425    /**
     426     * @return static
     427     */
     428    abstract public function padBoth(int $length, string $padStr = ' '): self;
     429
     430    /**
     431     * @return static
     432     */
     433    abstract public function padEnd(int $length, string $padStr = ' '): self;
     434
     435    /**
     436     * @return static
     437     */
     438    abstract public function padStart(int $length, string $padStr = ' '): self;
     439
     440    /**
     441     * @return static
     442     */
     443    abstract public function prepend(string ...$prefix): self;
     444
     445    /**
     446     * @return static
     447     */
     448    public function repeat(int $multiplier): self
    415449    {
    416450        if (0 > $multiplier) {
    417             throw new InvalidArgumentException(\sprintf('Multiplier must be positive, %d given.', $multiplier));
     451            throw new InvalidArgumentException(sprintf('Multiplier must be positive, %d given.', $multiplier));
    418452        }
    419453
     
    424458    }
    425459
    426     abstract public function replace(string $from, string $to): static;
    427 
    428     abstract public function replaceMatches(string $fromRegexp, string|callable $to): static;
    429 
    430     abstract public function reverse(): static;
    431 
    432     abstract public function slice(int $start = 0, ?int $length = null): static;
    433 
    434     abstract public function snake(): static;
    435 
    436     public function kebab(): static
    437     {
    438         return $this->snake()->replace('_', '-');
    439     }
    440 
    441     public function pascal(): static
    442     {
    443         return $this->camel()->title();
    444     }
    445 
    446     abstract public function splice(string $replacement, int $start = 0, ?int $length = null): static;
     460    /**
     461     * @return static
     462     */
     463    abstract public function replace(string $from, string $to): self;
     464
     465    /**
     466     * @param string|callable $to
     467     *
     468     * @return static
     469     */
     470    abstract public function replaceMatches(string $fromRegexp, $to): self;
     471
     472    /**
     473     * @return static
     474     */
     475    abstract public function reverse(): self;
     476
     477    /**
     478     * @return static
     479     */
     480    abstract public function slice(int $start = 0, ?int $length = null): self;
     481
     482    /**
     483     * @return static
     484     */
     485    abstract public function snake(): self;
     486
     487    /**
     488     * @return static
     489     */
     490    abstract public function splice(string $replacement, int $start = 0, ?int $length = null): self;
    447491
    448492    /**
     
    459503        }
    460504
    461         set_error_handler(static fn ($t, $m) => throw new InvalidArgumentException($m));
     505        set_error_handler(static function ($t, $m) { throw new InvalidArgumentException($m); });
    462506
    463507        try {
    464508            if (false === $chunks = preg_split($delimiter, $this->string, $limit, $flags)) {
    465                 throw new RuntimeException('Splitting failed with error: '.preg_last_error_msg());
     509                $lastError = preg_last_error();
     510
     511                foreach (get_defined_constants(true)['pcre'] as $k => $v) {
     512                    if ($lastError === $v && '_ERROR' === substr($k, -6)) {
     513                        throw new RuntimeException('Splitting failed with '.$k.'.');
     514                    }
     515                }
     516
     517                throw new RuntimeException('Splitting failed with unknown error code.');
    466518            }
    467519        } finally {
     
    489541     * @param string|string[] $prefix
    490542     */
    491     public function startsWith(string|iterable $prefix): bool
    492     {
    493         if (\is_string($prefix)) {
    494             throw new \TypeError(\sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
     543    public function startsWith($prefix): bool
     544    {
     545        if (!\is_array($prefix) && !$prefix instanceof \Traversable) {
     546            throw new \TypeError(sprintf('Method "%s()" must be overridden by class "%s" to deal with non-iterable values.', __FUNCTION__, static::class));
    495547        }
    496548
     
    504556    }
    505557
    506     abstract public function title(bool $allWords = false): static;
     558    /**
     559     * @return static
     560     */
     561    abstract public function title(bool $allWords = false): self;
    507562
    508563    public function toByteString(?string $toEncoding = null): ByteString
     
    518573        }
    519574
     575        set_error_handler(static function ($t, $m) { throw new InvalidArgumentException($m); });
     576
    520577        try {
    521             $b->string = mb_convert_encoding($this->string, $toEncoding, 'UTF-8');
    522         } catch (\ValueError $e) {
    523             if (!\function_exists('iconv')) {
    524                 throw new InvalidArgumentException($e->getMessage(), $e->getCode(), $e);
    525             }
    526 
    527             $b->string = iconv('UTF-8', $toEncoding, $this->string);
     578            try {
     579                $b->string = mb_convert_encoding($this->string, $toEncoding, 'UTF-8');
     580            } catch (InvalidArgumentException|\ValueError $e) {
     581                if (!\function_exists('iconv')) {
     582                    if ($e instanceof \ValueError) {
     583                        throw new InvalidArgumentException($e->getMessage(), $e->getCode(), $e);
     584                    }
     585                    throw $e;
     586                }
     587
     588                $b->string = iconv('UTF-8', $toEncoding, $this->string);
     589            }
     590        } finally {
     591            restore_error_handler();
    528592        }
    529593
     
    546610    }
    547611
    548     abstract public function trim(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): static;
    549 
    550     abstract public function trimEnd(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): static;
     612    /**
     613     * @return static
     614     */
     615    abstract public function trim(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): self;
     616
     617    /**
     618     * @return static
     619     */
     620    abstract public function trimEnd(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): self;
    551621
    552622    /**
    553623     * @param string|string[] $prefix
    554      */
    555     public function trimPrefix($prefix): static
    556     {
    557         if (\is_array($prefix) || $prefix instanceof \Traversable) { // don't use is_iterable(), it's slow
     624     *
     625     * @return static
     626     */
     627    public function trimPrefix($prefix): self
     628    {
     629        if (\is_array($prefix) || $prefix instanceof \Traversable) {
    558630            foreach ($prefix as $s) {
    559631                $t = $this->trimPrefix($s);
     
    582654    }
    583655
    584     abstract public function trimStart(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): static;
     656    /**
     657     * @return static
     658     */
     659    abstract public function trimStart(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): self;
    585660
    586661    /**
    587662     * @param string|string[] $suffix
    588      */
    589     public function trimSuffix($suffix): static
    590     {
    591         if (\is_array($suffix) || $suffix instanceof \Traversable) { // don't use is_iterable(), it's slow
     663     *
     664     * @return static
     665     */
     666    public function trimSuffix($suffix): self
     667    {
     668        if (\is_array($suffix) || $suffix instanceof \Traversable) {
    592669            foreach ($suffix as $s) {
    593670                $t = $this->trimSuffix($s);
     
    616693    }
    617694
    618     public function truncate(int $length, string $ellipsis = '', bool|TruncateMode $cut = TruncateMode::Char): static
     695    /**
     696     * @return static
     697     */
     698    public function truncate(int $length, string $ellipsis = '', bool $cut = true): self
    619699    {
    620700        $stringLength = $this->length();
     
    630710        }
    631711
    632         $desiredLength = $length;
    633         if (TruncateMode::WordAfter === $cut || !$cut) {
     712        if (!$cut) {
    634713            if (null === $length = $this->indexOf([' ', "\r", "\n", "\t"], ($length ?: 1) - 1)) {
    635714                return clone $this;
     
    637716
    638717            $length += $ellipsisLength;
    639         } elseif (TruncateMode::WordBefore === $cut && null !== $this->indexOf([' ', "\r", "\n", "\t"], ($length ?: 1) - 1)) {
    640             $length += $ellipsisLength;
    641718        }
    642719
    643720        $str = $this->slice(0, $length - $ellipsisLength);
    644721
    645         if (TruncateMode::WordBefore === $cut) {
    646             if (0 === $ellipsisLength && $desiredLength === $this->indexOf([' ', "\r", "\n", "\t"], $length)) {
    647                 return $str;
    648             }
    649 
    650             $str = $str->beforeLast([' ', "\r", "\n", "\t"]);
    651         }
    652 
    653722        return $ellipsisLength ? $str->trimEnd()->append($ellipsis) : $str;
    654723    }
    655724
    656     abstract public function upper(): static;
     725    /**
     726     * @return static
     727     */
     728    abstract public function upper(): self;
    657729
    658730    /**
     
    661733    abstract public function width(bool $ignoreAnsiDecoration = true): int;
    662734
    663     public function wordwrap(int $width = 75, string $break = "\n", bool $cut = false): static
     735    /**
     736     * @return static
     737     */
     738    public function wordwrap(int $width = 75, string $break = "\n", bool $cut = false): self
    664739    {
    665740        $lines = '' !== $break ? $this->split($break) : [clone $this];
  • speechkit/trunk/vendor/symfony/string/AbstractUnicodeString.php

    r3393083 r3420880  
    4141    private const FOLD_TO = ['i̇', 'μ', 's', 'ι', 'σ', 'β', 'θ', 'φ', 'π', 'κ', 'ρ', 'ε', 'ṡ', 'ι', 'ss', 'ʼn', 'ǰ', 'ΐ', 'ΰ', 'եւ', 'ẖ', 'ẗ', 'ẘ', 'ẙ', 'aʾ', 'ss', 'ὐ', 'ὒ', 'ὔ', 'ὖ', 'ἀι', 'ἁι', 'ἂι', 'ἃι', 'ἄι', 'ἅι', 'ἆι', 'ἇι', 'ἀι', 'ἁι', 'ἂι', 'ἃι', 'ἄι', 'ἅι', 'ἆι', 'ἇι', 'ἠι', 'ἡι', 'ἢι', 'ἣι', 'ἤι', 'ἥι', 'ἦι', 'ἧι', 'ἠι', 'ἡι', 'ἢι', 'ἣι', 'ἤι', 'ἥι', 'ἦι', 'ἧι', 'ὠι', 'ὡι', 'ὢι', 'ὣι', 'ὤι', 'ὥι', 'ὦι', 'ὧι', 'ὠι', 'ὡι', 'ὢι', 'ὣι', 'ὤι', 'ὥι', 'ὦι', 'ὧι', 'ὰι', 'αι', 'άι', 'ᾶ', 'ᾶι', 'αι', 'ὴι', 'ηι', 'ήι', 'ῆ', 'ῆι', 'ηι', 'ῒ', 'ῖ', 'ῗ', 'ῢ', 'ῤ', 'ῦ', 'ῧ', 'ὼι', 'ωι', 'ώι', 'ῶ', 'ῶι', 'ωι', 'ff', 'fi', 'fl', 'ffi', 'ffl', 'st', 'st', 'մն', 'մե', 'մի', 'վն', 'մխ'];
    4242
     43    // the subset of upper case mappings that map one code point to many code points
     44    private const UPPER_FROM = ['ß', 'ff', 'fi', 'fl', 'ffi', 'ffl', 'ſt', 'st', 'և', 'ﬓ', 'ﬔ', 'ﬕ', 'ﬖ', 'ﬗ', 'ʼn', 'ΐ', 'ΰ', 'ǰ', 'ẖ', 'ẗ', 'ẘ', 'ẙ', 'ẚ', 'ὐ', 'ὒ', 'ὔ', 'ὖ', 'ᾶ', 'ῆ', 'ῒ', 'ΐ', 'ῖ', 'ῗ', 'ῢ', 'ΰ', 'ῤ', 'ῦ', 'ῧ', 'ῶ'];
     45    private const UPPER_TO = ['SS', 'FF', 'FI', 'FL', 'FFI', 'FFL', 'ST', 'ST', 'ԵՒ', 'ՄՆ', 'ՄԵ', 'ՄԻ', 'ՎՆ', 'ՄԽ', 'ʼN', 'Ϊ́', 'Ϋ́', 'J̌', 'H̱', 'T̈', 'W̊', 'Y̊', 'Aʾ', 'Υ̓', 'Υ̓̀', 'Υ̓́', 'Υ̓͂', 'Α͂', 'Η͂', 'Ϊ̀', 'Ϊ́', 'Ι͂', 'Ϊ͂', 'Ϋ̀', 'Ϋ́', 'Ρ̓', 'Υ͂', 'Ϋ͂', 'Ω͂'];
     46
    4347    // the subset of https://github.com/unicode-org/cldr/blob/master/common/transforms/Latin-ASCII.xml that is not in NFKD
    4448    private const TRANSLIT_FROM = ['Æ', 'Ð', 'Ø', 'Þ', 'ß', 'æ', 'ð', 'ø', 'þ', 'Đ', 'đ', 'Ħ', 'ħ', 'ı', 'ĸ', 'Ŀ', 'ŀ', 'Ł', 'ł', 'ʼn', 'Ŋ', 'ŋ', 'Œ', 'œ', 'Ŧ', 'ŧ', 'ƀ', 'Ɓ', 'Ƃ', 'ƃ', 'Ƈ', 'ƈ', 'Ɖ', 'Ɗ', 'Ƌ', 'ƌ', 'Ɛ', 'Ƒ', 'ƒ', 'Ɠ', 'ƕ', 'Ɩ', 'Ɨ', 'Ƙ', 'ƙ', 'ƚ', 'Ɲ', 'ƞ', 'Ƣ', 'ƣ', 'Ƥ', 'ƥ', 'ƫ', 'Ƭ', 'ƭ', 'Ʈ', 'Ʋ', 'Ƴ', 'ƴ', 'Ƶ', 'ƶ', 'DŽ', 'Dž', 'dž', 'Ǥ', 'ǥ', 'ȡ', 'Ȥ', 'ȥ', 'ȴ', 'ȵ', 'ȶ', 'ȷ', 'ȸ', 'ȹ', 'Ⱥ', 'Ȼ', 'ȼ', 'Ƚ', 'Ⱦ', 'ȿ', 'ɀ', 'Ƀ', 'Ʉ', 'Ɇ', 'ɇ', 'Ɉ', 'ɉ', 'Ɍ', 'ɍ', 'Ɏ', 'ɏ', 'ɓ', 'ɕ', 'ɖ', 'ɗ', 'ɛ', 'ɟ', 'ɠ', 'ɡ', 'ɢ', 'ɦ', 'ɧ', 'ɨ', 'ɪ', 'ɫ', 'ɬ', 'ɭ', 'ɱ', 'ɲ', 'ɳ', 'ɴ', 'ɶ', 'ɼ', 'ɽ', 'ɾ', 'ʀ', 'ʂ', 'ʈ', 'ʉ', 'ʋ', 'ʏ', 'ʐ', 'ʑ', 'ʙ', 'ʛ', 'ʜ', 'ʝ', 'ʟ', 'ʠ', 'ʣ', 'ʥ', 'ʦ', 'ʪ', 'ʫ', 'ᴀ', 'ᴁ', 'ᴃ', 'ᴄ', 'ᴅ', 'ᴆ', 'ᴇ', 'ᴊ', 'ᴋ', 'ᴌ', 'ᴍ', 'ᴏ', 'ᴘ', 'ᴛ', 'ᴜ', 'ᴠ', 'ᴡ', 'ᴢ', 'ᵫ', 'ᵬ', 'ᵭ', 'ᵮ', 'ᵯ', 'ᵰ', 'ᵱ', 'ᵲ', 'ᵳ', 'ᵴ', 'ᵵ', 'ᵶ', 'ᵺ', 'ᵻ', 'ᵽ', 'ᵾ', 'ᶀ', 'ᶁ', 'ᶂ', 'ᶃ', 'ᶄ', 'ᶅ', 'ᶆ', 'ᶇ', 'ᶈ', 'ᶉ', 'ᶊ', 'ᶌ', 'ᶍ', 'ᶎ', 'ᶏ', 'ᶑ', 'ᶒ', 'ᶓ', 'ᶖ', 'ᶙ', 'ẚ', 'ẜ', 'ẝ', 'ẞ', 'Ỻ', 'ỻ', 'Ỽ', 'ỽ', 'Ỿ', 'ỿ', '©', '®', '₠', '₢', '₣', '₤', '₧', '₺', '₹', 'ℌ', '℞', '㎧', '㎮', '㏆', '㏗', '㏞', '㏟', '¼', '½', '¾', '⅓', '⅔', '⅕', '⅖', '⅗', '⅘', '⅙', '⅚', '⅛', '⅜', '⅝', '⅞', '⅟', '〇', '‘', '’', '‚', '‛', '“', '”', '„', '‟', '′', '″', '〝', '〞', '«', '»', '‹', '›', '‐', '‑', '‒', '–', '—', '―', '︱', '︲', '﹘', '‖', '⁄', '⁅', '⁆', '⁎', '、', '。', '〈', '〉', '《', '》', '〔', '〕', '〘', '〙', '〚', '〛', '︑', '︒', '︹', '︺', '︽', '︾', '︿', '﹀', '﹑', '﹝', '﹞', '⦅', '⦆', '。', '、', '×', '÷', '−', '∕', '∖', '∣', '∥', '≪', '≫', '⦅', '⦆'];
    4549    private const TRANSLIT_TO = ['AE', 'D', 'O', 'TH', 'ss', 'ae', 'd', 'o', 'th', 'D', 'd', 'H', 'h', 'i', 'q', 'L', 'l', 'L', 'l', '\'n', 'N', 'n', 'OE', 'oe', 'T', 't', 'b', 'B', 'B', 'b', 'C', 'c', 'D', 'D', 'D', 'd', 'E', 'F', 'f', 'G', 'hv', 'I', 'I', 'K', 'k', 'l', 'N', 'n', 'OI', 'oi', 'P', 'p', 't', 'T', 't', 'T', 'V', 'Y', 'y', 'Z', 'z', 'DZ', 'Dz', 'dz', 'G', 'g', 'd', 'Z', 'z', 'l', 'n', 't', 'j', 'db', 'qp', 'A', 'C', 'c', 'L', 'T', 's', 'z', 'B', 'U', 'E', 'e', 'J', 'j', 'R', 'r', 'Y', 'y', 'b', 'c', 'd', 'd', 'e', 'j', 'g', 'g', 'G', 'h', 'h', 'i', 'I', 'l', 'l', 'l', 'm', 'n', 'n', 'N', 'OE', 'r', 'r', 'r', 'R', 's', 't', 'u', 'v', 'Y', 'z', 'z', 'B', 'G', 'H', 'j', 'L', 'q', 'dz', 'dz', 'ts', 'ls', 'lz', 'A', 'AE', 'B', 'C', 'D', 'D', 'E', 'J', 'K', 'L', 'M', 'O', 'P', 'T', 'U', 'V', 'W', 'Z', 'ue', 'b', 'd', 'f', 'm', 'n', 'p', 'r', 'r', 's', 't', 'z', 'th', 'I', 'p', 'U', 'b', 'd', 'f', 'g', 'k', 'l', 'm', 'n', 'p', 'r', 's', 'v', 'x', 'z', 'a', 'd', 'e', 'e', 'i', 'u', 'a', 's', 's', 'SS', 'LL', 'll', 'V', 'v', 'Y', 'y', '(C)', '(R)', 'CE', 'Cr', 'Fr.', 'L.', 'Pts', 'TL', 'Rs', 'x', 'Rx', 'm/s', 'rad/s', 'C/kg', 'pH', 'V/m', 'A/m', ' 1/4', ' 1/2', ' 3/4', ' 1/3', ' 2/3', ' 1/5', ' 2/5', ' 3/5', ' 4/5', ' 1/6', ' 5/6', ' 1/8', ' 3/8', ' 5/8', ' 7/8', ' 1/', '0', '\'', '\'', ',', '\'', '"', '"', ',,', '"', '\'', '"', '"', '"', '<<', '>>', '<', '>', '-', '-', '-', '-', '-', '-', '-', '-', '-', '||', '/', '[', ']', '*', ',', '.', '<', '>', '<<', '>>', '[', ']', '[', ']', '[', ']', ',', '.', '[', ']', '<<', '>>', '<', '>', ',', '[', ']', '((', '))', '.', ',', '*', '/', '-', '/', '\\', '|', '||', '<<', '>>', '((', '))'];
    4650
    47     private static array $transliterators = [];
    48     private static array $tableZero;
    49     private static array $tableWide;
    50 
    51     public static function fromCodePoints(int ...$codes): static
     51    private static $transliterators = [];
     52    private static $tableZero;
     53    private static $tableWide;
     54
     55    /**
     56     * @return static
     57     */
     58    public static function fromCodePoints(int ...$codes): self
    5259    {
    5360        $string = '';
     
    118125                    $s = str_replace(["a\u{0308}", "o\u{0308}", "u\u{0308}", "A\u{0308}", "O\u{0308}", "U\u{0308}"], ['ae', 'oe', 'ue', 'AE', 'OE', 'UE'], $s);
    119126                } elseif (\function_exists('transliterator_transliterate')) {
    120                     if (null === $transliterator = self::$transliterators[$rule] ??= \Transliterator::create($rule)) {
     127                    if (null === $transliterator = self::$transliterators[$rule] ?? self::$transliterators[$rule] = \Transliterator::create($rule)) {
    121128                        if ('any-latin/bgn' === $rule) {
    122129                            $rule = 'any-latin';
    123                             $transliterator = self::$transliterators[$rule] ??= \Transliterator::create($rule);
     130                            $transliterator = self::$transliterators[$rule] ?? self::$transliterators[$rule] = \Transliterator::create($rule);
    124131                        }
    125132
    126133                        if (null === $transliterator) {
    127                             throw new InvalidArgumentException(\sprintf('Unknown transliteration rule "%s".', $rule));
     134                            throw new InvalidArgumentException(sprintf('Unknown transliteration rule "%s".', $rule));
    128135                        }
    129136
     
    136143                $s = preg_replace('/[^\x00-\x7F]/u', '?', $s);
    137144            } else {
    138                 $previousLocale = setlocale(\LC_CTYPE, 0);
    139                 try {
    140                     setlocale(\LC_CTYPE, 'C');
    141                     $s = @preg_replace_callback('/[^\x00-\x7F]/u', static function ($c) {
    142                         $c = (string) iconv('UTF-8', 'ASCII//TRANSLIT', $c[0]);
    143 
    144                         if ('' === $c && '' === iconv('UTF-8', 'ASCII//TRANSLIT', '²')) {
    145                             throw new \LogicException(\sprintf('"%s" requires a translit-able iconv implementation, try installing "gnu-libiconv" if you\'re using Alpine Linux.', static::class));
    146                         }
    147 
    148                         return 1 < \strlen($c) ? ltrim($c, '\'`"^~') : ('' !== $c ? $c : '?');
    149                     }, $s);
    150                 } finally {
    151                     setlocale(\LC_CTYPE, $previousLocale);
    152                 }
     145                $s = @preg_replace_callback('/[^\x00-\x7F]/u', static function ($c) {
     146                    $c = (string) iconv('UTF-8', 'ASCII//TRANSLIT', $c[0]);
     147
     148                    if ('' === $c && '' === iconv('UTF-8', 'ASCII//TRANSLIT', '²')) {
     149                        throw new \LogicException(sprintf('"%s" requires a translit-able iconv implementation, try installing "gnu-libiconv" if you\'re using Alpine Linux.', static::class));
     150                    }
     151
     152                    return 1 < \strlen($c) ? ltrim($c, '\'`"^~') : ('' !== $c ? $c : '?');
     153                }, $s);
    153154            }
    154155        }
     
    159160    }
    160161
    161     public function camel(): static
    162     {
    163         $str = clone $this;
    164         $str->string = str_replace(' ', '', preg_replace_callback('/\b.(?!\p{Lu})/u', static function ($m) {
    165             static $i = 0;
    166 
     162    public function camel(): parent
     163    {
     164        $str = clone $this;
     165        $str->string = str_replace(' ', '', preg_replace_callback('/\b.(?!\p{Lu})/u', static function ($m) use (&$i) {
    167166            return 1 === ++$i ? ('İ' === $m[0] ? 'i̇' : mb_strtolower($m[0], 'UTF-8')) : mb_convert_case($m[0], \MB_CASE_TITLE, 'UTF-8');
    168167        }, preg_replace('/[^\pL0-9]++/u', ' ', $this->string)));
     
    191190    }
    192191
    193     public function folded(bool $compat = true): static
    194     {
    195         $str = clone $this;
    196 
    197         if (!$compat || !\defined('Normalizer::NFKC_CF')) {
     192    public function folded(bool $compat = true): parent
     193    {
     194        $str = clone $this;
     195
     196        if (!$compat || \PHP_VERSION_ID < 70300 || !\defined('Normalizer::NFKC_CF')) {
    198197            $str->string = normalizer_normalize($str->string, $compat ? \Normalizer::NFKC : \Normalizer::NFC);
    199198            $str->string = mb_strtolower(str_replace(self::FOLD_FROM, self::FOLD_TO, $str->string), 'UTF-8');
     
    205204    }
    206205
    207     public function join(array $strings, ?string $lastGlue = null): static
     206    public function join(array $strings, ?string $lastGlue = null): parent
    208207    {
    209208        $str = clone $this;
     
    219218    }
    220219
    221     public function lower(): static
     220    public function lower(): parent
    222221    {
    223222        $str = clone $this;
     
    225224
    226225        return $str;
    227     }
    228 
    229     /**
    230      * @param string $locale In the format language_region (e.g. tr_TR)
    231      */
    232     public function localeLower(string $locale): static
    233     {
    234         if (null !== $transliterator = $this->getLocaleTransliterator($locale, 'Lower')) {
    235             $str = clone $this;
    236             $str->string = $transliterator->transliterate($str->string);
    237 
    238             return $str;
    239         }
    240 
    241         return $this->lower();
    242226    }
    243227
     
    250234        }
    251235
    252         set_error_handler(static fn ($t, $m) => throw new InvalidArgumentException($m));
     236        set_error_handler(static function ($t, $m) { throw new InvalidArgumentException($m); });
    253237
    254238        try {
    255239            if (false === $match($regexp.'u', $this->string, $matches, $flags | \PREG_UNMATCHED_AS_NULL, $offset)) {
    256                 throw new RuntimeException('Matching failed with error: '.preg_last_error_msg());
     240                $lastError = preg_last_error();
     241
     242                foreach (get_defined_constants(true)['pcre'] as $k => $v) {
     243                    if ($lastError === $v && '_ERROR' === substr($k, -6)) {
     244                        throw new RuntimeException('Matching failed with '.$k.'.');
     245                    }
     246                }
     247
     248                throw new RuntimeException('Matching failed with unknown error code.');
    257249            }
    258250        } finally {
     
    263255    }
    264256
    265     public function normalize(int $form = self::NFC): static
     257    /**
     258     * @return static
     259     */
     260    public function normalize(int $form = self::NFC): self
    266261    {
    267262        if (!\in_array($form, [self::NFC, self::NFD, self::NFKC, self::NFKD])) {
     
    275270    }
    276271
    277     public function padBoth(int $length, string $padStr = ' '): static
     272    public function padBoth(int $length, string $padStr = ' '): parent
    278273    {
    279274        if ('' === $padStr || !preg_match('//u', $padStr)) {
     
    287282    }
    288283
    289     public function padEnd(int $length, string $padStr = ' '): static
     284    public function padEnd(int $length, string $padStr = ' '): parent
    290285    {
    291286        if ('' === $padStr || !preg_match('//u', $padStr)) {
     
    299294    }
    300295
    301     public function padStart(int $length, string $padStr = ' '): static
     296    public function padStart(int $length, string $padStr = ' '): parent
    302297    {
    303298        if ('' === $padStr || !preg_match('//u', $padStr)) {
     
    311306    }
    312307
    313     public function replaceMatches(string $fromRegexp, string|callable $to): static
     308    public function replaceMatches(string $fromRegexp, $to): parent
    314309    {
    315310        if ($this->ignoreCase) {
     
    318313
    319314        if (\is_array($to) || $to instanceof \Closure) {
     315            if (!\is_callable($to)) {
     316                throw new \TypeError(sprintf('Argument 2 passed to "%s::replaceMatches()" must be callable, array given.', static::class));
     317            }
     318
    320319            $replace = 'preg_replace_callback';
    321320            $to = static function (array $m) use ($to): string {
     
    334333        }
    335334
    336         set_error_handler(static fn ($t, $m) => throw new InvalidArgumentException($m));
     335        set_error_handler(static function ($t, $m) { throw new InvalidArgumentException($m); });
    337336
    338337        try {
     
    341340
    342341                foreach (get_defined_constants(true)['pcre'] as $k => $v) {
    343                     if ($lastError === $v && str_ends_with($k, '_ERROR')) {
     342                    if ($lastError === $v && '_ERROR' === substr($k, -6)) {
    344343                        throw new RuntimeException('Matching failed with '.$k.'.');
    345344                    }
     
    358357    }
    359358
    360     public function reverse(): static
     359    public function reverse(): parent
    361360    {
    362361        $str = clone $this;
     
    366365    }
    367366
    368     public function snake(): static
     367    public function snake(): parent
    369368    {
    370369        $str = $this->camel();
     
    374373    }
    375374
    376     public function title(bool $allWords = false): static
     375    public function title(bool $allWords = false): parent
    377376    {
    378377        $str = clone $this;
     
    380379        $limit = $allWords ? -1 : 1;
    381380
    382         $str->string = preg_replace_callback('/\b./u', static fn (array $m): string => mb_convert_case($m[0], \MB_CASE_TITLE, 'UTF-8'), $str->string, $limit);
    383 
    384         return $str;
    385     }
    386 
    387     /**
    388      * @param string $locale In the format language_region (e.g. tr_TR)
    389      */
    390     public function localeTitle(string $locale): static
    391     {
    392         if (null !== $transliterator = $this->getLocaleTransliterator($locale, 'Title')) {
    393             $str = clone $this;
    394             $str->string = $transliterator->transliterate($str->string);
    395 
    396             return $str;
    397         }
    398 
    399         return $this->title();
    400     }
    401 
    402     public function trim(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): static
     381        $str->string = preg_replace_callback('/\b./u', static function (array $m): string {
     382            return mb_convert_case($m[0], \MB_CASE_TITLE, 'UTF-8');
     383        }, $str->string, $limit);
     384
     385        return $str;
     386    }
     387
     388    public function trim(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): parent
    403389    {
    404390        if (" \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}" !== $chars && !preg_match('//u', $chars)) {
     
    413399    }
    414400
    415     public function trimEnd(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): static
     401    public function trimEnd(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): parent
    416402    {
    417403        if (" \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}" !== $chars && !preg_match('//u', $chars)) {
     
    426412    }
    427413
    428     public function trimPrefix($prefix): static
     414    public function trimPrefix($prefix): parent
    429415    {
    430416        if (!$this->ignoreCase) {
     
    446432    }
    447433
    448     public function trimStart(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): static
     434    public function trimStart(string $chars = " \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}"): parent
    449435    {
    450436        if (" \t\n\r\0\x0B\x0C\u{A0}\u{FEFF}" !== $chars && !preg_match('//u', $chars)) {
     
    459445    }
    460446
    461     public function trimSuffix($suffix): static
     447    public function trimSuffix($suffix): parent
    462448    {
    463449        if (!$this->ignoreCase) {
     
    479465    }
    480466
    481     public function upper(): static
     467    public function upper(): parent
    482468    {
    483469        $str = clone $this;
    484470        $str->string = mb_strtoupper($str->string, 'UTF-8');
    485471
    486         return $str;
    487     }
    488 
    489     /**
    490      * @param string $locale In the format language_region (e.g. tr_TR)
    491      */
    492     public function localeUpper(string $locale): static
    493     {
    494         if (null !== $transliterator = $this->getLocaleTransliterator($locale, 'Upper')) {
    495             $str = clone $this;
    496             $str->string = $transliterator->transliterate($str->string);
    497 
    498             return $str;
    499         }
    500 
    501         return $this->upper();
     472        if (\PHP_VERSION_ID < 70300) {
     473            $str->string = str_replace(self::UPPER_FROM, self::UPPER_TO, $str->string);
     474        }
     475
     476        return $str;
    502477    }
    503478
     
    507482        $s = str_replace(["\x00", "\x05", "\x07"], '', $this->string);
    508483
    509         if (str_contains($s, "\r")) {
     484        if (false !== strpos($s, "\r")) {
    510485            $s = str_replace(["\r\n", "\r"], "\n", $s);
    511486        }
     
    534509    }
    535510
    536     private function pad(int $len, self $pad, int $type): static
     511    /**
     512     * @return static
     513     */
     514    private function pad(int $len, self $pad, int $type): parent
    537515    {
    538516        $sLen = $this->length();
     
    598576            }
    599577
    600             self::$tableZero ??= require __DIR__.'/Resources/data/wcswidth_table_zero.php';
     578            if (null === self::$tableZero) {
     579                self::$tableZero = require __DIR__.'/Resources/data/wcswidth_table_zero.php';
     580            }
    601581
    602582            if ($codePoint >= self::$tableZero[0][0] && $codePoint <= self::$tableZero[$ubound = \count(self::$tableZero) - 1][1]) {
     
    615595            }
    616596
    617             self::$tableWide ??= require __DIR__.'/Resources/data/wcswidth_table_wide.php';
     597            if (null === self::$tableWide) {
     598                self::$tableWide = require __DIR__.'/Resources/data/wcswidth_table_wide.php';
     599            }
    618600
    619601            if ($codePoint >= self::$tableWide[0][0] && $codePoint <= self::$tableWide[$ubound = \count(self::$tableWide) - 1][1]) {
     
    639621        return $width;
    640622    }
    641 
    642     private function getLocaleTransliterator(string $locale, string $id): ?\Transliterator
    643     {
    644         $rule = $locale.'-'.$id;
    645         if (\array_key_exists($rule, self::$transliterators)) {
    646             return self::$transliterators[$rule];
    647         }
    648 
    649         if (null !== $transliterator = self::$transliterators[$rule] = \Transliterator::create($rule)) {
    650             return $transliterator;
    651         }
    652 
    653         // Try to find a parent locale (nl_BE -> nl)
    654         if (false === $i = strpos($locale, '_')) {
    655             return null;
    656         }
    657 
    658         $parentRule = substr_replace($locale, '-'.$id, $i);
    659 
    660         // Parent locale was already cached, return and store as current locale
    661         if (\array_key_exists($parentRule, self::$transliterators)) {
    662             return self::$transliterators[$rule] = self::$transliterators[$parentRule];
    663         }
    664 
    665         // Create transliterator based on parent locale and cache the result on both initial and parent locale values
    666         $transliterator = \Transliterator::create($parentRule);
    667 
    668         return self::$transliterators[$rule] = self::$transliterators[$parentRule] = $transliterator;
    669     }
    670623}
  • speechkit/trunk/vendor/symfony/string/ByteString.php

    r3393083 r3420880  
    1212namespace Symfony\Component\String;
    1313
    14 use Random\Randomizer;
    1514use Symfony\Component\String\Exception\ExceptionInterface;
    1615use Symfony\Component\String\Exception\InvalidArgumentException;
     
    4746    {
    4847        if ($length <= 0) {
    49             throw new InvalidArgumentException(\sprintf('A strictly positive length is expected, "%d" given.', $length));
    50         }
    51 
    52         $alphabet ??= self::ALPHABET_ALPHANUMERIC;
     48            throw new InvalidArgumentException(sprintf('A strictly positive length is expected, "%d" given.', $length));
     49        }
     50
     51        $alphabet = $alphabet ?? self::ALPHABET_ALPHANUMERIC;
    5352        $alphabetSize = \strlen($alphabet);
    5453        $bits = (int) ceil(log($alphabetSize, 2.0));
    5554        if ($bits <= 0 || $bits > 56) {
    5655            throw new InvalidArgumentException('The length of the alphabet must in the [2^1, 2^56] range.');
    57         }
    58 
    59         if (\PHP_VERSION_ID >= 80300) {
    60             return new static((new Randomizer())->getBytesFromString($alphabet, $length));
    6156        }
    6257
     
    9893    }
    9994
    100     public function append(string ...$suffix): static
     95    public function append(string ...$suffix): parent
    10196    {
    10297        $str = clone $this;
     
    106101    }
    107102
    108     public function camel(): static
     103    public function camel(): parent
    109104    {
    110105        $str = clone $this;
     
    138133    }
    139134
    140     public function endsWith(string|iterable|AbstractString $suffix): bool
    141     {
    142         if ($suffix instanceof AbstractString) {
     135    public function endsWith($suffix): bool
     136    {
     137        if ($suffix instanceof parent) {
    143138            $suffix = $suffix->string;
    144         } elseif (!\is_string($suffix)) {
     139        } elseif (\is_array($suffix) || $suffix instanceof \Traversable) {
    145140            return parent::endsWith($suffix);
     141        } else {
     142            $suffix = (string) $suffix;
    146143        }
    147144
     
    149146    }
    150147
    151     public function equalsTo(string|iterable|AbstractString $string): bool
    152     {
    153         if ($string instanceof AbstractString) {
     148    public function equalsTo($string): bool
     149    {
     150        if ($string instanceof parent) {
    154151            $string = $string->string;
    155         } elseif (!\is_string($string)) {
     152        } elseif (\is_array($string) || $string instanceof \Traversable) {
    156153            return parent::equalsTo($string);
     154        } else {
     155            $string = (string) $string;
    157156        }
    158157
     
    164163    }
    165164
    166     public function folded(): static
     165    public function folded(): parent
    167166    {
    168167        $str = clone $this;
     
    172171    }
    173172
    174     public function indexOf(string|iterable|AbstractString $needle, int $offset = 0): ?int
    175     {
    176         if ($needle instanceof AbstractString) {
     173    public function indexOf($needle, int $offset = 0): ?int
     174    {
     175        if ($needle instanceof parent) {
    177176            $needle = $needle->string;
    178         } elseif (!\is_string($needle)) {
     177        } elseif (\is_array($needle) || $needle instanceof \Traversable) {
    179178            return parent::indexOf($needle, $offset);
     179        } else {
     180            $needle = (string) $needle;
    180181        }
    181182
     
    189190    }
    190191
    191     public function indexOfLast(string|iterable|AbstractString $needle, int $offset = 0): ?int
    192     {
    193         if ($needle instanceof AbstractString) {
     192    public function indexOfLast($needle, int $offset = 0): ?int
     193    {
     194        if ($needle instanceof parent) {
    194195            $needle = $needle->string;
    195         } elseif (!\is_string($needle)) {
     196        } elseif (\is_array($needle) || $needle instanceof \Traversable) {
    196197            return parent::indexOfLast($needle, $offset);
     198        } else {
     199            $needle = (string) $needle;
    197200        }
    198201
     
    211214    }
    212215
    213     public function join(array $strings, ?string $lastGlue = null): static
     216    public function join(array $strings, ?string $lastGlue = null): parent
    214217    {
    215218        $str = clone $this;
     
    226229    }
    227230
    228     public function lower(): static
     231    public function lower(): parent
    229232    {
    230233        $str = clone $this;
     
    242245        }
    243246
    244         set_error_handler(static fn ($t, $m) => throw new InvalidArgumentException($m));
     247        set_error_handler(static function ($t, $m) { throw new InvalidArgumentException($m); });
    245248
    246249        try {
    247250            if (false === $match($regexp, $this->string, $matches, $flags | \PREG_UNMATCHED_AS_NULL, $offset)) {
    248                 throw new RuntimeException('Matching failed with error: '.preg_last_error_msg());
    249             }
    250         } finally {
    251             restore_error_handler();
    252         }
    253 
    254         return $matches;
    255     }
    256 
    257     public function padBoth(int $length, string $padStr = ' '): static
    258     {
    259         $str = clone $this;
    260         $str->string = str_pad($this->string, $length, $padStr, \STR_PAD_BOTH);
    261 
    262         return $str;
    263     }
    264 
    265     public function padEnd(int $length, string $padStr = ' '): static
    266     {
    267         $str = clone $this;
    268         $str->string = str_pad($this->string, $length, $padStr, \STR_PAD_RIGHT);
    269 
    270         return $str;
    271     }
    272 
    273     public function padStart(int $length, string $padStr = ' '): static
    274     {
    275         $str = clone $this;
    276         $str->string = str_pad($this->string, $length, $padStr, \STR_PAD_LEFT);
    277 
    278         return $str;
    279     }
    280 
    281     public function prepend(string ...$prefix): static
    282     {
    283         $str = clone $this;
    284         $str->string = (1 >= \count($prefix) ? ($prefix[0] ?? '') : implode('', $prefix)).$str->string;
    285 
    286         return $str;
    287     }
    288 
    289     public function replace(string $from, string $to): static
    290     {
    291         $str = clone $this;
    292 
    293         if ('' !== $from) {
    294             $str->string = $this->ignoreCase ? str_ireplace($from, $to, $this->string) : str_replace($from, $to, $this->string);
    295         }
    296 
    297         return $str;
    298     }
    299 
    300     public function replaceMatches(string $fromRegexp, string|callable $to): static
    301     {
    302         if ($this->ignoreCase) {
    303             $fromRegexp .= 'i';
    304         }
    305 
    306         $replace = \is_array($to) || $to instanceof \Closure ? 'preg_replace_callback' : 'preg_replace';
    307 
    308         set_error_handler(static fn ($t, $m) => throw new InvalidArgumentException($m));
    309 
    310         try {
    311             if (null === $string = $replace($fromRegexp, $to, $this->string)) {
    312251                $lastError = preg_last_error();
    313252
    314253                foreach (get_defined_constants(true)['pcre'] as $k => $v) {
    315                     if ($lastError === $v && str_ends_with($k, '_ERROR')) {
     254                    if ($lastError === $v && '_ERROR' === substr($k, -6)) {
    316255                        throw new RuntimeException('Matching failed with '.$k.'.');
    317256                    }
     
    324263        }
    325264
     265        return $matches;
     266    }
     267
     268    public function padBoth(int $length, string $padStr = ' '): parent
     269    {
     270        $str = clone $this;
     271        $str->string = str_pad($this->string, $length, $padStr, \STR_PAD_BOTH);
     272
     273        return $str;
     274    }
     275
     276    public function padEnd(int $length, string $padStr = ' '): parent
     277    {
     278        $str = clone $this;
     279        $str->string = str_pad($this->string, $length, $padStr, \STR_PAD_RIGHT);
     280
     281        return $str;
     282    }
     283
     284    public function padStart(int $length, string $padStr = ' '): parent
     285    {
     286        $str = clone $this;
     287        $str->string = str_pad($this->string, $length, $padStr, \STR_PAD_LEFT);
     288
     289        return $str;
     290    }
     291
     292    public function prepend(string ...$prefix): parent
     293    {
     294        $str = clone $this;
     295        $str->string = (1 >= \count($prefix) ? ($prefix[0] ?? '') : implode('', $prefix)).$str->string;
     296
     297        return $str;
     298    }
     299
     300    public function replace(string $from, string $to): parent
     301    {
     302        $str = clone $this;
     303
     304        if ('' !== $from) {
     305            $str->string = $this->ignoreCase ? str_ireplace($from, $to, $this->string) : str_replace($from, $to, $this->string);
     306        }
     307
     308        return $str;
     309    }
     310
     311    public function replaceMatches(string $fromRegexp, $to): parent
     312    {
     313        if ($this->ignoreCase) {
     314            $fromRegexp .= 'i';
     315        }
     316
     317        if (\is_array($to)) {
     318            if (!\is_callable($to)) {
     319                throw new \TypeError(sprintf('Argument 2 passed to "%s::replaceMatches()" must be callable, array given.', static::class));
     320            }
     321
     322            $replace = 'preg_replace_callback';
     323        } else {
     324            $replace = $to instanceof \Closure ? 'preg_replace_callback' : 'preg_replace';
     325        }
     326
     327        set_error_handler(static function ($t, $m) { throw new InvalidArgumentException($m); });
     328
     329        try {
     330            if (null === $string = $replace($fromRegexp, $to, $this->string)) {
     331                $lastError = preg_last_error();
     332
     333                foreach (get_defined_constants(true)['pcre'] as $k => $v) {
     334                    if ($lastError === $v && '_ERROR' === substr($k, -6)) {
     335                        throw new RuntimeException('Matching failed with '.$k.'.');
     336                    }
     337                }
     338
     339                throw new RuntimeException('Matching failed with unknown error code.');
     340            }
     341        } finally {
     342            restore_error_handler();
     343        }
     344
    326345        $str = clone $this;
    327346        $str->string = $string;
     
    330349    }
    331350
    332     public function reverse(): static
     351    public function reverse(): parent
    333352    {
    334353        $str = clone $this;
     
    338357    }
    339358
    340     public function slice(int $start = 0, ?int $length = null): static
    341     {
    342         $str = clone $this;
    343         $str->string = substr($this->string, $start, $length ?? \PHP_INT_MAX);
    344 
    345         return $str;
    346     }
    347 
    348     public function snake(): static
     359    public function slice(int $start = 0, ?int $length = null): parent
     360    {
     361        $str = clone $this;
     362        $str->string = (string) substr($this->string, $start, $length ?? \PHP_INT_MAX);
     363
     364        return $str;
     365    }
     366
     367    public function snake(): parent
    349368    {
    350369        $str = $this->camel();
     
    354373    }
    355374
    356     public function splice(string $replacement, int $start = 0, ?int $length = null): static
     375    public function splice(string $replacement, int $start = 0, ?int $length = null): parent
    357376    {
    358377        $str = clone $this;
     
    364383    public function split(string $delimiter, ?int $limit = null, ?int $flags = null): array
    365384    {
    366         if (1 > $limit ??= \PHP_INT_MAX) {
     385        if (1 > $limit = $limit ?? \PHP_INT_MAX) {
    367386            throw new InvalidArgumentException('Split limit must be a positive integer.');
    368387        }
     
    389408    }
    390409
    391     public function startsWith(string|iterable|AbstractString $prefix): bool
    392     {
    393         if ($prefix instanceof AbstractString) {
     410    public function startsWith($prefix): bool
     411    {
     412        if ($prefix instanceof parent) {
    394413            $prefix = $prefix->string;
    395414        } elseif (!\is_string($prefix)) {
     
    400419    }
    401420
    402     public function title(bool $allWords = false): static
     421    public function title(bool $allWords = false): parent
    403422    {
    404423        $str = clone $this;
     
    423442        }
    424443
    425         set_error_handler(static fn ($t, $m) => throw new InvalidArgumentException($m));
     444        set_error_handler(static function ($t, $m) { throw new InvalidArgumentException($m); });
    426445
    427446        try {
     
    442461
    443462        if (!$validEncoding) {
    444             throw new InvalidArgumentException(\sprintf('Invalid "%s" string.', $fromEncoding ?? 'Windows-1252'));
     463            throw new InvalidArgumentException(sprintf('Invalid "%s" string.', $fromEncoding ?? 'Windows-1252'));
    445464        }
    446465
     
    450469    }
    451470
    452     public function trim(string $chars = " \t\n\r\0\x0B\x0C"): static
     471    public function trim(string $chars = " \t\n\r\0\x0B\x0C"): parent
    453472    {
    454473        $str = clone $this;
     
    458477    }
    459478
    460     public function trimEnd(string $chars = " \t\n\r\0\x0B\x0C"): static
     479    public function trimEnd(string $chars = " \t\n\r\0\x0B\x0C"): parent
    461480    {
    462481        $str = clone $this;
     
    466485    }
    467486
    468     public function trimStart(string $chars = " \t\n\r\0\x0B\x0C"): static
     487    public function trimStart(string $chars = " \t\n\r\0\x0B\x0C"): parent
    469488    {
    470489        $str = clone $this;
     
    474493    }
    475494
    476     public function upper(): static
     495    public function upper(): parent
    477496    {
    478497        $str = clone $this;
  • speechkit/trunk/vendor/symfony/string/CHANGELOG.md

    r3393083 r3420880  
    11CHANGELOG
    22=========
    3 
    4 7.3
    5 ---
    6 
    7  * Add the `AbstractString::pascal()` method
    8 
    9 7.2
    10 ---
    11 
    12  * Add `TruncateMode` enum to handle more truncate methods
    13  * Add the `AbstractString::kebab()` method
    14 
    15 7.1
    16 ---
    17 
    18  * Add `localeLower()`, `localeUpper()`, `localeTitle()` methods to `AbstractUnicodeString`
    19 
    20 6.2
    21 ---
    22 
    23   * Add support for emoji in `AsciiSlugger`
    243
    2545.4
  • speechkit/trunk/vendor/symfony/string/CodePointString.php

    r3393083 r3420880  
    3434    }
    3535
    36     public function append(string ...$suffix): static
     36    public function append(string ...$suffix): AbstractString
    3737    {
    3838        $str = clone $this;
     
    8181    }
    8282
    83     public function endsWith(string|iterable|AbstractString $suffix): bool
     83    public function endsWith($suffix): bool
    8484    {
    8585        if ($suffix instanceof AbstractString) {
    8686            $suffix = $suffix->string;
    87         } elseif (!\is_string($suffix)) {
     87        } elseif (\is_array($suffix) || $suffix instanceof \Traversable) {
    8888            return parent::endsWith($suffix);
     89        } else {
     90            $suffix = (string) $suffix;
    8991        }
    9092
     
    100102    }
    101103
    102     public function equalsTo(string|iterable|AbstractString $string): bool
     104    public function equalsTo($string): bool
    103105    {
    104106        if ($string instanceof AbstractString) {
    105107            $string = $string->string;
    106         } elseif (!\is_string($string)) {
     108        } elseif (\is_array($string) || $string instanceof \Traversable) {
    107109            return parent::equalsTo($string);
     110        } else {
     111            $string = (string) $string;
    108112        }
    109113
     
    115119    }
    116120
    117     public function indexOf(string|iterable|AbstractString $needle, int $offset = 0): ?int
     121    public function indexOf($needle, int $offset = 0): ?int
    118122    {
    119123        if ($needle instanceof AbstractString) {
    120124            $needle = $needle->string;
    121         } elseif (!\is_string($needle)) {
     125        } elseif (\is_array($needle) || $needle instanceof \Traversable) {
    122126            return parent::indexOf($needle, $offset);
     127        } else {
     128            $needle = (string) $needle;
    123129        }
    124130
     
    132138    }
    133139
    134     public function indexOfLast(string|iterable|AbstractString $needle, int $offset = 0): ?int
     140    public function indexOfLast($needle, int $offset = 0): ?int
    135141    {
    136142        if ($needle instanceof AbstractString) {
    137143            $needle = $needle->string;
    138         } elseif (!\is_string($needle)) {
     144        } elseif (\is_array($needle) || $needle instanceof \Traversable) {
    139145            return parent::indexOfLast($needle, $offset);
     146        } else {
     147            $needle = (string) $needle;
    140148        }
    141149
     
    154162    }
    155163
    156     public function prepend(string ...$prefix): static
     164    public function prepend(string ...$prefix): AbstractString
    157165    {
    158166        $str = clone $this;
     
    166174    }
    167175
    168     public function replace(string $from, string $to): static
     176    public function replace(string $from, string $to): AbstractString
    169177    {
    170178        $str = clone $this;
     
    187195    }
    188196
    189     public function slice(int $start = 0, ?int $length = null): static
     197    public function slice(int $start = 0, ?int $length = null): AbstractString
    190198    {
    191199        $str = clone $this;
     
    195203    }
    196204
    197     public function splice(string $replacement, int $start = 0, ?int $length = null): static
     205    public function splice(string $replacement, int $start = 0, ?int $length = null): AbstractString
    198206    {
    199207        if (!preg_match('//u', $replacement)) {
     
    211219    public function split(string $delimiter, ?int $limit = null, ?int $flags = null): array
    212220    {
    213         if (1 > $limit ??= \PHP_INT_MAX) {
     221        if (1 > $limit = $limit ?? \PHP_INT_MAX) {
    214222            throw new InvalidArgumentException('Split limit must be a positive integer.');
    215223        }
     
    240248    }
    241249
    242     public function startsWith(string|iterable|AbstractString $prefix): bool
     250    public function startsWith($prefix): bool
    243251    {
    244252        if ($prefix instanceof AbstractString) {
    245253            $prefix = $prefix->string;
    246         } elseif (!\is_string($prefix)) {
     254        } elseif (\is_array($prefix) || $prefix instanceof \Traversable) {
    247255            return parent::startsWith($prefix);
     256        } else {
     257            $prefix = (string) $prefix;
    248258        }
    249259
  • speechkit/trunk/vendor/symfony/string/Inflector/EnglishInflector.php

    r3393083 r3420880  
    2626        // Fifth entry: singular suffix, normal
    2727
    28         // insignias (insigne), insignia (insigne)
    29         ['saingisni', 9, true, true, 'insigne'],
    30         ['aingisni', 8, true, true, 'insigne'],
    31 
    32         // passersby (passerby)
    33         ['ybsressap', 9, true, true, 'passerby'],
    34 
    35         // nodes (node)
    36         ['sedon', 5, true, true, 'node'],
    37 
    3828        // bacteria (bacterium)
    3929        ['airetcab', 8, true, true, 'bacterium'],
    4030
    41         // issues (issue)
    42         ['seussi', 6, true, true, 'issue'],
    43 
    4431        // corpora (corpus)
    4532        ['aroproc', 7, true, true, 'corpus'],
     
    5037        // curricula (curriculum)
    5138        ['alucirruc', 9, true, true, 'curriculum'],
    52 
    53         // quora (quorum)
    54         ['arouq', 5, true, true, 'quorum'],
    5539
    5640        // genera (genus)
     
    179163        // edges (edge)
    180164        ['segd', 4, true, true, 'dge'],
    181 
    182         // outages (outage) - specific fix to avoid 'outag'
    183         ['segatuo', 7, true, true, 'outage'],
    184165
    185166        // roses (rose), garages (garage), cassettes (cassette),
     
    213194        // Fifth entry: plural suffix, normal
    214195
    215         // passerby (passersby)
    216         ['ybressap', 8, true, true, 'passersby'],
    217 
    218         // insigne (insignia, insignias)
    219         ['engisni', 7, true, true, ['insignia', 'insignias']],
    220 
    221         // nodes (node)
    222         ['edon', 4, true, true, 'nodes'],
    223 
    224196        // axes (axis)
    225197        ['sixa', 4, false, false, 'axes'],
     
    296268        // albums (album)
    297269        ['mubla', 5, true, true, 'albums'],
    298 
    299         // quorums (quorum)
    300         ['murouq', 6, true, true, ['quora', 'quorums']],
    301270
    302271        // bacteria (bacterium), curricula (curriculum), media (medium), memoranda (memorandum), phenomena (phenomenon), strata (stratum)
     
    358327        // conspectuses (conspectus), prospectuses (prospectus)
    359328        ['sutcep', 6, true, true, 'pectuses'],
    360 
    361         // nexuses (nexus)
    362         ['suxen', 5, false, false, 'nexuses'],
    363329
    364330        // fungi (fungus), alumni (alumnus), syllabi (syllabus), radii (radius)
  • speechkit/trunk/vendor/symfony/string/Inflector/FrenchInflector.php

    r3393083 r3420880  
    111111    private const UNINFLECTED = '/^(abcès|accès|abus|albatros|anchois|anglais|autobus|bois|brebis|carquois|cas|chas|colis|concours|corps|cours|cyprès|décès|devis|discours|dos|embarras|engrais|entrelacs|excès|fils|fois|gâchis|gars|glas|héros|intrus|jars|jus|kermès|lacis|legs|lilas|marais|mars|matelas|mépris|mets|mois|mors|obus|os|palais|paradis|parcours|pardessus|pays|plusieurs|poids|pois|pouls|printemps|processus|progrès|puits|pus|rabais|radis|recors|recours|refus|relais|remords|remous|rictus|rhinocéros|repas|rubis|sans|sas|secours|sens|souris|succès|talus|tapis|tas|taudis|temps|tiers|univers|velours|verglas|vernis|virus)$/i';
    112112
     113    /**
     114     * {@inheritdoc}
     115     */
    113116    public function singularize(string $plural): array
    114117    {
     
    128131    }
    129132
     133    /**
     134     * {@inheritdoc}
     135     */
    130136    public function pluralize(string $singular): array
    131137    {
  • speechkit/trunk/vendor/symfony/string/LazyString.php

    r3393083 r3420880  
    1919class LazyString implements \Stringable, \JsonSerializable
    2020{
    21     private \Closure|string $value;
     21    private $value;
    2222
    2323    /**
    2424     * @param callable|array $callback A callable or a [Closure, method] lazy-callable
     25     *
     26     * @return static
    2527     */
    26     public static function fromCallable(callable|array $callback, mixed ...$arguments): static
     28    public static function fromCallable($callback, ...$arguments): self
    2729    {
    28         if (\is_array($callback) && !\is_callable($callback) && !(($callback[0] ?? null) instanceof \Closure || 2 < \count($callback))) {
    29             throw new \TypeError(\sprintf('Argument 1 passed to "%s()" must be a callable or a [Closure, method] lazy-callable, "%s" given.', __METHOD__, '['.implode(', ', array_map('get_debug_type', $callback)).']'));
     30        if (!\is_callable($callback) && !(\is_array($callback) && isset($callback[0]) && $callback[0] instanceof \Closure && 2 >= \count($callback))) {
     31            throw new \TypeError(sprintf('Argument 1 passed to "%s()" must be a callable or a [Closure, method] lazy-callable, "%s" given.', __METHOD__, get_debug_type($callback)));
    3032        }
    3133
    3234        $lazyString = new static();
    33         $lazyString->value = static function () use (&$callback, &$arguments): string {
    34             static $value;
    35 
     35        $lazyString->value = static function () use (&$callback, &$arguments, &$value): string {
    3636            if (null !== $arguments) {
    3737                if (!\is_callable($callback)) {
    3838                    $callback[0] = $callback[0]();
    39                     $callback[1] ??= '__invoke';
     39                    $callback[1] = $callback[1] ?? '__invoke';
    4040                }
    4141                $value = $callback(...$arguments);
    42                 $callback = !\is_scalar($value) && !$value instanceof \Stringable ? self::getPrettyName($callback) : 'callable';
     42                $callback = self::getPrettyName($callback);
    4343                $arguments = null;
    4444            }
     
    5050    }
    5151
    52     public static function fromStringable(string|int|float|bool|\Stringable $value): static
     52    /**
     53     * @param string|int|float|bool|\Stringable $value
     54     *
     55     * @return static
     56     */
     57    public static function fromStringable($value): self
    5358    {
     59        if (!self::isStringable($value)) {
     60            throw new \TypeError(sprintf('Argument 1 passed to "%s()" must be a scalar or a stringable object, "%s" given.', __METHOD__, get_debug_type($value)));
     61        }
     62
    5463        if (\is_object($value)) {
    55             return static::fromCallable($value->__toString(...));
     64            return static::fromCallable([$value, '__toString']);
    5665        }
    5766
     
    6574     * Tells whether the provided value can be cast to string.
    6675     */
    67     final public static function isStringable(mixed $value): bool
     76    final public static function isStringable($value): bool
    6877    {
    69         return \is_string($value) || $value instanceof \Stringable || \is_scalar($value);
     78        return \is_string($value) || $value instanceof self || (\is_object($value) ? method_exists($value, '__toString') : \is_scalar($value));
    7079    }
    7180
     
    7382     * Casts scalars and stringable objects to strings.
    7483     *
     84     * @param object|string|int|float|bool $value
     85     *
    7586     * @throws \TypeError When the provided value is not stringable
    7687     */
    77     final public static function resolve(\Stringable|string|int|float|bool $value): string
     88    final public static function resolve($value): string
    7889    {
    7990        return $value;
    8091    }
    8192
    82     public function __toString(): string
     93    /**
     94     * @return string
     95     */
     96    public function __toString()
    8397    {
    8498        if (\is_string($this->value)) {
     
    89103            return $this->value = ($this->value)();
    90104        } catch (\Throwable $e) {
    91             if (\TypeError::class === $e::class && __FILE__ === $e->getFile()) {
     105            if (\TypeError::class === \get_class($e) && __FILE__ === $e->getFile()) {
    92106                $type = explode(', ', $e->getMessage());
    93107                $type = substr(array_pop($type), 0, -\strlen(' returned'));
     
    95109                $callback = $r->getStaticVariables()['callback'];
    96110
    97                 $e = new \TypeError(\sprintf('Return value of %s() passed to %s::fromCallable() must be of the type string, %s returned.', $callback, static::class, $type));
     111                $e = new \TypeError(sprintf('Return value of %s() passed to %s::fromCallable() must be of the type string, %s returned.', $callback, static::class, $type));
     112            }
     113
     114            if (\PHP_VERSION_ID < 70400) {
     115                // leverage the ErrorHandler component with graceful fallback when it's not available
     116                return trigger_error($e, \E_USER_ERROR);
    98117            }
    99118
     
    130149            $r = new \ReflectionFunction($callback);
    131150
    132             if ($r->isAnonymous() || !$class = $r->getClosureCalledClass()) {
     151            if (str_contains($r->name, '{closure') || !$class = \PHP_VERSION_ID >= 80111 ? $r->getClosureCalledClass() : $r->getClosureScopeClass()) {
    133152                return $r->name;
    134153            }
  • speechkit/trunk/vendor/symfony/string/Resources/data/wcswidth_table_wide.php

    r3393083 r3420880  
    22
    33/*
    4  * This file is part of the Symfony package.
    5  *
    6  * (c) Fabien Potencier <fabien@symfony.com>
    7  *
    84 * This file has been auto-generated by the Symfony String Component for internal use.
    95 *
    106 * Unicode version: 16.0.0
    117 * Date: 2024-09-11T08:21:22+00:00
    12  *
    13  * For the full copyright and license information, please view the LICENSE
    14  * file that was distributed with this source code.
    158 */
    169
  • speechkit/trunk/vendor/symfony/string/Resources/data/wcswidth_table_zero.php

    r3393083 r3420880  
    22
    33/*
    4  * This file is part of the Symfony package.
    5  *
    6  * (c) Fabien Potencier <fabien@symfony.com>
    7  *
    84 * This file has been auto-generated by the Symfony String Component for internal use.
    95 *
    106 * Unicode version: 16.0.0
    117 * Date: 2024-09-11T08:21:22+00:00
    12  *
    13  * For the full copyright and license information, please view the LICENSE
    14  * file that was distributed with this source code.
    158 */
    169
  • speechkit/trunk/vendor/symfony/string/Resources/functions.php

    r3393083 r3420880  
    3232    function s(?string $string = ''): AbstractString
    3333    {
    34         $string ??= '';
     34        $string = $string ?? '';
    3535
    3636        return preg_match('//u', $string) ? new UnicodeString($string) : new ByteString($string);
  • speechkit/trunk/vendor/symfony/string/Slugger/AsciiSlugger.php

    r3393083 r3420880  
    1212namespace Symfony\Component\String\Slugger;
    1313
    14 use Symfony\Component\Emoji\EmojiTransliterator;
    1514use Symfony\Component\String\AbstractUnicodeString;
    1615use Symfony\Component\String\UnicodeString;
     
    5655    ];
    5756
    58     private \Closure|array $symbolsMap = [
     57    private $defaultLocale;
     58    private $symbolsMap = [
    5959        'en' => ['@' => 'at', '&' => 'and'],
    6060    ];
    61     private bool|string $emoji = false;
    6261
    6362    /**
     
    6665     * @var \Transliterator[]
    6766     */
    68     private array $transliterators = [];
     67    private $transliterators = [];
    6968
    70     public function __construct(
    71         private ?string $defaultLocale = null,
    72         array|\Closure|null $symbolsMap = null,
    73     ) {
     69    /**
     70     * @param array|\Closure|null $symbolsMap
     71     */
     72    public function __construct(?string $defaultLocale = null, $symbolsMap = null)
     73    {
     74        if (null !== $symbolsMap && !\is_array($symbolsMap) && !$symbolsMap instanceof \Closure) {
     75            throw new \TypeError(sprintf('Argument 2 passed to "%s()" must be array, Closure or null, "%s" given.', __METHOD__, \gettype($symbolsMap)));
     76        }
     77
     78        $this->defaultLocale = $defaultLocale;
    7479        $this->symbolsMap = $symbolsMap ?? $this->symbolsMap;
    7580    }
    7681
    77     public function setLocale(string $locale): void
     82    /**
     83     * {@inheritdoc}
     84     */
     85    public function setLocale($locale)
    7886    {
    7987        $this->defaultLocale = $locale;
    8088    }
    8189
    82     public function getLocale(): string
     90    /**
     91     * {@inheritdoc}
     92     */
     93    public function getLocale()
    8394    {
    8495        return $this->defaultLocale;
     
    8697
    8798    /**
    88      * @param bool|string $emoji true will use the same locale,
    89      *                           false will disable emoji,
    90      *                           and a string to use a specific locale
     99     * {@inheritdoc}
    91100     */
    92     public function withEmoji(bool|string $emoji = true): static
    93     {
    94         if (false !== $emoji && !class_exists(EmojiTransliterator::class)) {
    95             throw new \LogicException(\sprintf('You cannot use the "%s()" method as the "symfony/emoji" package is not installed. Try running "composer require symfony/emoji".', __METHOD__));
    96         }
    97 
    98         $new = clone $this;
    99         $new->emoji = $emoji;
    100 
    101         return $new;
    102     }
    103 
    104101    public function slug(string $string, string $separator = '-', ?string $locale = null): AbstractUnicodeString
    105102    {
    106         $locale ??= $this->defaultLocale;
     103        $locale = $locale ?? $this->defaultLocale;
    107104
    108105        $transliterator = [];
    109         if ($locale && ('de' === $locale || str_starts_with($locale, 'de_'))) {
     106        if ($locale && ('de' === $locale || 0 === strpos($locale, 'de_'))) {
    110107            // Use the shortcut for German in UnicodeString::ascii() if possible (faster and no requirement on intl)
    111108            $transliterator = ['de-ASCII'];
     
    114111        }
    115112
    116         if ($emojiTransliterator = $this->createEmojiTransliterator($locale)) {
    117             $transliterator[] = $emojiTransliterator;
    118         }
    119 
    120113        if ($this->symbolsMap instanceof \Closure) {
    121114            // If the symbols map is passed as a closure, there is no need to fallback to the parent locale
    122115            // as the closure can just provide substitutions for all locales of interest.
    123116            $symbolsMap = $this->symbolsMap;
    124             array_unshift($transliterator, static fn ($s) => $symbolsMap($s, $locale));
     117            array_unshift($transliterator, static function ($s) use ($symbolsMap, $locale) {
     118                return $symbolsMap($s, $locale);
     119            });
    125120        }
    126121
     
    129124        if (\is_array($this->symbolsMap)) {
    130125            $map = null;
    131             if (isset($this->symbolsMap[$locale ?? ''])) {
    132                 $map = $this->symbolsMap[$locale ?? ''];
     126            if (isset($this->symbolsMap[$locale])) {
     127                $map = $this->symbolsMap[$locale];
    133128            } else {
    134129                $parent = self::getParentLocale($locale);
     
    174169    }
    175170
    176     private function createEmojiTransliterator(?string $locale): ?EmojiTransliterator
    177     {
    178         if (\is_string($this->emoji)) {
    179             $locale = $this->emoji;
    180         } elseif (!$this->emoji) {
    181             return null;
    182         }
    183 
    184         while (null !== $locale) {
    185             try {
    186                 return EmojiTransliterator::create("emoji-$locale");
    187             } catch (\IntlException) {
    188                 $locale = self::getParentLocale($locale);
    189             }
    190         }
    191 
    192         return null;
    193     }
    194 
    195171    private static function getParentLocale(?string $locale): ?string
    196172    {
  • speechkit/trunk/vendor/symfony/string/UnicodeString.php

    r3393083 r3420880  
    3535    public function __construct(string $string = '')
    3636    {
    37         if ('' === $string || normalizer_is_normalized($this->string = $string)) {
    38             return;
    39         }
    40 
    41         if (false === $string = normalizer_normalize($string)) {
     37        $this->string = normalizer_is_normalized($string) ? $string : normalizer_normalize($string);
     38
     39        if (false === $this->string) {
    4240            throw new InvalidArgumentException('Invalid UTF-8 string.');
    4341        }
    44 
    45         $this->string = $string;
    46     }
    47 
    48     public function append(string ...$suffix): static
     42    }
     43
     44    public function append(string ...$suffix): AbstractString
    4945    {
    5046        $str = clone $this;
    5147        $str->string = $this->string.(1 >= \count($suffix) ? ($suffix[0] ?? '') : implode('', $suffix));
    52 
    53         if (normalizer_is_normalized($str->string)) {
    54             return $str;
    55         }
    56 
    57         if (false === $string = normalizer_normalize($str->string)) {
     48        normalizer_is_normalized($str->string) ?: $str->string = normalizer_normalize($str->string);
     49
     50        if (false === $str->string) {
    5851            throw new InvalidArgumentException('Invalid UTF-8 string.');
    5952        }
    60 
    61         $str->string = $string;
    6253
    6354        return $str;
     
    9283    }
    9384
    94     public function endsWith(string|iterable|AbstractString $suffix): bool
     85    public function endsWith($suffix): bool
    9586    {
    9687        if ($suffix instanceof AbstractString) {
    9788            $suffix = $suffix->string;
    98         } elseif (!\is_string($suffix)) {
     89        } elseif (\is_array($suffix) || $suffix instanceof \Traversable) {
    9990            return parent::endsWith($suffix);
     91        } else {
     92            $suffix = (string) $suffix;
    10093        }
    10194
     
    114107    }
    115108
    116     public function equalsTo(string|iterable|AbstractString $string): bool
     109    public function equalsTo($string): bool
    117110    {
    118111        if ($string instanceof AbstractString) {
    119112            $string = $string->string;
    120         } elseif (!\is_string($string)) {
     113        } elseif (\is_array($string) || $string instanceof \Traversable) {
    121114            return parent::equalsTo($string);
     115        } else {
     116            $string = (string) $string;
    122117        }
    123118
     
    132127    }
    133128
    134     public function indexOf(string|iterable|AbstractString $needle, int $offset = 0): ?int
     129    public function indexOf($needle, int $offset = 0): ?int
    135130    {
    136131        if ($needle instanceof AbstractString) {
    137132            $needle = $needle->string;
    138         } elseif (!\is_string($needle)) {
     133        } elseif (\is_array($needle) || $needle instanceof \Traversable) {
    139134            return parent::indexOf($needle, $offset);
     135        } else {
     136            $needle = (string) $needle;
    140137        }
    141138
     
    149146        try {
    150147            $i = $this->ignoreCase ? grapheme_stripos($this->string, $needle, $offset) : grapheme_strpos($this->string, $needle, $offset);
    151         } catch (\ValueError) {
     148        } catch (\ValueError $e) {
    152149            return null;
    153150        }
     
    156153    }
    157154
    158     public function indexOfLast(string|iterable|AbstractString $needle, int $offset = 0): ?int
     155    public function indexOfLast($needle, int $offset = 0): ?int
    159156    {
    160157        if ($needle instanceof AbstractString) {
    161158            $needle = $needle->string;
    162         } elseif (!\is_string($needle)) {
     159        } elseif (\is_array($needle) || $needle instanceof \Traversable) {
    163160            return parent::indexOfLast($needle, $offset);
     161        } else {
     162            $needle = (string) $needle;
    164163        }
    165164
     
    186185    }
    187186
    188     public function join(array $strings, ?string $lastGlue = null): static
     187    public function join(array $strings, ?string $lastGlue = null): AbstractString
    189188    {
    190189        $str = parent::join($strings, $lastGlue);
     
    199198    }
    200199
    201     public function normalize(int $form = self::NFC): static
     200    /**
     201     * @return static
     202     */
     203    public function normalize(int $form = self::NFC): parent
    202204    {
    203205        $str = clone $this;
     
    215217    }
    216218
    217     public function prepend(string ...$prefix): static
     219    public function prepend(string ...$prefix): AbstractString
    218220    {
    219221        $str = clone $this;
    220222        $str->string = (1 >= \count($prefix) ? ($prefix[0] ?? '') : implode('', $prefix)).$this->string;
    221 
    222         if (normalizer_is_normalized($str->string)) {
    223             return $str;
    224         }
    225 
    226         if (false === $string = normalizer_normalize($str->string)) {
     223        normalizer_is_normalized($str->string) ?: $str->string = normalizer_normalize($str->string);
     224
     225        if (false === $str->string) {
    227226            throw new InvalidArgumentException('Invalid UTF-8 string.');
    228227        }
    229228
    230         $str->string = $string;
    231 
    232         return $str;
    233     }
    234 
    235     public function replace(string $from, string $to): static
     229        return $str;
     230    }
     231
     232    public function replace(string $from, string $to): AbstractString
    236233    {
    237234        $str = clone $this;
     
    250247
    251248            $str->string = $result.$tail;
    252 
    253             if (normalizer_is_normalized($str->string)) {
    254                 return $str;
    255             }
    256 
    257             if (false === $string = normalizer_normalize($str->string)) {
     249            normalizer_is_normalized($str->string) ?: $str->string = normalizer_normalize($str->string);
     250
     251            if (false === $str->string) {
    258252                throw new InvalidArgumentException('Invalid UTF-8 string.');
    259253            }
    260 
    261             $str->string = $string;
    262         }
    263 
    264         return $str;
    265     }
    266 
    267     public function replaceMatches(string $fromRegexp, string|callable $to): static
     254        }
     255
     256        return $str;
     257    }
     258
     259    public function replaceMatches(string $fromRegexp, $to): AbstractString
    268260    {
    269261        $str = parent::replaceMatches($fromRegexp, $to);
     
    273265    }
    274266
    275     public function slice(int $start = 0, ?int $length = null): static
    276     {
    277         $str = clone $this;
    278 
     267    public function slice(int $start = 0, ?int $length = null): AbstractString
     268    {
     269        $str = clone $this;
     270
     271        if (\PHP_VERSION_ID < 80000 && 0 > $start && grapheme_strlen($this->string) < -$start) {
     272            $start = 0;
     273        }
    279274        $str->string = (string) grapheme_substr($this->string, $start, $length ?? 2147483647);
    280275
     
    282277    }
    283278
    284     public function splice(string $replacement, int $start = 0, ?int $length = null): static
    285     {
    286         $str = clone $this;
    287 
     279    public function splice(string $replacement, int $start = 0, ?int $length = null): AbstractString
     280    {
     281        $str = clone $this;
     282
     283        if (\PHP_VERSION_ID < 80000 && 0 > $start && grapheme_strlen($this->string) < -$start) {
     284            $start = 0;
     285        }
    288286        $start = $start ? \strlen(grapheme_substr($this->string, 0, $start)) : 0;
    289         $length = $length ? \strlen(grapheme_substr($this->string, $start, $length)) : $length;
     287        $length = $length ? \strlen(grapheme_substr($this->string, $start, $length ?? 2147483647)) : $length;
    290288        $str->string = substr_replace($this->string, $replacement, $start, $length ?? 2147483647);
    291 
    292         if (normalizer_is_normalized($str->string)) {
    293             return $str;
    294         }
    295 
    296         if (false === $string = normalizer_normalize($str->string)) {
     289        normalizer_is_normalized($str->string) ?: $str->string = normalizer_normalize($str->string);
     290
     291        if (false === $str->string) {
    297292            throw new InvalidArgumentException('Invalid UTF-8 string.');
    298293        }
    299294
    300         $str->string = $string;
    301 
    302295        return $str;
    303296    }
     
    305298    public function split(string $delimiter, ?int $limit = null, ?int $flags = null): array
    306299    {
    307         if (1 > $limit ??= 2147483647) {
     300        if (1 > $limit = $limit ?? 2147483647) {
    308301            throw new InvalidArgumentException('Split limit must be a positive integer.');
    309302        }
     
    341334    }
    342335
    343     public function startsWith(string|iterable|AbstractString $prefix): bool
     336    public function startsWith($prefix): bool
    344337    {
    345338        if ($prefix instanceof AbstractString) {
    346339            $prefix = $prefix->string;
    347         } elseif (!\is_string($prefix)) {
     340        } elseif (\is_array($prefix) || $prefix instanceof \Traversable) {
    348341            return parent::startsWith($prefix);
     342        } else {
     343            $prefix = (string) $prefix;
    349344        }
    350345
     
    363358    }
    364359
    365     public function __wakeup(): void
     360    public function __wakeup()
    366361    {
    367362        if (!\is_string($this->string)) {
  • speechkit/trunk/vendor/symfony/string/composer.json

    r3393083 r3420880  
    1717    ],
    1818    "require": {
    19         "php": ">=8.2",
     19        "php": ">=7.2.5",
    2020        "symfony/polyfill-ctype": "~1.8",
    2121        "symfony/polyfill-intl-grapheme": "~1.0",
    2222        "symfony/polyfill-intl-normalizer": "~1.0",
    23         "symfony/polyfill-mbstring": "~1.0"
     23        "symfony/polyfill-mbstring": "~1.0",
     24        "symfony/polyfill-php80": "~1.15"
    2425    },
    2526    "require-dev": {
    26         "symfony/emoji": "^7.1",
    27         "symfony/http-client": "^6.4|^7.0",
    28         "symfony/intl": "^6.4|^7.0",
    29         "symfony/translation-contracts": "^2.5|^3.0",
    30         "symfony/var-exporter": "^6.4|^7.0"
     27        "symfony/error-handler": "^4.4|^5.0|^6.0",
     28        "symfony/http-client": "^4.4|^5.0|^6.0",
     29        "symfony/translation-contracts": "^1.1|^2",
     30        "symfony/var-exporter": "^4.4|^5.0|^6.0"
    3131    },
    3232    "conflict": {
    33         "symfony/translation-contracts": "<2.5"
     33        "symfony/translation-contracts": ">=3.0"
    3434    },
    3535    "autoload": {
Note: See TracChangeset for help on using the changeset viewer.