diff --git a/composer.lock b/composer.lock index 2db2d870..7c17f09f 100644 --- a/composer.lock +++ b/composer.lock @@ -173,79 +173,6 @@ ], "time": "2021-03-30T17:13:30+00:00" }, - { - "name": "composer/package-versions-deprecated", - "version": "1.11.99.5", - "source": { - "type": "git", - "url": "https://github.com/composer/package-versions-deprecated.git", - "reference": "b4f54f74ef3453349c24a845d22392cd31e65f1d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/b4f54f74ef3453349c24a845d22392cd31e65f1d", - "reference": "b4f54f74ef3453349c24a845d22392cd31e65f1d", - "shasum": "" - }, - "require": { - "composer-plugin-api": "^1.1.0 || ^2.0", - "php": "^7 || ^8" - }, - "replace": { - "ocramius/package-versions": "1.11.99" - }, - "require-dev": { - "composer/composer": "^1.9.3 || ^2.0@dev", - "ext-zip": "^1.13", - "phpunit/phpunit": "^6.5 || ^7" - }, - "type": "composer-plugin", - "extra": { - "class": "PackageVersions\\Installer", - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "PackageVersions\\": "src/PackageVersions" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com" - }, - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be" - } - ], - "description": "Composer plugin that provides efficient querying for installed package versions (no runtime IO)", - "support": { - "issues": "https://github.com/composer/package-versions-deprecated/issues", - "source": "https://github.com/composer/package-versions-deprecated/tree/1.11.99.5" - }, - "funding": [ - { - "url": "https://packagist.com", - "type": "custom" - }, - { - "url": "https://github.com/composer", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/composer/composer", - "type": "tidelift" - } - ], - "time": "2022-01-17T14:14:24+00:00" - }, { "name": "composer/pcre", "version": "3.1.0", @@ -501,6 +428,49 @@ }, "time": "2019-12-04T15:06:13+00:00" }, + { + "name": "doctrine/deprecations", + "version": "v1.0.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/deprecations.git", + "reference": "0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/deprecations/zipball/0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de", + "reference": "0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de", + "shasum": "" + }, + "require": { + "php": "^7.1|^8.0" + }, + "require-dev": { + "doctrine/coding-standard": "^9", + "phpunit/phpunit": "^7.5|^8.5|^9.5", + "psr/log": "^1|^2|^3" + }, + "suggest": { + "psr/log": "Allows logging deprecations via PSR-3 logger implementation" + }, + "type": "library", + "autoload": { + "psr-4": { + "Doctrine\\Deprecations\\": "lib/Doctrine/Deprecations" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A small layer on top of trigger_error(E_USER_DEPRECATED) or PSR-3 logging with options to disable all deprecations or selectively for packages.", + "homepage": "https://www.doctrine-project.org/", + "support": { + "issues": "https://github.com/doctrine/deprecations/issues", + "source": "https://github.com/doctrine/deprecations/tree/v1.0.0" + }, + "time": "2022-05-02T15:47:09+00:00" + }, { "name": "felixfbecker/advanced-json-rpc", "version": "v3.2.1", @@ -1006,24 +976,27 @@ }, { "name": "phpdocumentor/type-resolver", - "version": "1.6.2", + "version": "1.7.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "48f445a408c131e38cab1c235aa6d2bb7a0bb20d" + "reference": "dfc078e8af9c99210337325ff5aa152872c98714" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/48f445a408c131e38cab1c235aa6d2bb7a0bb20d", - "reference": "48f445a408c131e38cab1c235aa6d2bb7a0bb20d", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/dfc078e8af9c99210337325ff5aa152872c98714", + "reference": "dfc078e8af9c99210337325ff5aa152872c98714", "shasum": "" }, "require": { + "doctrine/deprecations": "^1.0", "php": "^7.4 || ^8.0", - "phpdocumentor/reflection-common": "^2.0" + "phpdocumentor/reflection-common": "^2.0", + "phpstan/phpdoc-parser": "^1.13" }, "require-dev": { "ext-tokenizer": "*", + "phpbench/phpbench": "^1.2", "phpstan/extension-installer": "^1.1", "phpstan/phpstan": "^1.8", "phpstan/phpstan-phpunit": "^1.1", @@ -1055,9 +1028,9 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.6.2" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.7.1" }, - "time": "2022-10-14T12:47:21+00:00" + "time": "2023-03-27T19:02:04+00:00" }, { "name": "phpstan/extension-installer", @@ -1104,17 +1077,62 @@ "time": "2022-10-17T12:59:16+00:00" }, { - "name": "phpstan/phpstan", - "version": "1.10.5", + "name": "phpstan/phpdoc-parser", + "version": "1.16.1", "source": { "type": "git", - "url": "https://github.com/phpstan/phpstan.git", - "reference": "1fb6f494d82455151ecf15c5c191923f5d84324e" + "url": "https://github.com/phpstan/phpdoc-parser.git", + "reference": "e27e92d939e2e3636f0a1f0afaba59692c0bf571" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpstan/zipball/1fb6f494d82455151ecf15c5c191923f5d84324e", - "reference": "1fb6f494d82455151ecf15c5c191923f5d84324e", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/e27e92d939e2e3636f0a1f0afaba59692c0bf571", + "reference": "e27e92d939e2e3636f0a1f0afaba59692c0bf571", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "require-dev": { + "php-parallel-lint/php-parallel-lint": "^1.2", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^1.5", + "phpstan/phpstan-phpunit": "^1.1", + "phpstan/phpstan-strict-rules": "^1.0", + "phpunit/phpunit": "^9.5", + "symfony/process": "^5.2" + }, + "type": "library", + "autoload": { + "psr-4": { + "PHPStan\\PhpDocParser\\": [ + "src/" + ] + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "PHPDoc parser with support for nullable, intersection and generic types", + "support": { + "issues": "https://github.com/phpstan/phpdoc-parser/issues", + "source": "https://github.com/phpstan/phpdoc-parser/tree/1.16.1" + }, + "time": "2023-02-07T18:11:17+00:00" + }, + { + "name": "phpstan/phpstan", + "version": "1.10.8", + "source": { + "type": "git", + "url": "https://github.com/phpstan/phpstan.git", + "reference": "0166aef76e066f0dd2adc2799bdadfa1635711e9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/0166aef76e066f0dd2adc2799bdadfa1635711e9", + "reference": "0166aef76e066f0dd2adc2799bdadfa1635711e9", "shasum": "" }, "require": { @@ -1143,8 +1161,11 @@ "static analysis" ], "support": { + "docs": "https://phpstan.org/user-guide/getting-started", + "forum": "https://github.com/phpstan/phpstan/discussions", "issues": "https://github.com/phpstan/phpstan/issues", - "source": "https://github.com/phpstan/phpstan/tree/1.10.5" + "security": "https://github.com/phpstan/phpstan/security/policy", + "source": "https://github.com/phpstan/phpstan-src" }, "funding": [ { @@ -1160,20 +1181,20 @@ "type": "tidelift" } ], - "time": "2023-03-07T16:48:45+00:00" + "time": "2023-03-24T10:28:16+00:00" }, { "name": "phpstan/phpstan-deprecation-rules", - "version": "1.1.2", + "version": "1.1.3", "source": { "type": "git", "url": "https://github.com/phpstan/phpstan-deprecation-rules.git", - "reference": "bcc1e8cdf81c3da1a2ba9188ee94cd7e2a62e865" + "reference": "a22b36b955a2e9a3d39fe533b6c1bb5359f9c319" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpstan-deprecation-rules/zipball/bcc1e8cdf81c3da1a2ba9188ee94cd7e2a62e865", - "reference": "bcc1e8cdf81c3da1a2ba9188ee94cd7e2a62e865", + "url": "https://api.github.com/repos/phpstan/phpstan-deprecation-rules/zipball/a22b36b955a2e9a3d39fe533b6c1bb5359f9c319", + "reference": "a22b36b955a2e9a3d39fe533b6c1bb5359f9c319", "shasum": "" }, "require": { @@ -1206,9 +1227,9 @@ "description": "PHPStan rules for detecting usage of deprecated classes, methods, properties, constants and traits.", "support": { "issues": "https://github.com/phpstan/phpstan-deprecation-rules/issues", - "source": "https://github.com/phpstan/phpstan-deprecation-rules/tree/1.1.2" + "source": "https://github.com/phpstan/phpstan-deprecation-rules/tree/1.1.3" }, - "time": "2023-01-17T16:14:21+00:00" + "time": "2023-03-17T07:50:08+00:00" }, { "name": "psr/container", @@ -1381,16 +1402,16 @@ }, { "name": "sebastian/diff", - "version": "5.0.0", + "version": "5.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "70dd1b20bc198da394ad542e988381b44e64e39f" + "reference": "aae9a0a43bff37bd5d8d0311426c87bf36153f02" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/70dd1b20bc198da394ad542e988381b44e64e39f", - "reference": "70dd1b20bc198da394ad542e988381b44e64e39f", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/aae9a0a43bff37bd5d8d0311426c87bf36153f02", + "reference": "aae9a0a43bff37bd5d8d0311426c87bf36153f02", "shasum": "" }, "require": { @@ -1435,7 +1456,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/5.0.0" + "security": "https://github.com/sebastianbergmann/diff/security/policy", + "source": "https://github.com/sebastianbergmann/diff/tree/5.0.1" }, "funding": [ { @@ -1443,7 +1465,7 @@ "type": "github" } ], - "time": "2023-02-03T07:00:31+00:00" + "time": "2023-03-23T05:12:41+00:00" }, { "name": "spatie/array-to-xml", @@ -2382,22 +2404,22 @@ }, { "name": "vimeo/psalm", - "version": "5.7.7", + "version": "5.8.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "e028ba46ba0d7f9a78bc3201c251e137383e145f" + "reference": "9cf4f60a333f779ad3bc704a555920e81d4fdcda" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/e028ba46ba0d7f9a78bc3201c251e137383e145f", - "reference": "e028ba46ba0d7f9a78bc3201c251e137383e145f", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/9cf4f60a333f779ad3bc704a555920e81d4fdcda", + "reference": "9cf4f60a333f779ad3bc704a555920e81d4fdcda", "shasum": "" }, "require": { "amphp/amp": "^2.4.2", "amphp/byte-stream": "^1.5", - "composer/package-versions-deprecated": "^1.10.0", + "composer-runtime-api": "^2", "composer/semver": "^1.4 || ^2.0 || ^3.0", "composer/xdebug-handler": "^2.0 || ^3.0", "dnoegel/php-xdg-base-dir": "^0.1.1", @@ -2412,7 +2434,7 @@ "felixfbecker/language-server-protocol": "^1.5.2", "fidry/cpu-core-counter": "^0.4.1 || ^0.5.1", "netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0 || ^4.0", - "nikic/php-parser": "^4.13", + "nikic/php-parser": "^4.14", "php": "^7.4 || ~8.0.0 || ~8.1.0 || ~8.2.0", "sebastian/diff": "^4.0 || ^5.0", "spatie/array-to-xml": "^2.17.0 || ^3.0", @@ -2481,9 +2503,9 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/5.7.7" + "source": "https://github.com/vimeo/psalm/tree/5.8.0" }, - "time": "2023-02-25T01:05:07+00:00" + "time": "2023-03-09T04:14:35+00:00" }, { "name": "webmozart/assert", diff --git a/vendor/composer/autoload_psr4.php b/vendor/composer/autoload_psr4.php index 39e53205..9830ddd7 100644 --- a/vendor/composer/autoload_psr4.php +++ b/vendor/composer/autoload_psr4.php @@ -26,12 +26,13 @@ return array( 'Psalm\\' => array($vendorDir . '/vimeo/psalm/src/Psalm'), 'PhpParser\\' => array($vendorDir . '/nikic/php-parser/lib/PhpParser'), 'Phan\\' => array($vendorDir . '/phan/phan/src/Phan'), - 'PackageVersions\\' => array($vendorDir . '/composer/package-versions-deprecated/src/PackageVersions'), + 'PHPStan\\PhpDocParser\\' => array($vendorDir . '/phpstan/phpdoc-parser/src'), 'PHPStan\\ExtensionInstaller\\' => array($vendorDir . '/phpstan/extension-installer/src'), 'PHPStan\\' => array($vendorDir . '/phpstan/phpstan-deprecation-rules/src'), 'Microsoft\\PhpParser\\' => array($vendorDir . '/microsoft/tolerant-php-parser/src'), 'LanguageServerProtocol\\' => array($vendorDir . '/felixfbecker/language-server-protocol/src'), 'Fidry\\CpuCoreCounter\\' => array($vendorDir . '/fidry/cpu-core-counter/src'), + 'Doctrine\\Deprecations\\' => array($vendorDir . '/doctrine/deprecations/lib/Doctrine/Deprecations'), 'Composer\\XdebugHandler\\' => array($vendorDir . '/composer/xdebug-handler/src'), 'Composer\\Semver\\' => array($vendorDir . '/composer/semver/src'), 'Composer\\Pcre\\' => array($vendorDir . '/composer/pcre/src'), diff --git a/vendor/composer/autoload_static.php b/vendor/composer/autoload_static.php index f9cf85b5..647cadf6 100644 --- a/vendor/composer/autoload_static.php +++ b/vendor/composer/autoload_static.php @@ -62,7 +62,7 @@ class ComposerStaticInitdd705c6e8ab22e0d642372dec7767718 'Psalm\\' => 6, 'PhpParser\\' => 10, 'Phan\\' => 5, - 'PackageVersions\\' => 16, + 'PHPStan\\PhpDocParser\\' => 21, 'PHPStan\\ExtensionInstaller\\' => 27, 'PHPStan\\' => 8, ), @@ -78,6 +78,10 @@ class ComposerStaticInitdd705c6e8ab22e0d642372dec7767718 array ( 'Fidry\\CpuCoreCounter\\' => 21, ), + 'D' => + array ( + 'Doctrine\\Deprecations\\' => 22, + ), 'C' => array ( 'Composer\\XdebugHandler\\' => 23, @@ -175,9 +179,9 @@ class ComposerStaticInitdd705c6e8ab22e0d642372dec7767718 array ( 0 => __DIR__ . '/..' . '/phan/phan/src/Phan', ), - 'PackageVersions\\' => + 'PHPStan\\PhpDocParser\\' => array ( - 0 => __DIR__ . '/..' . '/composer/package-versions-deprecated/src/PackageVersions', + 0 => __DIR__ . '/..' . '/phpstan/phpdoc-parser/src', ), 'PHPStan\\ExtensionInstaller\\' => array ( @@ -199,6 +203,10 @@ class ComposerStaticInitdd705c6e8ab22e0d642372dec7767718 array ( 0 => __DIR__ . '/..' . '/fidry/cpu-core-counter/src', ), + 'Doctrine\\Deprecations\\' => + array ( + 0 => __DIR__ . '/..' . '/doctrine/deprecations/lib/Doctrine/Deprecations', + ), 'Composer\\XdebugHandler\\' => array ( 0 => __DIR__ . '/..' . '/composer/xdebug-handler/src', diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index a47ea436..2fe33c4b 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -172,82 +172,6 @@ ], "install-path": "../amphp/byte-stream" }, - { - "name": "composer/package-versions-deprecated", - "version": "1.11.99.5", - "version_normalized": "1.11.99.5", - "source": { - "type": "git", - "url": "https://github.com/composer/package-versions-deprecated.git", - "reference": "b4f54f74ef3453349c24a845d22392cd31e65f1d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/package-versions-deprecated/zipball/b4f54f74ef3453349c24a845d22392cd31e65f1d", - "reference": "b4f54f74ef3453349c24a845d22392cd31e65f1d", - "shasum": "" - }, - "require": { - "composer-plugin-api": "^1.1.0 || ^2.0", - "php": "^7 || ^8" - }, - "replace": { - "ocramius/package-versions": "1.11.99" - }, - "require-dev": { - "composer/composer": "^1.9.3 || ^2.0@dev", - "ext-zip": "^1.13", - "phpunit/phpunit": "^6.5 || ^7" - }, - "time": "2022-01-17T14:14:24+00:00", - "type": "composer-plugin", - "extra": { - "class": "PackageVersions\\Installer", - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "PackageVersions\\": "src/PackageVersions" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com" - }, - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be" - } - ], - "description": "Composer plugin that provides efficient querying for installed package versions (no runtime IO)", - "support": { - "issues": "https://github.com/composer/package-versions-deprecated/issues", - "source": "https://github.com/composer/package-versions-deprecated/tree/1.11.99.5" - }, - "funding": [ - { - "url": "https://packagist.com", - "type": "custom" - }, - { - "url": "https://github.com/composer", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/composer/composer", - "type": "tidelift" - } - ], - "install-path": "./package-versions-deprecated" - }, { "name": "composer/pcre", "version": "3.1.0", @@ -515,6 +439,52 @@ }, "install-path": "../dnoegel/php-xdg-base-dir" }, + { + "name": "doctrine/deprecations", + "version": "v1.0.0", + "version_normalized": "1.0.0.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/deprecations.git", + "reference": "0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/deprecations/zipball/0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de", + "reference": "0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de", + "shasum": "" + }, + "require": { + "php": "^7.1|^8.0" + }, + "require-dev": { + "doctrine/coding-standard": "^9", + "phpunit/phpunit": "^7.5|^8.5|^9.5", + "psr/log": "^1|^2|^3" + }, + "suggest": { + "psr/log": "Allows logging deprecations via PSR-3 logger implementation" + }, + "time": "2022-05-02T15:47:09+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "psr-4": { + "Doctrine\\Deprecations\\": "lib/Doctrine/Deprecations" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A small layer on top of trigger_error(E_USER_DEPRECATED) or PSR-3 logging with options to disable all deprecations or selectively for packages.", + "homepage": "https://www.doctrine-project.org/", + "support": { + "issues": "https://github.com/doctrine/deprecations/issues", + "source": "https://github.com/doctrine/deprecations/tree/v1.0.0" + }, + "install-path": "../doctrine/deprecations" + }, { "name": "felixfbecker/advanced-json-rpc", "version": "v3.2.1", @@ -1047,25 +1017,28 @@ }, { "name": "phpdocumentor/type-resolver", - "version": "1.6.2", - "version_normalized": "1.6.2.0", + "version": "1.7.1", + "version_normalized": "1.7.1.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "48f445a408c131e38cab1c235aa6d2bb7a0bb20d" + "reference": "dfc078e8af9c99210337325ff5aa152872c98714" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/48f445a408c131e38cab1c235aa6d2bb7a0bb20d", - "reference": "48f445a408c131e38cab1c235aa6d2bb7a0bb20d", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/dfc078e8af9c99210337325ff5aa152872c98714", + "reference": "dfc078e8af9c99210337325ff5aa152872c98714", "shasum": "" }, "require": { + "doctrine/deprecations": "^1.0", "php": "^7.4 || ^8.0", - "phpdocumentor/reflection-common": "^2.0" + "phpdocumentor/reflection-common": "^2.0", + "phpstan/phpdoc-parser": "^1.13" }, "require-dev": { "ext-tokenizer": "*", + "phpbench/phpbench": "^1.2", "phpstan/extension-installer": "^1.1", "phpstan/phpstan": "^1.8", "phpstan/phpstan-phpunit": "^1.1", @@ -1073,7 +1046,7 @@ "rector/rector": "^0.13.9", "vimeo/psalm": "^4.25" }, - "time": "2022-10-14T12:47:21+00:00", + "time": "2023-03-27T19:02:04+00:00", "type": "library", "extra": { "branch-alias": { @@ -1099,7 +1072,7 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.6.2" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.7.1" }, "install-path": "../phpdocumentor/type-resolver" }, @@ -1151,18 +1124,66 @@ "install-path": "../phpstan/extension-installer" }, { - "name": "phpstan/phpstan", - "version": "1.10.5", - "version_normalized": "1.10.5.0", + "name": "phpstan/phpdoc-parser", + "version": "1.16.1", + "version_normalized": "1.16.1.0", "source": { "type": "git", - "url": "https://github.com/phpstan/phpstan.git", - "reference": "1fb6f494d82455151ecf15c5c191923f5d84324e" + "url": "https://github.com/phpstan/phpdoc-parser.git", + "reference": "e27e92d939e2e3636f0a1f0afaba59692c0bf571" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpstan/zipball/1fb6f494d82455151ecf15c5c191923f5d84324e", - "reference": "1fb6f494d82455151ecf15c5c191923f5d84324e", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/e27e92d939e2e3636f0a1f0afaba59692c0bf571", + "reference": "e27e92d939e2e3636f0a1f0afaba59692c0bf571", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "require-dev": { + "php-parallel-lint/php-parallel-lint": "^1.2", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^1.5", + "phpstan/phpstan-phpunit": "^1.1", + "phpstan/phpstan-strict-rules": "^1.0", + "phpunit/phpunit": "^9.5", + "symfony/process": "^5.2" + }, + "time": "2023-02-07T18:11:17+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "psr-4": { + "PHPStan\\PhpDocParser\\": [ + "src/" + ] + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "PHPDoc parser with support for nullable, intersection and generic types", + "support": { + "issues": "https://github.com/phpstan/phpdoc-parser/issues", + "source": "https://github.com/phpstan/phpdoc-parser/tree/1.16.1" + }, + "install-path": "../phpstan/phpdoc-parser" + }, + { + "name": "phpstan/phpstan", + "version": "1.10.8", + "version_normalized": "1.10.8.0", + "source": { + "type": "git", + "url": "https://github.com/phpstan/phpstan.git", + "reference": "0166aef76e066f0dd2adc2799bdadfa1635711e9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/0166aef76e066f0dd2adc2799bdadfa1635711e9", + "reference": "0166aef76e066f0dd2adc2799bdadfa1635711e9", "shasum": "" }, "require": { @@ -1171,7 +1192,7 @@ "conflict": { "phpstan/phpstan-shim": "*" }, - "time": "2023-03-07T16:48:45+00:00", + "time": "2023-03-24T10:28:16+00:00", "bin": [ "phpstan", "phpstan.phar" @@ -1193,8 +1214,11 @@ "static analysis" ], "support": { + "docs": "https://phpstan.org/user-guide/getting-started", + "forum": "https://github.com/phpstan/phpstan/discussions", "issues": "https://github.com/phpstan/phpstan/issues", - "source": "https://github.com/phpstan/phpstan/tree/1.10.5" + "security": "https://github.com/phpstan/phpstan/security/policy", + "source": "https://github.com/phpstan/phpstan-src" }, "funding": [ { @@ -1214,17 +1238,17 @@ }, { "name": "phpstan/phpstan-deprecation-rules", - "version": "1.1.2", - "version_normalized": "1.1.2.0", + "version": "1.1.3", + "version_normalized": "1.1.3.0", "source": { "type": "git", "url": "https://github.com/phpstan/phpstan-deprecation-rules.git", - "reference": "bcc1e8cdf81c3da1a2ba9188ee94cd7e2a62e865" + "reference": "a22b36b955a2e9a3d39fe533b6c1bb5359f9c319" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpstan-deprecation-rules/zipball/bcc1e8cdf81c3da1a2ba9188ee94cd7e2a62e865", - "reference": "bcc1e8cdf81c3da1a2ba9188ee94cd7e2a62e865", + "url": "https://api.github.com/repos/phpstan/phpstan-deprecation-rules/zipball/a22b36b955a2e9a3d39fe533b6c1bb5359f9c319", + "reference": "a22b36b955a2e9a3d39fe533b6c1bb5359f9c319", "shasum": "" }, "require": { @@ -1237,7 +1261,7 @@ "phpstan/phpstan-phpunit": "^1.0", "phpunit/phpunit": "^9.5" }, - "time": "2023-01-17T16:14:21+00:00", + "time": "2023-03-17T07:50:08+00:00", "type": "phpstan-extension", "extra": { "phpstan": { @@ -1259,7 +1283,7 @@ "description": "PHPStan rules for detecting usage of deprecated classes, methods, properties, constants and traits.", "support": { "issues": "https://github.com/phpstan/phpstan-deprecation-rules/issues", - "source": "https://github.com/phpstan/phpstan-deprecation-rules/tree/1.1.2" + "source": "https://github.com/phpstan/phpstan-deprecation-rules/tree/1.1.3" }, "install-path": "../phpstan/phpstan-deprecation-rules" }, @@ -1443,17 +1467,17 @@ }, { "name": "sebastian/diff", - "version": "5.0.0", - "version_normalized": "5.0.0.0", + "version": "5.0.1", + "version_normalized": "5.0.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "70dd1b20bc198da394ad542e988381b44e64e39f" + "reference": "aae9a0a43bff37bd5d8d0311426c87bf36153f02" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/70dd1b20bc198da394ad542e988381b44e64e39f", - "reference": "70dd1b20bc198da394ad542e988381b44e64e39f", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/aae9a0a43bff37bd5d8d0311426c87bf36153f02", + "reference": "aae9a0a43bff37bd5d8d0311426c87bf36153f02", "shasum": "" }, "require": { @@ -1463,7 +1487,7 @@ "phpunit/phpunit": "^10.0", "symfony/process": "^4.2 || ^5" }, - "time": "2023-02-03T07:00:31+00:00", + "time": "2023-03-23T05:12:41+00:00", "type": "library", "extra": { "branch-alias": { @@ -1500,7 +1524,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/5.0.0" + "security": "https://github.com/sebastianbergmann/diff/security/policy", + "source": "https://github.com/sebastianbergmann/diff/tree/5.0.1" }, "funding": [ { @@ -2483,23 +2508,23 @@ }, { "name": "vimeo/psalm", - "version": "5.7.7", - "version_normalized": "5.7.7.0", + "version": "5.8.0", + "version_normalized": "5.8.0.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "e028ba46ba0d7f9a78bc3201c251e137383e145f" + "reference": "9cf4f60a333f779ad3bc704a555920e81d4fdcda" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/e028ba46ba0d7f9a78bc3201c251e137383e145f", - "reference": "e028ba46ba0d7f9a78bc3201c251e137383e145f", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/9cf4f60a333f779ad3bc704a555920e81d4fdcda", + "reference": "9cf4f60a333f779ad3bc704a555920e81d4fdcda", "shasum": "" }, "require": { "amphp/amp": "^2.4.2", "amphp/byte-stream": "^1.5", - "composer/package-versions-deprecated": "^1.10.0", + "composer-runtime-api": "^2", "composer/semver": "^1.4 || ^2.0 || ^3.0", "composer/xdebug-handler": "^2.0 || ^3.0", "dnoegel/php-xdg-base-dir": "^0.1.1", @@ -2514,7 +2539,7 @@ "felixfbecker/language-server-protocol": "^1.5.2", "fidry/cpu-core-counter": "^0.4.1 || ^0.5.1", "netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0 || ^4.0", - "nikic/php-parser": "^4.13", + "nikic/php-parser": "^4.14", "php": "^7.4 || ~8.0.0 || ~8.1.0 || ~8.2.0", "sebastian/diff": "^4.0 || ^5.0", "spatie/array-to-xml": "^2.17.0 || ^3.0", @@ -2543,7 +2568,7 @@ "ext-curl": "In order to send data to shepherd", "ext-igbinary": "^2.0.5 is required, used to serialize caching data" }, - "time": "2023-02-25T01:05:07+00:00", + "time": "2023-03-09T04:14:35+00:00", "bin": [ "psalm", "psalm-language-server", @@ -2585,7 +2610,7 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/5.7.7" + "source": "https://github.com/vimeo/psalm/tree/5.8.0" }, "install-path": "../vimeo/psalm" }, @@ -2655,11 +2680,11 @@ "dev-package-names": [ "amphp/amp", "amphp/byte-stream", - "composer/package-versions-deprecated", "composer/pcre", "composer/semver", "composer/xdebug-handler", "dnoegel/php-xdg-base-dir", + "doctrine/deprecations", "felixfbecker/advanced-json-rpc", "felixfbecker/language-server-protocol", "fidry/cpu-core-counter", @@ -2671,6 +2696,7 @@ "phpdocumentor/reflection-docblock", "phpdocumentor/type-resolver", "phpstan/extension-installer", + "phpstan/phpdoc-parser", "phpstan/phpstan", "phpstan/phpstan-deprecation-rules", "psr/container", diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index 4c12da7f..9f147870 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -28,15 +28,6 @@ 'aliases' => array(), 'dev_requirement' => true, ), - 'composer/package-versions-deprecated' => array( - 'pretty_version' => '1.11.99.5', - 'version' => '1.11.99.5', - 'reference' => 'b4f54f74ef3453349c24a845d22392cd31e65f1d', - 'type' => 'composer-plugin', - 'install_path' => __DIR__ . '/./package-versions-deprecated', - 'aliases' => array(), - 'dev_requirement' => true, - ), 'composer/pcre' => array( 'pretty_version' => '3.1.0', 'version' => '3.1.0.0', @@ -73,6 +64,15 @@ 'aliases' => array(), 'dev_requirement' => true, ), + 'doctrine/deprecations' => array( + 'pretty_version' => 'v1.0.0', + 'version' => '1.0.0.0', + 'reference' => '0e2a4f1f8cdfc7a92ec3b01c9334898c806b30de', + 'type' => 'library', + 'install_path' => __DIR__ . '/../doctrine/deprecations', + 'aliases' => array(), + 'dev_requirement' => true, + ), 'egrajp/development-corelibs-dev' => array( 'pretty_version' => 'dev-master', 'version' => 'dev-master', @@ -136,12 +136,6 @@ 'aliases' => array(), 'dev_requirement' => true, ), - 'ocramius/package-versions' => array( - 'dev_requirement' => true, - 'replaced' => array( - 0 => '1.11.99', - ), - ), 'phan/phan' => array( 'pretty_version' => '5.4.2', 'version' => '5.4.2.0', @@ -170,9 +164,9 @@ 'dev_requirement' => true, ), 'phpdocumentor/type-resolver' => array( - 'pretty_version' => '1.6.2', - 'version' => '1.6.2.0', - 'reference' => '48f445a408c131e38cab1c235aa6d2bb7a0bb20d', + 'pretty_version' => '1.7.1', + 'version' => '1.7.1.0', + 'reference' => 'dfc078e8af9c99210337325ff5aa152872c98714', 'type' => 'library', 'install_path' => __DIR__ . '/../phpdocumentor/type-resolver', 'aliases' => array(), @@ -187,19 +181,28 @@ 'aliases' => array(), 'dev_requirement' => true, ), + 'phpstan/phpdoc-parser' => array( + 'pretty_version' => '1.16.1', + 'version' => '1.16.1.0', + 'reference' => 'e27e92d939e2e3636f0a1f0afaba59692c0bf571', + 'type' => 'library', + 'install_path' => __DIR__ . '/../phpstan/phpdoc-parser', + 'aliases' => array(), + 'dev_requirement' => true, + ), 'phpstan/phpstan' => array( - 'pretty_version' => '1.10.5', - 'version' => '1.10.5.0', - 'reference' => '1fb6f494d82455151ecf15c5c191923f5d84324e', + 'pretty_version' => '1.10.8', + 'version' => '1.10.8.0', + 'reference' => '0166aef76e066f0dd2adc2799bdadfa1635711e9', 'type' => 'library', 'install_path' => __DIR__ . '/../phpstan/phpstan', 'aliases' => array(), 'dev_requirement' => true, ), 'phpstan/phpstan-deprecation-rules' => array( - 'pretty_version' => '1.1.2', - 'version' => '1.1.2.0', - 'reference' => 'bcc1e8cdf81c3da1a2ba9188ee94cd7e2a62e865', + 'pretty_version' => '1.1.3', + 'version' => '1.1.3.0', + 'reference' => 'a22b36b955a2e9a3d39fe533b6c1bb5359f9c319', 'type' => 'phpstan-extension', 'install_path' => __DIR__ . '/../phpstan/phpstan-deprecation-rules', 'aliases' => array(), @@ -208,7 +211,7 @@ 'psalm/psalm' => array( 'dev_requirement' => true, 'provided' => array( - 0 => '5.7.7', + 0 => '5.8.0', ), ), 'psr/container' => array( @@ -245,9 +248,9 @@ 'dev_requirement' => true, ), 'sebastian/diff' => array( - 'pretty_version' => '5.0.0', - 'version' => '5.0.0.0', - 'reference' => '70dd1b20bc198da394ad542e988381b44e64e39f', + 'pretty_version' => '5.0.1', + 'version' => '5.0.1.0', + 'reference' => 'aae9a0a43bff37bd5d8d0311426c87bf36153f02', 'type' => 'library', 'install_path' => __DIR__ . '/../sebastian/diff', 'aliases' => array(), @@ -362,9 +365,9 @@ 'dev_requirement' => true, ), 'vimeo/psalm' => array( - 'pretty_version' => '5.7.7', - 'version' => '5.7.7.0', - 'reference' => 'e028ba46ba0d7f9a78bc3201c251e137383e145f', + 'pretty_version' => '5.8.0', + 'version' => '5.8.0.0', + 'reference' => '9cf4f60a333f779ad3bc704a555920e81d4fdcda', 'type' => 'library', 'install_path' => __DIR__ . '/../vimeo/psalm', 'aliases' => array(), diff --git a/vendor/composer/package-versions-deprecated/CHANGELOG.md b/vendor/composer/package-versions-deprecated/CHANGELOG.md deleted file mode 100644 index a838c56a..00000000 --- a/vendor/composer/package-versions-deprecated/CHANGELOG.md +++ /dev/null @@ -1,120 +0,0 @@ -# CHANGELOG - -## 1.1.3 - 2017-09-06 - -This release fixes a bug that caused PackageVersions to prevent -the `composer remove` and `composer update` commands to fail when -this package is removed. - -In addition to that, mutation testing has been added to the suite, -ensuring that the package is accurately and extensively tested. - -Total issues resolved: **3** - -- [40: Mutation testing, PHP 7.1 testing](https://github.com/Ocramius/PackageVersions/pull/40) thanks to @Ocramius -- [41: Removing this package on install results in file access error](https://github.com/Ocramius/PackageVersions/issues/41) thanks to @Xerkus -- [46: #41 Avoid issues when the package is scheduled for removal](https://github.com/Ocramius/PackageVersions/pull/46) thanks to @Jean85 - -## 1.1.2 - 2016-12-30 - -This release fixes a bug that caused PackageVersions to be enabled -even when it was part of a globally installed package. - -Total issues resolved: **3** - -- [35: remove all temp directories](https://github.com/Ocramius/PackageVersions/pull/35) -- [38: Interferes with other projects when installed globally](https://github.com/Ocramius/PackageVersions/issues/38) -- [39: Ignore the global plugin when updating local projects](https://github.com/Ocramius/PackageVersions/pull/39) - -## 1.1.1 - 2016-07-25 - -This release removes the [`"files"`](https://getcomposer.org/doc/04-schema.md#files) directive from -[`composer.json`](https://github.com/Ocramius/PackageVersions/commit/86f2636f7c5e7b56fa035fa3826d5fcf80b6dc72), -as it is no longer needed for `composer install --classmap-authoritative`. -Also, that directive was causing issues with HHVM installations, since -PackageVersions is not compatible with it. - -Total issues resolved: **1** - -- [34: Fatal error during travis build after update to 1.1.0](https://github.com/Ocramius/PackageVersions/issues/34) - -## 1.1.0 - 2016-07-22 - -This release introduces support for running `composer install --classmap-authoritative` -and `composer install --no-scripts`. Please note that performance -while using these modes may be degraded, but the package will -still work. - -Additionally, the package was tuned to prevent the plugin from -running twice at installation. - -Total issues resolved: **10** - -- [18: Fails when using composer install --no-scripts](https://github.com/Ocramius/PackageVersions/issues/18) -- [20: CS (spacing)](https://github.com/Ocramius/PackageVersions/pull/20) -- [22: Document the way the require-dev section is treated](https://github.com/Ocramius/PackageVersions/issues/22) -- [23: Underline that composer.lock is used as source of information](https://github.com/Ocramius/PackageVersions/pull/23) -- [27: Fix incompatibility with --classmap-authoritative](https://github.com/Ocramius/PackageVersions/pull/27) -- [29: mention optimize-autoloader composer.json config option in README](https://github.com/Ocramius/PackageVersions/pull/29) -- [30: The version class is generated twice during composer update](https://github.com/Ocramius/PackageVersions/issues/30) -- [31: Remove double registration of the event listeners](https://github.com/Ocramius/PackageVersions/pull/31) -- [32: Update the usage of mock APIs to use the new API](https://github.com/Ocramius/PackageVersions/pull/32) -- [33: Fix for #18 - support running with --no-scripts flag](https://github.com/Ocramius/PackageVersions/pull/33) - -## 1.0.4 - 2016-04-23 - -This release includes a fix/workaround for composer/composer#5237, -which causes `ocramius/package-versions` to sometimes generate a -`Versions` class with malformed name (something like -`Versions_composer_tmp0`) when running `composer require `. - -Total issues resolved: **2** - -- [16: Workaround for composer/composer#5237 - class parsing](https://github.com/Ocramius/PackageVersions/pull/16) -- [17: Weird Class name being generated](https://github.com/Ocramius/PackageVersions/issues/17) - -## 1.0.3 - 2016-02-26 - -This release fixes an issue related to concurrent autoloader -re-generation caused by multiple composer plugins being installed. -The issue was solved by removing autoloader re-generation from this -package, but it may still affect other packages. - -It is now recommended that you run `composer dump-autoload --optimize` -after installation when using this particular package. -Please note that `composer (install|update) -o` is not sufficient -to avoid autoload overhead when using this particular package. - -Total issues resolved: **1** - -- [15: Remove autoload re-dump optimization](https://github.com/Ocramius/PackageVersions/pull/15) - -## 1.0.2 - 2016-02-24 - -This release fixes issues related to installing the component without -any dev dependencies or with packages that don't have a source or dist -reference, which is usual with packages defined directly in the -`composer.json`. - -Total issues resolved: **3** - -- [11: fix composer install --no-dev PHP7](https://github.com/Ocramius/PackageVersions/pull/11) -- [12: Packages don't always have a source/reference](https://github.com/Ocramius/PackageVersions/issues/12) -- [13: Fix #12 - support dist and missing package version references](https://github.com/Ocramius/PackageVersions/pull/13) - -## 1.0.1 - 2016-02-01 - -This release fixes an issue related with composer updates to -already installed versions. -Using `composer require` within a package that already used -`ocramius/package-versions` caused the installation to be unable -to write the `PackageVersions\Versions` class to a file. - -Total issues resolved: **6** - -- [2: remove unused use statement](https://github.com/Ocramius/PackageVersions/pull/2) -- [3: Remove useless files from dist package](https://github.com/Ocramius/PackageVersions/pull/3) -- [5: failed to open stream: phar error: write operations disabled by the php.ini setting phar.readonly](https://github.com/Ocramius/PackageVersions/issues/5) -- [6: Fix/#5 use composer vendor dir](https://github.com/Ocramius/PackageVersions/pull/6) -- [7: Hotfix - #5 generate package versions also when in phar context](https://github.com/Ocramius/PackageVersions/pull/7) -- [8: Versions class should be ignored by VCS, as it is an install-time artifact](https://github.com/Ocramius/PackageVersions/pull/8) diff --git a/vendor/composer/package-versions-deprecated/CONTRIBUTING.md b/vendor/composer/package-versions-deprecated/CONTRIBUTING.md deleted file mode 100644 index 71806175..00000000 --- a/vendor/composer/package-versions-deprecated/CONTRIBUTING.md +++ /dev/null @@ -1,39 +0,0 @@ ---- -title: Contributing ---- - -# Contributing - - * Coding standard for the project is [PSR-2](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md) - * The project will follow strict [object calisthenics](http://www.slideshare.net/guilhermeblanco/object-calisthenics-applied-to-php) - * Any contribution must provide tests for additional introduced conditions - * Any un-confirmed issue needs a failing test case before being accepted - * Pull requests must be sent from a new hotfix/feature branch, not from `master`. - -## Installation - -To install the project and run the tests, you need to clone it first: - -```sh -$ git clone git://github.com/Ocramius/PackageVersions.git -``` - -You will then need to run a composer installation: - -```sh -$ cd PackageVersions -$ curl -s https://getcomposer.org/installer | php -$ php composer.phar update -``` - -## Testing - -The PHPUnit version to be used is the one installed as a dev- dependency via composer: - -```sh -$ ./vendor/bin/phpunit -``` - -Accepted coverage for new contributions is 80%. Any contribution not satisfying this requirement -won't be merged. - diff --git a/vendor/composer/package-versions-deprecated/README.md b/vendor/composer/package-versions-deprecated/README.md deleted file mode 100644 index 8bea9d41..00000000 --- a/vendor/composer/package-versions-deprecated/README.md +++ /dev/null @@ -1,7 +0,0 @@ -# Package Versions - -**`composer/package-versions-deprecated` is a fully-compatible fork of [`ocramius/package-versions`](https://github.com/Ocramius/PackageVersions)** which provides compatibility with Composer 1 and 2 on PHP 7+. It replaces ocramius/package-versions so if you have a dependency requiring it and you want to use Composer v2 but can not upgrade to PHP 7.4 just yet, you can require this package instead. - -If you have a **direct** dependency on `ocramius/package-versions`, we recommend that once you migrated to Composer 2.x you also migrate to use the [`Composer\InstalledVersions`](https://getcomposer.org/doc/07-runtime.md#installed-versions) class which offers the functionality present here out of the box. You can then remove the require on this package. - -This package is EOL / deprecated and you should aim to migrate away from it as soon as possible! diff --git a/vendor/composer/package-versions-deprecated/SECURITY.md b/vendor/composer/package-versions-deprecated/SECURITY.md deleted file mode 100644 index da9c516d..00000000 --- a/vendor/composer/package-versions-deprecated/SECURITY.md +++ /dev/null @@ -1,5 +0,0 @@ -## Security contact information - -To report a security vulnerability, please use the -[Tidelift security contact](https://tidelift.com/security). -Tidelift will coordinate the fix and disclosure. diff --git a/vendor/composer/package-versions-deprecated/composer.json b/vendor/composer/package-versions-deprecated/composer.json deleted file mode 100644 index d5a40daa..00000000 --- a/vendor/composer/package-versions-deprecated/composer.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "name": "composer/package-versions-deprecated", - "description": "Composer plugin that provides efficient querying for installed package versions (no runtime IO)", - "type": "composer-plugin", - "license": "MIT", - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com" - }, - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be" - } - ], - "require": { - "php": "^7 || ^8", - "composer-plugin-api": "^1.1.0 || ^2.0" - }, - "replace": { - "ocramius/package-versions": "1.11.99" - }, - "require-dev": { - "phpunit/phpunit": "^6.5 || ^7", - "composer/composer": "^1.9.3 || ^2.0@dev", - "ext-zip": "^1.13" - }, - "autoload": { - "psr-4": { - "PackageVersions\\": "src/PackageVersions" - } - }, - "autoload-dev": { - "psr-4": { - "PackageVersionsTest\\": "test/PackageVersionsTest" - } - }, - "extra": { - "class": "PackageVersions\\Installer", - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "scripts": { - "post-update-cmd": "PackageVersions\\Installer::dumpVersionsClass", - "post-install-cmd": "PackageVersions\\Installer::dumpVersionsClass" - } -} diff --git a/vendor/composer/package-versions-deprecated/composer.lock b/vendor/composer/package-versions-deprecated/composer.lock deleted file mode 100644 index b711f6b1..00000000 --- a/vendor/composer/package-versions-deprecated/composer.lock +++ /dev/null @@ -1,2603 +0,0 @@ -{ - "_readme": [ - "This file locks the dependencies of your project to a known state", - "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", - "This file is @generated automatically" - ], - "content-hash": "6bfe0a7d7a51c4bdf14a2d7ea1d22d11", - "packages": [], - "packages-dev": [ - { - "name": "composer/ca-bundle", - "version": "1.2.7", - "source": { - "type": "git", - "url": "https://github.com/composer/ca-bundle.git", - "reference": "95c63ab2117a72f48f5a55da9740a3273d45b7fd" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/ca-bundle/zipball/95c63ab2117a72f48f5a55da9740a3273d45b7fd", - "reference": "95c63ab2117a72f48f5a55da9740a3273d45b7fd", - "shasum": "" - }, - "require": { - "ext-openssl": "*", - "ext-pcre": "*", - "php": "^5.3.2 || ^7.0 || ^8.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8", - "psr/log": "^1.0", - "symfony/process": "^2.5 || ^3.0 || ^4.0 || ^5.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Composer\\CaBundle\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - } - ], - "description": "Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.", - "keywords": [ - "cabundle", - "cacert", - "certificate", - "ssl", - "tls" - ], - "funding": [ - { - "url": "https://packagist.com", - "type": "custom" - }, - { - "url": "https://tidelift.com/funding/github/packagist/composer/composer", - "type": "tidelift" - } - ], - "time": "2020-04-08T08:27:21+00:00" - }, - { - "name": "composer/composer", - "version": "dev-master", - "source": { - "type": "git", - "url": "https://github.com/composer/composer.git", - "reference": "a8c105da344dd84ebd5d11be7943a45b09dc076f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/composer/zipball/a8c105da344dd84ebd5d11be7943a45b09dc076f", - "reference": "a8c105da344dd84ebd5d11be7943a45b09dc076f", - "shasum": "" - }, - "require": { - "composer/ca-bundle": "^1.0", - "composer/semver": "^1.0", - "composer/spdx-licenses": "^1.2", - "composer/xdebug-handler": "^1.1", - "justinrainbow/json-schema": "^3.0 || ^4.0 || ^5.0", - "php": "^5.3.2 || ^7.0", - "psr/log": "^1.0", - "seld/jsonlint": "^1.4", - "seld/phar-utils": "^1.0", - "symfony/console": "^2.7 || ^3.0 || ^4.0 || ^5.0", - "symfony/filesystem": "^2.7 || ^3.0 || ^4.0 || ^5.0", - "symfony/finder": "^2.7 || ^3.0 || ^4.0 || ^5.0", - "symfony/process": "^2.7 || ^3.0 || ^4.0 || ^5.0" - }, - "conflict": { - "symfony/console": "2.8.38" - }, - "require-dev": { - "phpspec/prophecy": "^1.10", - "symfony/phpunit-bridge": "^3.4" - }, - "suggest": { - "ext-openssl": "Enabling the openssl extension allows you to access https URLs for repositories and packages", - "ext-zip": "Enabling the zip extension allows you to unzip archives", - "ext-zlib": "Allow gzip compression of HTTP requests" - }, - "bin": [ - "bin/composer" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.10-dev" - } - }, - "autoload": { - "psr-4": { - "Composer\\": "src/Composer" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nils Adermann", - "email": "naderman@naderman.de", - "homepage": "http://www.naderman.de" - }, - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - } - ], - "description": "Composer helps you declare, manage and install dependencies of PHP projects. It ensures you have the right stack everywhere.", - "homepage": "https://getcomposer.org/", - "keywords": [ - "autoload", - "dependency", - "package" - ], - "support": { - "irc": "irc://irc.freenode.org/composer", - "issues": "https://github.com/composer/composer/issues", - "source": "https://github.com/composer/composer/tree/master" - }, - "funding": [ - { - "url": "https://packagist.com", - "type": "custom" - }, - { - "url": "https://tidelift.com/funding/github/packagist/composer/composer", - "type": "tidelift" - } - ], - "time": "2020-03-29T14:59:26+00:00" - }, - { - "name": "composer/semver", - "version": "1.5.1", - "source": { - "type": "git", - "url": "https://github.com/composer/semver.git", - "reference": "c6bea70230ef4dd483e6bbcab6005f682ed3a8de" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/c6bea70230ef4dd483e6bbcab6005f682ed3a8de", - "reference": "c6bea70230ef4dd483e6bbcab6005f682ed3a8de", - "shasum": "" - }, - "require": { - "php": "^5.3.2 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.5 || ^5.0.5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Composer\\Semver\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nils Adermann", - "email": "naderman@naderman.de", - "homepage": "http://www.naderman.de" - }, - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - }, - { - "name": "Rob Bast", - "email": "rob.bast@gmail.com", - "homepage": "http://robbast.nl" - } - ], - "description": "Semver library that offers utilities, version constraint parsing and validation.", - "keywords": [ - "semantic", - "semver", - "validation", - "versioning" - ], - "support": { - "irc": "irc://irc.freenode.org/composer", - "issues": "https://github.com/composer/semver/issues", - "source": "https://github.com/composer/semver/tree/1.5.1" - }, - "time": "2020-01-13T12:06:48+00:00" - }, - { - "name": "composer/spdx-licenses", - "version": "1.5.3", - "source": { - "type": "git", - "url": "https://github.com/composer/spdx-licenses.git", - "reference": "0c3e51e1880ca149682332770e25977c70cf9dae" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/spdx-licenses/zipball/0c3e51e1880ca149682332770e25977c70cf9dae", - "reference": "0c3e51e1880ca149682332770e25977c70cf9dae", - "shasum": "" - }, - "require": { - "php": "^5.3.2 || ^7.0 || ^8.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 7" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Composer\\Spdx\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nils Adermann", - "email": "naderman@naderman.de", - "homepage": "http://www.naderman.de" - }, - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - }, - { - "name": "Rob Bast", - "email": "rob.bast@gmail.com", - "homepage": "http://robbast.nl" - } - ], - "description": "SPDX licenses list and validation library.", - "keywords": [ - "license", - "spdx", - "validator" - ], - "time": "2020-02-14T07:44:31+00:00" - }, - { - "name": "composer/xdebug-handler", - "version": "1.4.1", - "source": { - "type": "git", - "url": "https://github.com/composer/xdebug-handler.git", - "reference": "1ab9842d69e64fb3a01be6b656501032d1b78cb7" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/1ab9842d69e64fb3a01be6b656501032d1b78cb7", - "reference": "1ab9842d69e64fb3a01be6b656501032d1b78cb7", - "shasum": "" - }, - "require": { - "php": "^5.3.2 || ^7.0 || ^8.0", - "psr/log": "^1.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8" - }, - "type": "library", - "autoload": { - "psr-4": { - "Composer\\XdebugHandler\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "John Stevenson", - "email": "john-stevenson@blueyonder.co.uk" - } - ], - "description": "Restarts a process without Xdebug.", - "keywords": [ - "Xdebug", - "performance" - ], - "support": { - "irc": "irc://irc.freenode.org/composer", - "issues": "https://github.com/composer/xdebug-handler/issues", - "source": "https://github.com/composer/xdebug-handler/tree/master" - }, - "funding": [ - { - "url": "https://packagist.com", - "type": "custom" - } - ], - "time": "2020-03-01T12:26:26+00:00" - }, - { - "name": "doctrine/instantiator", - "version": "1.3.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/instantiator.git", - "reference": "ae466f726242e637cebdd526a7d991b9433bacf1" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/ae466f726242e637cebdd526a7d991b9433bacf1", - "reference": "ae466f726242e637cebdd526a7d991b9433bacf1", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "doctrine/coding-standard": "^6.0", - "ext-pdo": "*", - "ext-phar": "*", - "phpbench/phpbench": "^0.13", - "phpstan/phpstan-phpunit": "^0.11", - "phpstan/phpstan-shim": "^0.11", - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/" - } - ], - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://www.doctrine-project.org/projects/instantiator.html", - "keywords": [ - "constructor", - "instantiate" - ], - "support": { - "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/master" - }, - "time": "2019-10-21T16:45:58+00:00" - }, - { - "name": "justinrainbow/json-schema", - "version": "5.2.9", - "source": { - "type": "git", - "url": "https://github.com/justinrainbow/json-schema.git", - "reference": "44c6787311242a979fa15c704327c20e7221a0e4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/justinrainbow/json-schema/zipball/44c6787311242a979fa15c704327c20e7221a0e4", - "reference": "44c6787311242a979fa15c704327c20e7221a0e4", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "friendsofphp/php-cs-fixer": "~2.2.20||~2.15.1", - "json-schema/json-schema-test-suite": "1.2.0", - "phpunit/phpunit": "^4.8.35" - }, - "bin": [ - "bin/validate-json" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "JsonSchema\\": "src/JsonSchema/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bruno Prieto Reis", - "email": "bruno.p.reis@gmail.com" - }, - { - "name": "Justin Rainbow", - "email": "justin.rainbow@gmail.com" - }, - { - "name": "Igor Wiedler", - "email": "igor@wiedler.ch" - }, - { - "name": "Robert Schönthal", - "email": "seroscho@googlemail.com" - } - ], - "description": "A library to validate a json schema.", - "homepage": "https://github.com/justinrainbow/json-schema", - "keywords": [ - "json", - "schema" - ], - "support": { - "issues": "https://github.com/justinrainbow/json-schema/issues", - "source": "https://github.com/justinrainbow/json-schema/tree/5.2.9" - }, - "time": "2019-09-25T14:49:45+00:00" - }, - { - "name": "myclabs/deep-copy", - "version": "1.9.5", - "source": { - "type": "git", - "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "b2c28789e80a97badd14145fda39b545d83ca3ef" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/b2c28789e80a97badd14145fda39b545d83ca3ef", - "reference": "b2c28789e80a97badd14145fda39b545d83ca3ef", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "replace": { - "myclabs/deep-copy": "self.version" - }, - "require-dev": { - "doctrine/collections": "^1.0", - "doctrine/common": "^2.6", - "phpunit/phpunit": "^7.1" - }, - "type": "library", - "autoload": { - "psr-4": { - "DeepCopy\\": "src/DeepCopy/" - }, - "files": [ - "src/DeepCopy/deep_copy.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "Create deep copies (clones) of your objects", - "keywords": [ - "clone", - "copy", - "duplicate", - "object", - "object graph" - ], - "support": { - "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.9.5" - }, - "time": "2020-01-17T21:11:47+00:00" - }, - { - "name": "phar-io/manifest", - "version": "1.0.3", - "source": { - "type": "git", - "url": "https://github.com/phar-io/manifest.git", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phar-io/manifest/zipball/7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", - "shasum": "" - }, - "require": { - "ext-dom": "*", - "ext-phar": "*", - "phar-io/version": "^2.0", - "php": "^5.6 || ^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Arne Blankerts", - "email": "arne@blankerts.de", - "role": "Developer" - }, - { - "name": "Sebastian Heuer", - "email": "sebastian@phpeople.de", - "role": "Developer" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "Developer" - } - ], - "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", - "time": "2018-07-08T19:23:20+00:00" - }, - { - "name": "phar-io/version", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/phar-io/version.git", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/45a2ec53a73c70ce41d55cedef9063630abaf1b6", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Arne Blankerts", - "email": "arne@blankerts.de", - "role": "Developer" - }, - { - "name": "Sebastian Heuer", - "email": "sebastian@phpeople.de", - "role": "Developer" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "Developer" - } - ], - "description": "Library for handling version information and constraints", - "time": "2018-07-08T19:19:57+00:00" - }, - { - "name": "phpdocumentor/reflection-common", - "version": "2.0.0", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "63a995caa1ca9e5590304cd845c15ad6d482a62a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/63a995caa1ca9e5590304cd845c15ad6d482a62a", - "reference": "63a995caa1ca9e5590304cd845c15ad6d482a62a", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "require-dev": { - "phpunit/phpunit": "~6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "Common reflection classes used by phpdocumentor to reflect the code structure", - "homepage": "http://www.phpdoc.org", - "time": "2018-08-07T13:53:10+00:00" - }, - { - "name": "phpdocumentor/reflection-docblock", - "version": "5.1.0", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "cd72d394ca794d3466a3b2fc09d5a6c1dc86b47e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/cd72d394ca794d3466a3b2fc09d5a6c1dc86b47e", - "reference": "cd72d394ca794d3466a3b2fc09d5a6c1dc86b47e", - "shasum": "" - }, - "require": { - "ext-filter": "^7.1", - "php": "^7.2", - "phpdocumentor/reflection-common": "^2.0", - "phpdocumentor/type-resolver": "^1.0", - "webmozart/assert": "^1" - }, - "require-dev": { - "doctrine/instantiator": "^1", - "mockery/mockery": "^1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" - }, - { - "name": "Jaap van Otterdijk", - "email": "account@ijaap.nl" - } - ], - "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2020-02-22T12:28:44+00:00" - }, - { - "name": "phpdocumentor/type-resolver", - "version": "1.1.0", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "7462d5f123dfc080dfdf26897032a6513644fc95" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/7462d5f123dfc080dfdf26897032a6513644fc95", - "reference": "7462d5f123dfc080dfdf26897032a6513644fc95", - "shasum": "" - }, - "require": { - "php": "^7.2", - "phpdocumentor/reflection-common": "^2.0" - }, - "require-dev": { - "ext-tokenizer": "^7.2", - "mockery/mockery": "~1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" - } - ], - "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", - "support": { - "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/master" - }, - "time": "2020-02-18T18:59:58+00:00" - }, - { - "name": "phpspec/prophecy", - "version": "v1.10.3", - "source": { - "type": "git", - "url": "https://github.com/phpspec/prophecy.git", - "reference": "451c3cd1418cf640de218914901e51b064abb093" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/451c3cd1418cf640de218914901e51b064abb093", - "reference": "451c3cd1418cf640de218914901e51b064abb093", - "shasum": "" - }, - "require": { - "doctrine/instantiator": "^1.0.2", - "php": "^5.3|^7.0", - "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0|^5.0", - "sebastian/comparator": "^1.2.3|^2.0|^3.0|^4.0", - "sebastian/recursion-context": "^1.0|^2.0|^3.0|^4.0" - }, - "require-dev": { - "phpspec/phpspec": "^2.5 || ^3.2", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5 || ^7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.10.x-dev" - } - }, - "autoload": { - "psr-4": { - "Prophecy\\": "src/Prophecy" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com", - "homepage": "http://everzet.com" - }, - { - "name": "Marcello Duarte", - "email": "marcello.duarte@gmail.com" - } - ], - "description": "Highly opinionated mocking framework for PHP 5.3+", - "homepage": "https://github.com/phpspec/prophecy", - "keywords": [ - "Double", - "Dummy", - "fake", - "mock", - "spy", - "stub" - ], - "support": { - "issues": "https://github.com/phpspec/prophecy/issues", - "source": "https://github.com/phpspec/prophecy/tree/v1.10.3" - }, - "time": "2020-03-05T15:02:03+00:00" - }, - { - "name": "phpunit/php-code-coverage", - "version": "6.1.4", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", - "shasum": "" - }, - "require": { - "ext-dom": "*", - "ext-xmlwriter": "*", - "php": "^7.1", - "phpunit/php-file-iterator": "^2.0", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.0", - "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^3.1 || ^4.0", - "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.0" - }, - "suggest": { - "ext-xdebug": "^2.6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "6.1-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", - "homepage": "https://github.com/sebastianbergmann/php-code-coverage", - "keywords": [ - "coverage", - "testing", - "xunit" - ], - "time": "2018-10-31T16:06:48+00:00" - }, - { - "name": "phpunit/php-file-iterator", - "version": "2.0.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "050bedf145a257b1ff02746c31894800e5122946" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/050bedf145a257b1ff02746c31894800e5122946", - "reference": "050bedf145a257b1ff02746c31894800e5122946", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "FilterIterator implementation that filters files based on a list of suffixes.", - "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", - "keywords": [ - "filesystem", - "iterator" - ], - "time": "2018-09-13T20:33:42+00:00" - }, - { - "name": "phpunit/php-text-template", - "version": "1.2.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Simple template engine.", - "homepage": "https://github.com/sebastianbergmann/php-text-template/", - "keywords": [ - "template" - ], - "time": "2015-06-21T13:50:34+00:00" - }, - { - "name": "phpunit/php-timer", - "version": "2.1.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/1038454804406b0b5f5f520358e78c1c2f71501e", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.1-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Utility class for timing", - "homepage": "https://github.com/sebastianbergmann/php-timer/", - "keywords": [ - "timer" - ], - "time": "2019-06-07T04:22:29+00:00" - }, - { - "name": "phpunit/php-token-stream", - "version": "3.1.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/995192df77f63a59e47f025390d2d1fdf8f425ff", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.1-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ], - "time": "2019-09-17T06:23:10+00:00" - }, - { - "name": "phpunit/phpunit", - "version": "7.5.20", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "9467db479d1b0487c99733bb1e7944d32deded2c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/9467db479d1b0487c99733bb1e7944d32deded2c", - "reference": "9467db479d1b0487c99733bb1e7944d32deded2c", - "shasum": "" - }, - "require": { - "doctrine/instantiator": "^1.1", - "ext-dom": "*", - "ext-json": "*", - "ext-libxml": "*", - "ext-mbstring": "*", - "ext-xml": "*", - "myclabs/deep-copy": "^1.7", - "phar-io/manifest": "^1.0.2", - "phar-io/version": "^2.0", - "php": "^7.1", - "phpspec/prophecy": "^1.7", - "phpunit/php-code-coverage": "^6.0.7", - "phpunit/php-file-iterator": "^2.0.1", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1", - "sebastian/comparator": "^3.0", - "sebastian/diff": "^3.0", - "sebastian/environment": "^4.0", - "sebastian/exporter": "^3.1", - "sebastian/global-state": "^2.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0", - "sebastian/version": "^2.0.1" - }, - "conflict": { - "phpunit/phpunit-mock-objects": "*" - }, - "require-dev": { - "ext-pdo": "*" - }, - "suggest": { - "ext-soap": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0" - }, - "bin": [ - "phpunit" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "7.5-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "The PHP Unit Testing framework.", - "homepage": "https://phpunit.de/", - "keywords": [ - "phpunit", - "testing", - "xunit" - ], - "time": "2020-01-08T08:45:45+00:00" - }, - { - "name": "psr/container", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/php-fig/container.git", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/container/zipball/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Container\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common Container Interface (PHP FIG PSR-11)", - "homepage": "https://github.com/php-fig/container", - "keywords": [ - "PSR-11", - "container", - "container-interface", - "container-interop", - "psr" - ], - "time": "2017-02-14T16:28:37+00:00" - }, - { - "name": "psr/log", - "version": "1.1.3", - "source": { - "type": "git", - "url": "https://github.com/php-fig/log.git", - "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/0f73288fd15629204f9d42b7055f72dacbe811fc", - "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Log\\": "Psr/Log/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interface for logging libraries", - "homepage": "https://github.com/php-fig/log", - "keywords": [ - "log", - "psr", - "psr-3" - ], - "time": "2020-03-23T09:12:05+00:00" - }, - { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Looks up which function or method a line of code belongs to", - "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2017-03-04T06:30:41+00:00" - }, - { - "name": "sebastian/comparator", - "version": "3.0.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/5de4fc177adf9bce8df98d8d141a7559d7ccf6da", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da", - "shasum": "" - }, - "require": { - "php": "^7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides the functionality to compare PHP values for equality", - "homepage": "https://github.com/sebastianbergmann/comparator", - "keywords": [ - "comparator", - "compare", - "equality" - ], - "time": "2018-07-12T15:12:46+00:00" - }, - { - "name": "sebastian/diff", - "version": "3.0.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/720fcc7e9b5cf384ea68d9d930d480907a0c1a29", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Diff implementation", - "homepage": "https://github.com/sebastianbergmann/diff", - "keywords": [ - "diff", - "udiff", - "unidiff", - "unified diff" - ], - "time": "2019-02-04T06:01:07+00:00" - }, - { - "name": "sebastian/environment", - "version": "4.2.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/464c90d7bdf5ad4e8a6aea15c091fec0603d4368", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.5" - }, - "suggest": { - "ext-posix": "*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.2-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", - "keywords": [ - "Xdebug", - "environment", - "hhvm" - ], - "time": "2019-11-20T08:46:58+00:00" - }, - { - "name": "sebastian/exporter", - "version": "3.1.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/68609e1261d215ea5b21b7987539cbfbe156ec3e", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e", - "shasum": "" - }, - "require": { - "php": "^7.0", - "sebastian/recursion-context": "^3.0" - }, - "require-dev": { - "ext-mbstring": "*", - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.1.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", - "keywords": [ - "export", - "exporter" - ], - "time": "2019-09-14T09:02:43+00:00" - }, - { - "name": "sebastian/global-state", - "version": "2.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", - "shasum": "" - }, - "require": { - "php": "^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "suggest": { - "ext-uopz": "*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Snapshotting of global state", - "homepage": "http://www.github.com/sebastianbergmann/global-state", - "keywords": [ - "global state" - ], - "time": "2017-04-27T15:39:26+00:00" - }, - { - "name": "sebastian/object-enumerator", - "version": "3.0.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/7cfd9e65d11ffb5af41198476395774d4c8a84c5", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5", - "shasum": "" - }, - "require": { - "php": "^7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Traverses array structures and object graphs to enumerate all referenced objects", - "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-08-03T12:35:26+00:00" - }, - { - "name": "sebastian/object-reflector", - "version": "1.1.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "773f97c67f28de00d397be301821b06708fca0be" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/773f97c67f28de00d397be301821b06708fca0be", - "reference": "773f97c67f28de00d397be301821b06708fca0be", - "shasum": "" - }, - "require": { - "php": "^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Allows reflection of object attributes, including inherited and non-public ones", - "homepage": "https://github.com/sebastianbergmann/object-reflector/", - "time": "2017-03-29T09:07:27+00:00" - }, - { - "name": "sebastian/recursion-context", - "version": "3.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", - "shasum": "" - }, - "require": { - "php": "^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" - } - ], - "description": "Provides functionality to recursively process PHP variables", - "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2017-03-03T06:23:57+00:00" - }, - { - "name": "sebastian/resource-operations", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/4d7a795d35b889bf80a0cc04e08d77cedfa917a9", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides a list of PHP built-in functions that operate on resources", - "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2018-10-04T04:07:39+00:00" - }, - { - "name": "sebastian/version", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", - "shasum": "" - }, - "require": { - "php": ">=5.6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Library that helps with managing the version number of Git-hosted PHP projects", - "homepage": "https://github.com/sebastianbergmann/version", - "time": "2016-10-03T07:35:21+00:00" - }, - { - "name": "seld/jsonlint", - "version": "1.7.2", - "source": { - "type": "git", - "url": "https://github.com/Seldaek/jsonlint.git", - "reference": "e2e5d290e4d2a4f0eb449f510071392e00e10d19" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Seldaek/jsonlint/zipball/e2e5d290e4d2a4f0eb449f510071392e00e10d19", - "reference": "e2e5d290e4d2a4f0eb449f510071392e00e10d19", - "shasum": "" - }, - "require": { - "php": "^5.3 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0" - }, - "bin": [ - "bin/jsonlint" - ], - "type": "library", - "autoload": { - "psr-4": { - "Seld\\JsonLint\\": "src/Seld/JsonLint/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - } - ], - "description": "JSON Linter", - "keywords": [ - "json", - "linter", - "parser", - "validator" - ], - "support": { - "issues": "https://github.com/Seldaek/jsonlint/issues", - "source": "https://github.com/Seldaek/jsonlint/tree/1.7.2" - }, - "time": "2019-10-24T14:27:39+00:00" - }, - { - "name": "seld/phar-utils", - "version": "1.1.0", - "source": { - "type": "git", - "url": "https://github.com/Seldaek/phar-utils.git", - "reference": "8800503d56b9867d43d9c303b9cbcc26016e82f0" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Seldaek/phar-utils/zipball/8800503d56b9867d43d9c303b9cbcc26016e82f0", - "reference": "8800503d56b9867d43d9c303b9cbcc26016e82f0", - "shasum": "" - }, - "require": { - "php": ">=5.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Seld\\PharUtils\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be" - } - ], - "description": "PHAR file format utilities, for when PHP phars you up", - "keywords": [ - "phar" - ], - "support": { - "issues": "https://github.com/Seldaek/phar-utils/issues", - "source": "https://github.com/Seldaek/phar-utils/tree/1.1.0" - }, - "time": "2020-02-14T15:25:33+00:00" - }, - { - "name": "symfony/console", - "version": "v5.0.7", - "source": { - "type": "git", - "url": "https://github.com/symfony/console.git", - "reference": "5fa1caadc8cdaa17bcfb25219f3b53fe294a9935" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/5fa1caadc8cdaa17bcfb25219f3b53fe294a9935", - "reference": "5fa1caadc8cdaa17bcfb25219f3b53fe294a9935", - "shasum": "" - }, - "require": { - "php": "^7.2.5", - "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php73": "^1.8", - "symfony/service-contracts": "^1.1|^2" - }, - "conflict": { - "symfony/dependency-injection": "<4.4", - "symfony/event-dispatcher": "<4.4", - "symfony/lock": "<4.4", - "symfony/process": "<4.4" - }, - "provide": { - "psr/log-implementation": "1.0" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/config": "^4.4|^5.0", - "symfony/dependency-injection": "^4.4|^5.0", - "symfony/event-dispatcher": "^4.4|^5.0", - "symfony/lock": "^4.4|^5.0", - "symfony/process": "^4.4|^5.0", - "symfony/var-dumper": "^4.4|^5.0" - }, - "suggest": { - "psr/log": "For using the console logger", - "symfony/event-dispatcher": "", - "symfony/lock": "", - "symfony/process": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.0-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Console\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Console Component", - "homepage": "https://symfony.com", - "support": { - "source": "https://github.com/symfony/console/tree/v5.0.7" - }, - "time": "2020-03-30T11:42:42+00:00" - }, - { - "name": "symfony/filesystem", - "version": "v5.0.7", - "source": { - "type": "git", - "url": "https://github.com/symfony/filesystem.git", - "reference": "ca3b87dd09fff9b771731637f5379965fbfab420" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/ca3b87dd09fff9b771731637f5379965fbfab420", - "reference": "ca3b87dd09fff9b771731637f5379965fbfab420", - "shasum": "" - }, - "require": { - "php": "^7.2.5", - "symfony/polyfill-ctype": "~1.8" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.0-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Filesystem\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Filesystem Component", - "homepage": "https://symfony.com", - "support": { - "source": "https://github.com/symfony/filesystem/tree/v5.0.7" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2020-03-27T16:56:45+00:00" - }, - { - "name": "symfony/finder", - "version": "v5.0.7", - "source": { - "type": "git", - "url": "https://github.com/symfony/finder.git", - "reference": "600a52c29afc0d1caa74acbec8d3095ca7e9910d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/600a52c29afc0d1caa74acbec8d3095ca7e9910d", - "reference": "600a52c29afc0d1caa74acbec8d3095ca7e9910d", - "shasum": "" - }, - "require": { - "php": "^7.2.5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.0-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Finder\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Finder Component", - "homepage": "https://symfony.com", - "support": { - "source": "https://github.com/symfony/finder/tree/5.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2020-03-27T16:56:45+00:00" - }, - { - "name": "symfony/polyfill-ctype", - "version": "v1.15.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "4719fa9c18b0464d399f1a63bf624b42b6fa8d14" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/4719fa9c18b0464d399f1a63bf624b42b6fa8d14", - "reference": "4719fa9c18b0464d399f1a63bf624b42b6fa8d14", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-ctype": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Gert de Pagter", - "email": "BackEndTea@gmail.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for ctype functions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "ctype", - "polyfill", - "portable" - ], - "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.15.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2020-02-27T09:26:54+00:00" - }, - { - "name": "symfony/polyfill-mbstring", - "version": "v1.15.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "81ffd3a9c6d707be22e3012b827de1c9775fc5ac" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/81ffd3a9c6d707be22e3012b827de1c9775fc5ac", - "reference": "81ffd3a9c6d707be22e3012b827de1c9775fc5ac", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-mbstring": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for the Mbstring extension", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "mbstring", - "polyfill", - "portable", - "shim" - ], - "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.15.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2020-03-09T19:04:49+00:00" - }, - { - "name": "symfony/polyfill-php73", - "version": "v1.15.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "0f27e9f464ea3da33cbe7ca3bdf4eb66def9d0f7" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/0f27e9f464ea3da33cbe7ca3bdf4eb66def9d0f7", - "reference": "0f27e9f464ea3da33cbe7ca3bdf4eb66def9d0f7", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php73\\": "" - }, - "files": [ - "bootstrap.php" - ], - "classmap": [ - "Resources/stubs" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 7.3+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.15.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2020-02-27T09:26:54+00:00" - }, - { - "name": "symfony/process", - "version": "v5.0.7", - "source": { - "type": "git", - "url": "https://github.com/symfony/process.git", - "reference": "c5ca4a0fc16a0c888067d43fbcfe1f8a53d8e70e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/c5ca4a0fc16a0c888067d43fbcfe1f8a53d8e70e", - "reference": "c5ca4a0fc16a0c888067d43fbcfe1f8a53d8e70e", - "shasum": "" - }, - "require": { - "php": "^7.2.5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.0-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Process\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Process Component", - "homepage": "https://symfony.com", - "support": { - "source": "https://github.com/symfony/process/tree/v5.0.7" - }, - "time": "2020-03-27T16:56:45+00:00" - }, - { - "name": "symfony/service-contracts", - "version": "v2.0.1", - "source": { - "type": "git", - "url": "https://github.com/symfony/service-contracts.git", - "reference": "144c5e51266b281231e947b51223ba14acf1a749" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/144c5e51266b281231e947b51223ba14acf1a749", - "reference": "144c5e51266b281231e947b51223ba14acf1a749", - "shasum": "" - }, - "require": { - "php": "^7.2.5", - "psr/container": "^1.0" - }, - "suggest": { - "symfony/service-implementation": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Contracts\\Service\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Generic abstractions related to writing services", - "homepage": "https://symfony.com", - "keywords": [ - "abstractions", - "contracts", - "decoupling", - "interfaces", - "interoperability", - "standards" - ], - "support": { - "source": "https://github.com/symfony/service-contracts/tree/v2.0.1" - }, - "time": "2019-11-18T17:27:11+00:00" - }, - { - "name": "theseer/tokenizer", - "version": "1.1.3", - "source": { - "type": "git", - "url": "https://github.com/theseer/tokenizer.git", - "reference": "11336f6f84e16a720dae9d8e6ed5019efa85a0f9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/11336f6f84e16a720dae9d8e6ed5019efa85a0f9", - "reference": "11336f6f84e16a720dae9d8e6ed5019efa85a0f9", - "shasum": "" - }, - "require": { - "ext-dom": "*", - "ext-tokenizer": "*", - "ext-xmlwriter": "*", - "php": "^7.0" - }, - "type": "library", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Arne Blankerts", - "email": "arne@blankerts.de", - "role": "Developer" - } - ], - "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", - "time": "2019-06-13T22:48:21+00:00" - }, - { - "name": "webmozart/assert", - "version": "1.8.0", - "source": { - "type": "git", - "url": "https://github.com/webmozart/assert.git", - "reference": "ab2cb0b3b559010b75981b1bdce728da3ee90ad6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/ab2cb0b3b559010b75981b1bdce728da3ee90ad6", - "reference": "ab2cb0b3b559010b75981b1bdce728da3ee90ad6", - "shasum": "" - }, - "require": { - "php": "^5.3.3 || ^7.0", - "symfony/polyfill-ctype": "^1.8" - }, - "conflict": { - "vimeo/psalm": "<3.9.1" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.36 || ^7.5.13" - }, - "type": "library", - "autoload": { - "psr-4": { - "Webmozart\\Assert\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "Assertions to validate method input/output with nice error messages.", - "keywords": [ - "assert", - "check", - "validate" - ], - "support": { - "issues": "https://github.com/webmozart/assert/issues", - "source": "https://github.com/webmozart/assert/tree/master" - }, - "time": "2020-04-18T12:12:48+00:00" - } - ], - "aliases": [], - "minimum-stability": "stable", - "stability-flags": { - "composer/composer": 20 - }, - "prefer-stable": false, - "prefer-lowest": false, - "platform": { - "php": "^7", - "composer-plugin-api": "^1.1.0 || ^2.0" - }, - "platform-dev": { - "ext-zip": "^1.13" - }, - "plugin-api-version": "1.1.0" -} diff --git a/vendor/composer/package-versions-deprecated/src/PackageVersions/FallbackVersions.php b/vendor/composer/package-versions-deprecated/src/PackageVersions/FallbackVersions.php deleted file mode 100644 index 18e5fe64..00000000 --- a/vendor/composer/package-versions-deprecated/src/PackageVersions/FallbackVersions.php +++ /dev/null @@ -1,128 +0,0 @@ - - */ - private static function getVersions(array $packageData): Generator - { - foreach ($packageData as $package) { - yield $package['name'] => $package['version'] . '@' . ( - $package['source']['reference'] ?? $package['dist']['reference'] ?? '' - ); - } - - yield self::ROOT_PACKAGE_NAME => self::ROOT_PACKAGE_NAME; - } -} diff --git a/vendor/composer/package-versions-deprecated/src/PackageVersions/Installer.php b/vendor/composer/package-versions-deprecated/src/PackageVersions/Installer.php deleted file mode 100644 index 05bdac9a..00000000 --- a/vendor/composer/package-versions-deprecated/src/PackageVersions/Installer.php +++ /dev/null @@ -1,290 +0,0 @@ - - * @internal - */ - const VERSIONS = %s; - - private function __construct() - { - } - - /** - * @psalm-pure - * - * @psalm-suppress ImpureMethodCall we know that {@see InstalledVersions} interaction does not - * cause any side effects here. - */ - public static function rootPackageName() : string - { - if (!self::composer2ApiUsable()) { - return self::ROOT_PACKAGE_NAME; - } - - return InstalledVersions::getRootPackage()['name']; - } - - /** - * @throws OutOfBoundsException If a version cannot be located. - * - * @psalm-param key-of $packageName - * @psalm-pure - * - * @psalm-suppress ImpureMethodCall we know that {@see InstalledVersions} interaction does not - * cause any side effects here. - */ - public static function getVersion(string $packageName): string - { - if (self::composer2ApiUsable()) { - return InstalledVersions::getPrettyVersion($packageName) - . '@' . InstalledVersions::getReference($packageName); - } - - if (isset(self::VERSIONS[$packageName])) { - return self::VERSIONS[$packageName]; - } - - throw new OutOfBoundsException( - 'Required package "' . $packageName . '" is not installed: check your ./vendor/composer/installed.json and/or ./composer.lock files' - ); - } - - private static function composer2ApiUsable(): bool - { - if (!class_exists(InstalledVersions::class, false)) { - return false; - } - - if (method_exists(InstalledVersions::class, 'getAllRawData')) { - $rawData = InstalledVersions::getAllRawData(); - if (count($rawData) === 1 && count($rawData[0]) === 0) { - return false; - } - } else { - $rawData = InstalledVersions::getRawData(); - if ($rawData === null || $rawData === []) { - return false; - } - } - - return true; - } -} - -PHP; - - public function activate(Composer $composer, IOInterface $io) - { - // Nothing to do here, as all features are provided through event listeners - } - - public function deactivate(Composer $composer, IOInterface $io) - { - // Nothing to do here, as all features are provided through event listeners - } - - public function uninstall(Composer $composer, IOInterface $io) - { - // Nothing to do here, as all features are provided through event listeners - } - - /** - * {@inheritDoc} - */ - public static function getSubscribedEvents(): array - { - return [ScriptEvents::POST_AUTOLOAD_DUMP => 'dumpVersionsClass']; - } - - /** - * @throws RuntimeException - */ - public static function dumpVersionsClass(Event $composerEvent) - { - $composer = $composerEvent->getComposer(); - $rootPackage = $composer->getPackage(); - $versions = iterator_to_array(self::getVersions($composer->getLocker(), $rootPackage)); - - if (! array_key_exists('composer/package-versions-deprecated', $versions)) { - //plugin must be globally installed - we only want to generate versions for projects which specifically - //require composer/package-versions-deprecated - return; - } - - $versionClass = self::generateVersionsClass($rootPackage->getName(), $versions); - - self::writeVersionClassToFile($versionClass, $composer, $composerEvent->getIO()); - } - - /** - * @param string[] $versions - */ - private static function generateVersionsClass(string $rootPackageName, array $versions): string - { - return sprintf( - self::$generatedClassTemplate, - 'fin' . 'al ' . 'cla' . 'ss ' . 'Versions', // note: workaround for regex-based code parsers :-( - $rootPackageName, - var_export($versions, true) - ); - } - - /** - * @throws RuntimeException - */ - private static function writeVersionClassToFile(string $versionClassSource, Composer $composer, IOInterface $io) - { - $installPath = self::locateRootPackageInstallPath($composer->getConfig(), $composer->getPackage()) - . '/src/PackageVersions/Versions.php'; - - $installDir = dirname($installPath); - if (! file_exists($installDir)) { - $io->write('composer/package-versions-deprecated: Package not found (probably scheduled for removal); generation of version class skipped.'); - - return; - } - - if (! is_writable($installDir)) { - $io->write( - sprintf( - 'composer/package-versions-deprecated: %s is not writable; generation of version class skipped.', - $installDir - ) - ); - - return; - } - - $io->write('composer/package-versions-deprecated: Generating version class...'); - - $installPathTmp = $installPath . '_' . uniqid('tmp', true); - file_put_contents($installPathTmp, $versionClassSource); - chmod($installPathTmp, 0664); - rename($installPathTmp, $installPath); - - $io->write('composer/package-versions-deprecated: ...done generating version class'); - } - - /** - * @throws RuntimeException - */ - private static function locateRootPackageInstallPath( - Config $composerConfig, - RootPackageInterface $rootPackage - ): string { - if (self::getRootPackageAlias($rootPackage)->getName() === 'composer/package-versions-deprecated') { - return dirname($composerConfig->get('vendor-dir')); - } - - return $composerConfig->get('vendor-dir') . '/composer/package-versions-deprecated'; - } - - private static function getRootPackageAlias(RootPackageInterface $rootPackage): PackageInterface - { - $package = $rootPackage; - - while ($package instanceof AliasPackage) { - $package = $package->getAliasOf(); - } - - return $package; - } - - /** - * @return Generator&string[] - * - * @psalm-return Generator - */ - private static function getVersions(Locker $locker, RootPackageInterface $rootPackage): Generator - { - $lockData = $locker->getLockData(); - - $lockData['packages-dev'] = $lockData['packages-dev'] ?? []; - - $packages = $lockData['packages']; - if (getenv('COMPOSER_DEV_MODE') !== '0') { - $packages = array_merge($packages, $lockData['packages-dev']); - } - foreach ($packages as $package) { - yield $package['name'] => $package['version'] . '@' . ( - $package['source']['reference'] ?? $package['dist']['reference'] ?? '' - ); - } - - foreach ($rootPackage->getReplaces() as $replace) { - $version = $replace->getPrettyConstraint(); - if ($version === 'self.version') { - $version = $rootPackage->getPrettyVersion(); - } - - yield $replace->getTarget() => $version . '@' . $rootPackage->getSourceReference(); - } - - yield $rootPackage->getName() => $rootPackage->getPrettyVersion() . '@' . $rootPackage->getSourceReference(); - } -} diff --git a/vendor/composer/package-versions-deprecated/src/PackageVersions/Versions.php b/vendor/composer/package-versions-deprecated/src/PackageVersions/Versions.php deleted file mode 100644 index c1f45b5d..00000000 --- a/vendor/composer/package-versions-deprecated/src/PackageVersions/Versions.php +++ /dev/null @@ -1,94 +0,0 @@ - $count) { + echo $identifier . " was triggered " . $count . " times\n"; +} +``` + +### Suppressing Specific Deprecations + +Disable triggering about specific deprecations: + +```php +\Doctrine\Deprecations\Deprecation::ignoreDeprecations("https://link/to/deprecations-description-identifier"); +``` + +Disable all deprecations from a package + +```php +\Doctrine\Deprecations\Deprecation::ignorePackage("doctrine/orm"); +``` + +### Other Operations + +When used within PHPUnit or other tools that could collect multiple instances of the same deprecations +the deduplication can be disabled: + +```php +\Doctrine\Deprecations\Deprecation::withoutDeduplication(); +``` + +Disable deprecation tracking again: + +```php +\Doctrine\Deprecations\Deprecation::disable(); +``` + +## Usage from a library/producer perspective: + +When you want to unconditionally trigger a deprecation even when called +from the library itself then the `trigger` method is the way to go: + +```php +\Doctrine\Deprecations\Deprecation::trigger( + "doctrine/orm", + "https://link/to/deprecations-description", + "message" +); +``` + +If variable arguments are provided at the end, they are used with `sprintf` on +the message. + +```php +\Doctrine\Deprecations\Deprecation::trigger( + "doctrine/orm", + "https://github.com/doctrine/orm/issue/1234", + "message %s %d", + "foo", + 1234 +); +``` + +When you want to trigger a deprecation only when it is called by a function +outside of the current package, but not trigger when the package itself is the cause, +then use: + +```php +\Doctrine\Deprecations\Deprecation::triggerIfCalledFromOutside( + "doctrine/orm", + "https://link/to/deprecations-description", + "message" +); +``` + +Based on the issue link each deprecation message is only triggered once per +request. + +A limited stacktrace is included in the deprecation message to find the +offending location. + +Note: A producer/library should never call `Deprecation::enableWith` methods +and leave the decision how to handle deprecations to application and +frameworks. + +## Usage in PHPUnit tests + +There is a `VerifyDeprecations` trait that you can use to make assertions on +the occurrence of deprecations within a test. + +```php +use Doctrine\Deprecations\PHPUnit\VerifyDeprecations; + +class MyTest extends TestCase +{ + use VerifyDeprecations; + + public function testSomethingDeprecation() + { + $this->expectDeprecationWithIdentifier('https://github.com/doctrine/orm/issue/1234'); + + triggerTheCodeWithDeprecation(); + } + + public function testSomethingDeprecationFixed() + { + $this->expectNoDeprecationWithIdentifier('https://github.com/doctrine/orm/issue/1234'); + + triggerTheCodeWithoutDeprecation(); + } +} +``` + +## What is a deprecation identifier? + +An identifier for deprecations is just a link to any resource, most often a +Github Issue or Pull Request explaining the deprecation and potentially its +alternative. diff --git a/vendor/doctrine/deprecations/composer.json b/vendor/doctrine/deprecations/composer.json new file mode 100644 index 00000000..c79e38cd --- /dev/null +++ b/vendor/doctrine/deprecations/composer.json @@ -0,0 +1,32 @@ +{ + "name": "doctrine/deprecations", + "type": "library", + "description": "A small layer on top of trigger_error(E_USER_DEPRECATED) or PSR-3 logging with options to disable all deprecations or selectively for packages.", + "homepage": "https://www.doctrine-project.org/", + "license": "MIT", + "require": { + "php": "^7.1|^8.0" + }, + "require-dev": { + "phpunit/phpunit": "^7.5|^8.5|^9.5", + "psr/log": "^1|^2|^3", + "doctrine/coding-standard": "^9" + }, + "suggest": { + "psr/log": "Allows logging deprecations via PSR-3 logger implementation" + }, + "autoload": { + "psr-4": {"Doctrine\\Deprecations\\": "lib/Doctrine/Deprecations"} + }, + "autoload-dev": { + "psr-4": { + "DeprecationTests\\": "test_fixtures/src", + "Doctrine\\Foo\\": "test_fixtures/vendor/doctrine/foo" + } + }, + "config": { + "allow-plugins": { + "dealerdirect/phpcodesniffer-composer-installer": true + } + } +} diff --git a/vendor/doctrine/deprecations/lib/Doctrine/Deprecations/Deprecation.php b/vendor/doctrine/deprecations/lib/Doctrine/Deprecations/Deprecation.php new file mode 100644 index 00000000..1029372f --- /dev/null +++ b/vendor/doctrine/deprecations/lib/Doctrine/Deprecations/Deprecation.php @@ -0,0 +1,266 @@ + */ + private static $ignoredPackages = []; + + /** @var array */ + private static $ignoredLinks = []; + + /** @var bool */ + private static $deduplication = true; + + /** + * Trigger a deprecation for the given package and identfier. + * + * The link should point to a Github issue or Wiki entry detailing the + * deprecation. It is additionally used to de-duplicate the trigger of the + * same deprecation during a request. + * + * @param mixed $args + */ + public static function trigger(string $package, string $link, string $message, ...$args): void + { + if (self::$type === self::TYPE_NONE) { + return; + } + + if (array_key_exists($link, self::$ignoredLinks)) { + self::$ignoredLinks[$link]++; + } else { + self::$ignoredLinks[$link] = 1; + } + + if (self::$deduplication === true && self::$ignoredLinks[$link] > 1) { + return; + } + + if (isset(self::$ignoredPackages[$package])) { + return; + } + + $backtrace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 2); + + $message = sprintf($message, ...$args); + + self::delegateTriggerToBackend($message, $backtrace, $link, $package); + } + + /** + * Trigger a deprecation for the given package and identifier when called from outside. + * + * "Outside" means we assume that $package is currently installed as a + * dependency and the caller is not a file in that package. When $package + * is installed as a root package then deprecations triggered from the + * tests folder are also considered "outside". + * + * This deprecation method assumes that you are using Composer to install + * the dependency and are using the default /vendor/ folder and not a + * Composer plugin to change the install location. The assumption is also + * that $package is the exact composer packge name. + * + * Compared to {@link trigger()} this method causes some overhead when + * deprecation tracking is enabled even during deduplication, because it + * needs to call {@link debug_backtrace()} + * + * @param mixed $args + */ + public static function triggerIfCalledFromOutside(string $package, string $link, string $message, ...$args): void + { + if (self::$type === self::TYPE_NONE) { + return; + } + + $backtrace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 2); + + // first check that the caller is not from a tests folder, in which case we always let deprecations pass + if (strpos($backtrace[1]['file'], DIRECTORY_SEPARATOR . 'tests' . DIRECTORY_SEPARATOR) === false) { + $path = DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . $package . DIRECTORY_SEPARATOR; + + if (strpos($backtrace[0]['file'], $path) === false) { + return; + } + + if (strpos($backtrace[1]['file'], $path) !== false) { + return; + } + } + + if (array_key_exists($link, self::$ignoredLinks)) { + self::$ignoredLinks[$link]++; + } else { + self::$ignoredLinks[$link] = 1; + } + + if (self::$deduplication === true && self::$ignoredLinks[$link] > 1) { + return; + } + + if (isset(self::$ignoredPackages[$package])) { + return; + } + + $message = sprintf($message, ...$args); + + self::delegateTriggerToBackend($message, $backtrace, $link, $package); + } + + /** + * @param array $backtrace + */ + private static function delegateTriggerToBackend(string $message, array $backtrace, string $link, string $package): void + { + if ((self::$type & self::TYPE_PSR_LOGGER) > 0) { + $context = [ + 'file' => $backtrace[0]['file'], + 'line' => $backtrace[0]['line'], + 'package' => $package, + 'link' => $link, + ]; + + self::$logger->notice($message, $context); + } + + if (! ((self::$type & self::TYPE_TRIGGER_ERROR) > 0)) { + return; + } + + $message .= sprintf( + ' (%s:%d called by %s:%d, %s, package %s)', + self::basename($backtrace[0]['file']), + $backtrace[0]['line'], + self::basename($backtrace[1]['file']), + $backtrace[1]['line'], + $link, + $package + ); + + @trigger_error($message, E_USER_DEPRECATED); + } + + /** + * A non-local-aware version of PHPs basename function. + */ + private static function basename(string $filename): string + { + $pos = strrpos($filename, DIRECTORY_SEPARATOR); + + if ($pos === false) { + return $filename; + } + + return substr($filename, $pos + 1); + } + + public static function enableTrackingDeprecations(): void + { + self::$type |= self::TYPE_TRACK_DEPRECATIONS; + } + + public static function enableWithTriggerError(): void + { + self::$type |= self::TYPE_TRIGGER_ERROR; + } + + public static function enableWithPsrLogger(LoggerInterface $logger): void + { + self::$type |= self::TYPE_PSR_LOGGER; + self::$logger = $logger; + } + + public static function withoutDeduplication(): void + { + self::$deduplication = false; + } + + public static function disable(): void + { + self::$type = self::TYPE_NONE; + self::$logger = null; + self::$deduplication = true; + + foreach (self::$ignoredLinks as $link => $count) { + self::$ignoredLinks[$link] = 0; + } + } + + public static function ignorePackage(string $packageName): void + { + self::$ignoredPackages[$packageName] = true; + } + + public static function ignoreDeprecations(string ...$links): void + { + foreach ($links as $link) { + self::$ignoredLinks[$link] = 0; + } + } + + public static function getUniqueTriggeredDeprecationsCount(): int + { + return array_reduce(self::$ignoredLinks, static function (int $carry, int $count) { + return $carry + $count; + }, 0); + } + + /** + * Returns each triggered deprecation link identifier and the amount of occurrences. + * + * @return array + */ + public static function getTriggeredDeprecations(): array + { + return self::$ignoredLinks; + } +} diff --git a/vendor/doctrine/deprecations/lib/Doctrine/Deprecations/PHPUnit/VerifyDeprecations.php b/vendor/doctrine/deprecations/lib/Doctrine/Deprecations/PHPUnit/VerifyDeprecations.php new file mode 100644 index 00000000..4c3366a9 --- /dev/null +++ b/vendor/doctrine/deprecations/lib/Doctrine/Deprecations/PHPUnit/VerifyDeprecations.php @@ -0,0 +1,66 @@ + */ + private $doctrineDeprecationsExpectations = []; + + /** @var array */ + private $doctrineNoDeprecationsExpectations = []; + + public function expectDeprecationWithIdentifier(string $identifier): void + { + $this->doctrineDeprecationsExpectations[$identifier] = Deprecation::getTriggeredDeprecations()[$identifier] ?? 0; + } + + public function expectNoDeprecationWithIdentifier(string $identifier): void + { + $this->doctrineNoDeprecationsExpectations[$identifier] = Deprecation::getTriggeredDeprecations()[$identifier] ?? 0; + } + + /** + * @before + */ + public function enableDeprecationTracking(): void + { + Deprecation::enableTrackingDeprecations(); + } + + /** + * @after + */ + public function verifyDeprecationsAreTriggered(): void + { + foreach ($this->doctrineDeprecationsExpectations as $identifier => $expectation) { + $actualCount = Deprecation::getTriggeredDeprecations()[$identifier] ?? 0; + + $this->assertTrue( + $actualCount > $expectation, + sprintf( + "Expected deprecation with identifier '%s' was not triggered by code executed in test.", + $identifier + ) + ); + } + + foreach ($this->doctrineNoDeprecationsExpectations as $identifier => $expectation) { + $actualCount = Deprecation::getTriggeredDeprecations()[$identifier] ?? 0; + + $this->assertTrue( + $actualCount === $expectation, + sprintf( + "Expected deprecation with identifier '%s' was triggered by code executed in test, but expected not to.", + $identifier + ) + ); + } + } +} diff --git a/vendor/doctrine/deprecations/phpcs.xml b/vendor/doctrine/deprecations/phpcs.xml new file mode 100644 index 00000000..f115e43d --- /dev/null +++ b/vendor/doctrine/deprecations/phpcs.xml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + lib + tests + + + + + + diff --git a/vendor/phpdocumentor/type-resolver/.yamllint.yaml b/vendor/phpdocumentor/type-resolver/.yamllint.yaml deleted file mode 100644 index 55695cd5..00000000 --- a/vendor/phpdocumentor/type-resolver/.yamllint.yaml +++ /dev/null @@ -1,65 +0,0 @@ -extends: "default" - -ignore: | - .build/ - .notes/ - vendor/ -rules: - braces: - max-spaces-inside-empty: 0 - max-spaces-inside: 1 - min-spaces-inside-empty: 0 - min-spaces-inside: 1 - brackets: - max-spaces-inside-empty: 0 - max-spaces-inside: 0 - min-spaces-inside-empty: 0 - min-spaces-inside: 0 - colons: - max-spaces-after: 1 - max-spaces-before: 0 - commas: - max-spaces-after: 1 - max-spaces-before: 0 - min-spaces-after: 1 - comments: - ignore-shebangs: true - min-spaces-from-content: 1 - require-starting-space: true - comments-indentation: "enable" - document-end: - present: false - document-start: - present: false - indentation: - check-multi-line-strings: false - indent-sequences: true - spaces: 2 - empty-lines: - max-end: 0 - max-start: 0 - max: 1 - empty-values: - forbid-in-block-mappings: true - forbid-in-flow-mappings: true - hyphens: - max-spaces-after: 2 - key-duplicates: "enable" - key-ordering: "disable" - line-length: "disable" - new-line-at-end-of-file: "enable" - new-lines: - type: "unix" - octal-values: - forbid-implicit-octal: true - quoted-strings: - quote-type: "double" - trailing-spaces: "enable" - truthy: - allowed-values: - - "false" - - "true" - -yaml-files: - - "*.yaml" - - "*.yml" diff --git a/vendor/phpdocumentor/type-resolver/composer-require-checker.json b/vendor/phpdocumentor/type-resolver/composer-require-checker.json deleted file mode 100644 index 137522df..00000000 --- a/vendor/phpdocumentor/type-resolver/composer-require-checker.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "symbol-whitelist" : [ - "null", "true", "false", - "static", "self", "parent", - "array", "string", "int", "float", "bool", "iterable", "callable", "void", "object", "XSLTProcessor", - "T_NAME_QUALIFIED", "T_NAME_FULLY_QUALIFIED" - ], - "php-core-extensions" : [ - "Core", - "pcre", - "Reflection", - "tokenizer", - "SPL", - "standard" - ] -} diff --git a/vendor/phpdocumentor/type-resolver/composer.json b/vendor/phpdocumentor/type-resolver/composer.json index a7ae10f6..3138b4cc 100644 --- a/vendor/phpdocumentor/type-resolver/composer.json +++ b/vendor/phpdocumentor/type-resolver/composer.json @@ -11,7 +11,9 @@ ], "require": { "php": "^7.4 || ^8.0", - "phpdocumentor/reflection-common": "^2.0" + "phpdocumentor/reflection-common": "^2.0", + "phpstan/phpdoc-parser": "^1.13", + "doctrine/deprecations": "^1.0" }, "require-dev": { "ext-tokenizer": "*", @@ -20,7 +22,8 @@ "phpstan/phpstan-phpunit": "^1.1", "phpstan/extension-installer": "^1.1", "vimeo/psalm": "^4.25", - "rector/rector": "^0.13.9" + "rector/rector": "^0.13.9", + "phpbench/phpbench": "^1.2" }, "autoload": { "psr-4": { diff --git a/vendor/phpdocumentor/type-resolver/rector.php b/vendor/phpdocumentor/type-resolver/rector.php deleted file mode 100644 index b285d6cf..00000000 --- a/vendor/phpdocumentor/type-resolver/rector.php +++ /dev/null @@ -1,26 +0,0 @@ -paths([ - __DIR__ . '/src', - __DIR__ . '/tests/unit' - ]); - - // register a single rule - $rectorConfig->rule(InlineConstructorDefaultToPropertyRector::class); - $rectorConfig->rule(Rector\CodeQuality\Rector\Class_\CompleteDynamicPropertiesRector::class); - $rectorConfig->rule(Rector\TypeDeclaration\Rector\Closure\AddClosureReturnTypeRector::class); - $rectorConfig->rule(Rector\PHPUnit\Rector\Class_\AddProphecyTraitRector::class); - $rectorConfig->importNames(); - - // define sets of rules - $rectorConfig->sets([ - LevelSetList::UP_TO_PHP_74 - ]); -}; diff --git a/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ArrayShape.php b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ArrayShape.php new file mode 100644 index 00000000..48e66f01 --- /dev/null +++ b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ArrayShape.php @@ -0,0 +1,44 @@ +items = $items; + } + + public function underlyingType(): Type + { + return new Array_(new Mixed_(), new ArrayKey()); + } + + public function __toString(): string + { + return 'array{' . implode(', ', $this->items) . '}'; + } +} diff --git a/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ArrayShapeItem.php b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ArrayShapeItem.php new file mode 100644 index 00000000..56ab5dce --- /dev/null +++ b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ArrayShapeItem.php @@ -0,0 +1,62 @@ +key = $key; + $this->value = $value ?? new Mixed_(); + $this->optional = $optional; + } + + public function getKey(): ?string + { + return $this->key; + } + + public function getValue(): Type + { + return $this->value; + } + + public function isOptional(): bool + { + return $this->optional; + } + + public function __toString(): string + { + if ($this->key !== null) { + return sprintf( + '%s%s: %s', + $this->key, + $this->optional ? '?' : '', + (string) $this->value + ); + } + + return (string) $this->value; + } +} diff --git a/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ConstExpression.php b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ConstExpression.php new file mode 100644 index 00000000..930dfdcf --- /dev/null +++ b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/ConstExpression.php @@ -0,0 +1,53 @@ +owner = $owner; + $this->expression = $expression; + } + + public function getOwner(): Type + { + return $this->owner; + } + + public function getExpression(): string + { + return $this->expression; + } + + public function underlyingType(): Type + { + return new Mixed_(); + } + + public function __toString(): string + { + return sprintf('%s::%s', (string) $this->owner, $this->expression); + } +} diff --git a/vendor/phpdocumentor/type-resolver/src/PseudoTypes/FloatValue.php b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/FloatValue.php new file mode 100644 index 00000000..778374fe --- /dev/null +++ b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/FloatValue.php @@ -0,0 +1,44 @@ +value = $value; + } + + public function getValue(): float + { + return $this->value; + } + + public function underlyingType(): Type + { + return new Float_(); + } + + public function __toString(): string + { + return (string) $this->value; + } +} diff --git a/vendor/phpdocumentor/type-resolver/src/PseudoTypes/IntegerValue.php b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/IntegerValue.php new file mode 100644 index 00000000..e2f34633 --- /dev/null +++ b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/IntegerValue.php @@ -0,0 +1,44 @@ +value = $value; + } + + public function getValue(): int + { + return $this->value; + } + + public function underlyingType(): Type + { + return new Integer(); + } + + public function __toString(): string + { + return (string) $this->value; + } +} diff --git a/vendor/phpdocumentor/type-resolver/src/PseudoTypes/NonEmptyList.php b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/NonEmptyList.php new file mode 100644 index 00000000..dd6a6531 --- /dev/null +++ b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/NonEmptyList.php @@ -0,0 +1,50 @@ +valueType instanceof Mixed_) { + return 'non-empty-list'; + } + + return 'non-empty-list<' . $this->valueType . '>'; + } +} diff --git a/vendor/phpdocumentor/type-resolver/src/PseudoTypes/StringValue.php b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/StringValue.php new file mode 100644 index 00000000..c22eff07 --- /dev/null +++ b/vendor/phpdocumentor/type-resolver/src/PseudoTypes/StringValue.php @@ -0,0 +1,46 @@ +value = $value; + } + + public function getValue(): string + { + return $this->value; + } + + public function underlyingType(): Type + { + return new Float_(); + } + + public function __toString(): string + { + return sprintf('"%s"', $this->value); + } +} diff --git a/vendor/phpdocumentor/type-resolver/src/TypeResolver.php b/vendor/phpdocumentor/type-resolver/src/TypeResolver.php index e5695b8e..58af0ace 100644 --- a/vendor/phpdocumentor/type-resolver/src/TypeResolver.php +++ b/vendor/phpdocumentor/type-resolver/src/TypeResolver.php @@ -13,27 +13,36 @@ declare(strict_types=1); namespace phpDocumentor\Reflection; -use ArrayIterator; +use Doctrine\Deprecations\Deprecation; use InvalidArgumentException; +use phpDocumentor\Reflection\PseudoTypes\ArrayShape; +use phpDocumentor\Reflection\PseudoTypes\ArrayShapeItem; use phpDocumentor\Reflection\PseudoTypes\CallableString; +use phpDocumentor\Reflection\PseudoTypes\ConstExpression; use phpDocumentor\Reflection\PseudoTypes\False_; +use phpDocumentor\Reflection\PseudoTypes\FloatValue; use phpDocumentor\Reflection\PseudoTypes\HtmlEscapedString; use phpDocumentor\Reflection\PseudoTypes\IntegerRange; +use phpDocumentor\Reflection\PseudoTypes\IntegerValue; use phpDocumentor\Reflection\PseudoTypes\List_; use phpDocumentor\Reflection\PseudoTypes\LiteralString; use phpDocumentor\Reflection\PseudoTypes\LowercaseString; use phpDocumentor\Reflection\PseudoTypes\NegativeInteger; +use phpDocumentor\Reflection\PseudoTypes\NonEmptyList; use phpDocumentor\Reflection\PseudoTypes\NonEmptyLowercaseString; use phpDocumentor\Reflection\PseudoTypes\NonEmptyString; use phpDocumentor\Reflection\PseudoTypes\Numeric_; use phpDocumentor\Reflection\PseudoTypes\NumericString; use phpDocumentor\Reflection\PseudoTypes\PositiveInteger; +use phpDocumentor\Reflection\PseudoTypes\StringValue; use phpDocumentor\Reflection\PseudoTypes\TraitString; use phpDocumentor\Reflection\PseudoTypes\True_; +use phpDocumentor\Reflection\Types\AggregatedType; use phpDocumentor\Reflection\Types\Array_; use phpDocumentor\Reflection\Types\ArrayKey; use phpDocumentor\Reflection\Types\Boolean; use phpDocumentor\Reflection\Types\Callable_; +use phpDocumentor\Reflection\Types\CallableParameter; use phpDocumentor\Reflection\Types\ClassString; use phpDocumentor\Reflection\Types\Collection; use phpDocumentor\Reflection\Types\Compound; @@ -57,46 +66,51 @@ use phpDocumentor\Reflection\Types\Static_; use phpDocumentor\Reflection\Types\String_; use phpDocumentor\Reflection\Types\This; use phpDocumentor\Reflection\Types\Void_; +use PHPStan\PhpDocParser\Ast\ConstExpr\ConstExprFloatNode; +use PHPStan\PhpDocParser\Ast\ConstExpr\ConstExprIntegerNode; +use PHPStan\PhpDocParser\Ast\ConstExpr\ConstExprStringNode; +use PHPStan\PhpDocParser\Ast\ConstExpr\ConstFetchNode; +use PHPStan\PhpDocParser\Ast\Type\ArrayShapeItemNode; +use PHPStan\PhpDocParser\Ast\Type\ArrayShapeNode; +use PHPStan\PhpDocParser\Ast\Type\ArrayTypeNode; +use PHPStan\PhpDocParser\Ast\Type\CallableTypeNode; +use PHPStan\PhpDocParser\Ast\Type\CallableTypeParameterNode; +use PHPStan\PhpDocParser\Ast\Type\ConditionalTypeForParameterNode; +use PHPStan\PhpDocParser\Ast\Type\ConditionalTypeNode; +use PHPStan\PhpDocParser\Ast\Type\ConstTypeNode; +use PHPStan\PhpDocParser\Ast\Type\GenericTypeNode; +use PHPStan\PhpDocParser\Ast\Type\IdentifierTypeNode; +use PHPStan\PhpDocParser\Ast\Type\IntersectionTypeNode; +use PHPStan\PhpDocParser\Ast\Type\NullableTypeNode; +use PHPStan\PhpDocParser\Ast\Type\OffsetAccessTypeNode; +use PHPStan\PhpDocParser\Ast\Type\ThisTypeNode; +use PHPStan\PhpDocParser\Ast\Type\TypeNode; +use PHPStan\PhpDocParser\Ast\Type\UnionTypeNode; +use PHPStan\PhpDocParser\Lexer\Lexer; +use PHPStan\PhpDocParser\Parser\ConstExprParser; +use PHPStan\PhpDocParser\Parser\ParserException; +use PHPStan\PhpDocParser\Parser\TokenIterator; +use PHPStan\PhpDocParser\Parser\TypeParser; use RuntimeException; +use function array_filter; use function array_key_exists; -use function array_key_last; -use function array_pop; -use function array_values; +use function array_map; +use function array_reverse; use function class_exists; use function class_implements; -use function count; -use function current; +use function get_class; use function in_array; -use function is_numeric; -use function preg_split; +use function sprintf; use function strpos; use function strtolower; use function trim; -use const PREG_SPLIT_DELIM_CAPTURE; -use const PREG_SPLIT_NO_EMPTY; - final class TypeResolver { - /** @var string Definition of the ARRAY operator for types */ - private const OPERATOR_ARRAY = '[]'; - /** @var string Definition of the NAMESPACE operator in PHP */ private const OPERATOR_NAMESPACE = '\\'; - /** @var int the iterator parser is inside a compound context */ - private const PARSER_IN_COMPOUND = 0; - - /** @var int the iterator parser is inside a nullable expression context */ - private const PARSER_IN_NULLABLE = 1; - - /** @var int the iterator parser is inside an array expression context */ - private const PARSER_IN_ARRAY_EXPRESSION = 2; - - /** @var int the iterator parser is inside a collection expression context */ - private const PARSER_IN_COLLECTION_EXPRESSION = 3; - /** * @var array List of recognized keywords and unto which Value Object they map * @psalm-var array> @@ -142,10 +156,15 @@ final class TypeResolver 'iterable' => Iterable_::class, 'never' => Never_::class, 'list' => List_::class, + 'non-empty-list' => NonEmptyList::class, ]; /** @psalm-readonly */ private FqsenResolver $fqsenResolver; + /** @psalm-readonly */ + private TypeParser $typeParser; + /** @psalm-readonly */ + private Lexer $lexer; /** * Initializes this TypeResolver with the means to create and resolve Fqsen objects. @@ -153,6 +172,8 @@ final class TypeResolver public function __construct(?FqsenResolver $fqsenResolver = null) { $this->fqsenResolver = $fqsenResolver ?: new FqsenResolver(); + $this->typeParser = new TypeParser(new ConstExprParser()); + $this->lexer = new Lexer(); } /** @@ -165,9 +186,9 @@ final class TypeResolver * This method only works as expected if the namespace and aliases are set; * no dynamic reflection is being performed here. * + * @uses Context::getNamespace() to determine with what to prefix the type name. * @uses Context::getNamespaceAliases() to check whether the first part of the relative type name should not be * replaced with another namespace. - * @uses Context::getNamespace() to determine with what to prefix the type name. * * @param string $type The relative or absolute type. */ @@ -182,178 +203,219 @@ final class TypeResolver $context = new Context(''); } - // split the type string into tokens `|`, `?`, `<`, `>`, `,`, `(`, `)`, `[]`, '<', '>' and type names - $tokens = preg_split( - '/(\\||\\?|<|>|&|, ?|\\(|\\)|\\[\\]+)/', - $type, - -1, - PREG_SPLIT_NO_EMPTY | PREG_SPLIT_DELIM_CAPTURE - ); + $tokens = $this->lexer->tokenize($type); + $tokenIterator = new TokenIterator($tokens); - if ($tokens === false) { - throw new InvalidArgumentException('Unable to split the type string "' . $type . '" into tokens'); - } + $ast = $this->parse($tokenIterator); + $type = $this->createType($ast, $context); - /** @var ArrayIterator $tokenIterator */ - $tokenIterator = new ArrayIterator($tokens); - - return $this->parseTypes($tokenIterator, $context, self::PARSER_IN_COMPOUND); + return $this->tryParseRemainingCompoundTypes($tokenIterator, $context, $type); } - /** - * Analyse each tokens and creates types - * - * @param ArrayIterator $tokens the iterator on tokens - * @param int $parserContext on of self::PARSER_* constants, indicating - * the context where we are in the parsing - */ - private function parseTypes(ArrayIterator $tokens, Context $context, int $parserContext): Type + public function createType(?TypeNode $type, Context $context): Type { - $types = []; - $token = ''; - $compoundToken = '|'; - while ($tokens->valid()) { - $token = $tokens->current(); - if ($token === null) { - throw new RuntimeException( - 'Unexpected nullable character' - ); - } + if ($type === null) { + return new Mixed_(); + } - if ($token === '|' || $token === '&') { - if (count($types) === 0) { + switch (get_class($type)) { + case ArrayTypeNode::class: + return new Array_( + $this->createType($type->type, $context) + ); + + case ArrayShapeNode::class: + return new ArrayShape( + ...array_map( + fn (ArrayShapeItemNode $item) => new ArrayShapeItem( + (string) $item->keyName, + $this->createType($item->valueType, $context), + $item->optional + ), + $type->items + ) + ); + + case CallableTypeNode::class: + return $this->createFromCallable($type, $context); + + case ConstTypeNode::class: + return $this->createFromConst($type, $context); + + case GenericTypeNode::class: + return $this->createFromGeneric($type, $context); + + case IdentifierTypeNode::class: + return $this->resolveSingleType($type->name, $context); + + case IntersectionTypeNode::class: + return new Intersection( + array_filter( + array_map( + function (TypeNode $nestedType) use ($context) { + $type = $this->createType($nestedType, $context); + if ($type instanceof AggregatedType) { + return new Expression($type); + } + + return $type; + }, + $type->types + ) + ) + ); + + case NullableTypeNode::class: + $nestedType = $this->createType($type->type, $context); + + return new Nullable($nestedType); + + case UnionTypeNode::class: + return new Compound( + array_filter( + array_map( + function (TypeNode $nestedType) use ($context) { + $type = $this->createType($nestedType, $context); + if ($type instanceof AggregatedType) { + return new Expression($type); + } + + return $type; + }, + $type->types + ) + ) + ); + + case ThisTypeNode::class: + return new This(); + + case ConditionalTypeNode::class: + case ConditionalTypeForParameterNode::class: + case OffsetAccessTypeNode::class: + default: + return new Mixed_(); + } + } + + private function createFromGeneric(GenericTypeNode $type, Context $context): Type + { + switch (strtolower($type->type->name)) { + case 'array': + return $this->createArray($type->genericTypes, $context); + + case 'class-string': + $subType = $this->createType($type->genericTypes[0], $context); + if (!$subType instanceof Object_ || $subType->getFqsen() === null) { throw new RuntimeException( - 'A type is missing before a type separator' + $subType . ' is not a class string' ); } - if ( - !in_array($parserContext, [ - self::PARSER_IN_COMPOUND, - self::PARSER_IN_ARRAY_EXPRESSION, - self::PARSER_IN_COLLECTION_EXPRESSION, - self::PARSER_IN_NULLABLE, - ], true) - ) { + return new ClassString( + $subType->getFqsen() + ); + + case 'interface-string': + $subType = $this->createType($type->genericTypes[0], $context); + if (!$subType instanceof Object_ || $subType->getFqsen() === null) { throw new RuntimeException( - 'Unexpected type separator' + $subType . ' is not a class string' ); } - $compoundToken = $token; - $tokens->next(); - } elseif ($token === '?') { - if ( - !in_array($parserContext, [ - self::PARSER_IN_COMPOUND, - self::PARSER_IN_ARRAY_EXPRESSION, - self::PARSER_IN_COLLECTION_EXPRESSION, - self::PARSER_IN_NULLABLE, - ], true) - ) { - throw new RuntimeException( - 'Unexpected nullable character' + return new InterfaceString( + $subType->getFqsen() + ); + + case 'list': + return new List_( + $this->createType($type->genericTypes[0], $context) + ); + + case 'non-empty-list': + return new NonEmptyList( + $this->createType($type->genericTypes[0], $context) + ); + + case 'int': + if (isset($type->genericTypes[1]) === false) { + throw new RuntimeException('int has not the correct format'); + } + + return new IntegerRange( + (string) $type->genericTypes[0], + (string) $type->genericTypes[1], + ); + + case 'iterable': + return new Iterable_( + ...array_reverse( + array_map( + fn (TypeNode $genericType) => $this->createType($genericType, $context), + $type->genericTypes + ) + ) + ); + + default: + $collectionType = $this->createType($type->type, $context); + if ($collectionType instanceof Object_ === false) { + throw new RuntimeException(sprintf('%s is not a collection', (string) $collectionType)); + } + + return new Collection( + $collectionType->getFqsen(), + ...array_reverse( + array_map( + fn (TypeNode $genericType) => $this->createType($genericType, $context), + $type->genericTypes + ) + ) + ); + } + } + + private function createFromCallable(CallableTypeNode $type, Context $context): Callable_ + { + return new Callable_( + array_map( + function (CallableTypeParameterNode $param) use ($context) { + return new CallableParameter( + $this->createType($param->type, $context), + $param->parameterName !== '' ? trim($param->parameterName, '$') : null, + $param->isReference, + $param->isVariadic, + $param->isOptional ); - } + }, + $type->parameters + ), + $this->createType($type->returnType, $context), + ); + } - $tokens->next(); - $type = $this->parseTypes($tokens, $context, self::PARSER_IN_NULLABLE); - $types[] = new Nullable($type); - } elseif ($token === '(') { - $tokens->next(); - $type = $this->parseTypes($tokens, $context, self::PARSER_IN_ARRAY_EXPRESSION); + private function createFromConst(ConstTypeNode $type, Context $context): Type + { + switch (true) { + case $type->constExpr instanceof ConstExprIntegerNode: + return new IntegerValue((int) $type->constExpr->value); - $token = $tokens->current(); - if ($token === null) { // Someone did not properly close their array expression .. - break; - } + case $type->constExpr instanceof ConstExprFloatNode: + return new FloatValue((float) $type->constExpr->value); - $tokens->next(); + case $type->constExpr instanceof ConstExprStringNode: + return new StringValue($type->constExpr->value); - $resolvedType = new Expression($type); - - $types[] = $resolvedType; - } elseif ($parserContext === self::PARSER_IN_ARRAY_EXPRESSION && isset($token[0]) && $token[0] === ')') { - break; - } elseif ($token === '<') { - if (count($types) === 0) { - throw new RuntimeException( - 'Unexpected collection operator "<", class name is missing' - ); - } - - $classType = array_pop($types); - if ($classType !== null) { - if ((string) $classType === 'class-string') { - $types[] = $this->resolveClassString($tokens, $context); - } elseif ((string) $classType === 'int') { - $types[] = $this->resolveIntRange($tokens); - } elseif ((string) $classType === 'interface-string') { - $types[] = $this->resolveInterfaceString($tokens, $context); - } else { - $types[] = $this->resolveCollection($tokens, $classType, $context); - } - } - - $tokens->next(); - } elseif ( - $parserContext === self::PARSER_IN_COLLECTION_EXPRESSION - && ($token === '>' || trim($token) === ',') - ) { - break; - } elseif ($token === self::OPERATOR_ARRAY) { - $last = array_key_last($types); - if ($last === null) { - throw new InvalidArgumentException('Unexpected array operator'); - } - - $lastItem = $types[$last]; - if ($lastItem instanceof Expression) { - $lastItem = $lastItem->getValueType(); - } - - $types[$last] = new Array_($lastItem); - - $tokens->next(); - } else { - $types[] = $this->resolveSingleType($token, $context); - $tokens->next(); - } - } - - if ($token === '|' || $token === '&') { - throw new RuntimeException( - 'A type is missing after a type separator' - ); - } - - if (count($types) === 0) { - if ($parserContext === self::PARSER_IN_NULLABLE) { - throw new RuntimeException( - 'A type is missing after a nullable character' + case $type->constExpr instanceof ConstFetchNode: + return new ConstExpression( + $this->resolve($type->constExpr->className, $context), + $type->constExpr->name ); - } - if ($parserContext === self::PARSER_IN_ARRAY_EXPRESSION) { - throw new RuntimeException( - 'A type is missing in an array expression' - ); - } - - if ($parserContext === self::PARSER_IN_COLLECTION_EXPRESSION) { - throw new RuntimeException( - 'A type is missing in a collection expression' - ); - } - } elseif (count($types) === 1) { - return current($types); + default: + throw new RuntimeException(sprintf('Unsupported constant type %s', get_class($type))); } - - if ($compoundToken === '|') { - return new Compound(array_values($types)); - } - - return new Intersection(array_values($types)); } /** @@ -475,244 +537,87 @@ final class TypeResolver return new Object_($this->fqsenResolver->resolve($type, $context)); } - /** - * Resolves class string - * - * @param ArrayIterator $tokens - */ - private function resolveClassString(ArrayIterator $tokens, Context $context): Type + /** @param TypeNode[] $typeNodes */ + private function createArray(array $typeNodes, Context $context): Array_ { - $tokens->next(); + $types = array_reverse( + array_map( + fn (TypeNode $node) => $this->createType($node, $context), + $typeNodes + ) + ); - $classType = $this->parseTypes($tokens, $context, self::PARSER_IN_COLLECTION_EXPRESSION); - - if (!$classType instanceof Object_ || $classType->getFqsen() === null) { - throw new RuntimeException( - $classType . ' is not a class string' - ); + if (isset($types[1]) === false) { + return new Array_(...$types); } - $token = $tokens->current(); - if ($token !== '>') { - if (empty($token)) { - throw new RuntimeException( - 'class-string: ">" is missing' - ); + if ($this->validArrayKeyType($types[1]) || $types[1] instanceof ArrayKey) { + return new Array_(...$types); + } + + if ($types[1] instanceof Compound && $types[1]->getIterator()->count() === 2) { + if ($this->validArrayKeyType($types[1]->get(0)) && $this->validArrayKeyType($types[1]->get(1))) { + return new Array_(...$types); } - - throw new RuntimeException( - 'Unexpected character "' . $token . '", ">" is missing' - ); } - return new ClassString($classType->getFqsen()); + throw new RuntimeException('An array can have only integers or strings as keys'); + } + + private function validArrayKeyType(?Type $type): bool + { + return $type instanceof String_ || $type instanceof Integer; + } + + private function parse(TokenIterator $tokenIterator): TypeNode + { + try { + $ast = $this->typeParser->parse($tokenIterator); + } catch (ParserException $e) { + throw new RuntimeException($e->getMessage(), 0, $e); + } + + return $ast; } /** - * Resolves integer ranges + * Will try to parse unsupported type notations by phpstan * - * @param ArrayIterator $tokens + * The phpstan parser doesn't support the illegal nullable combinations like this library does. + * This method will warn the user about those notations but for bc purposes we will still have it here. */ - private function resolveIntRange(ArrayIterator $tokens): Type + private function tryParseRemainingCompoundTypes(TokenIterator $tokenIterator, Context $context, Type $type): Type { - $tokens->next(); - - $token = ''; - $minValue = null; - $maxValue = null; - $commaFound = false; - $tokenCounter = 0; - while ($tokens->valid()) { - $tokenCounter++; - $token = $tokens->current(); - if ($token === null) { - throw new RuntimeException( - 'Unexpected nullable character' - ); - } - - $token = trim($token); - - if ($token === '>') { - break; - } - - if ($token === ',') { - $commaFound = true; - } - - if ($commaFound === false && $minValue === null) { - if (is_numeric($token) || $token === 'max' || $token === 'min') { - $minValue = $token; - } - } - - if ($commaFound === true && $maxValue === null) { - if (is_numeric($token) || $token === 'max' || $token === 'min') { - $maxValue = $token; - } - } - - $tokens->next(); - } - - if ($token !== '>') { - if (empty($token)) { - throw new RuntimeException( - 'interface-string: ">" is missing' - ); - } - - throw new RuntimeException( - 'Unexpected character "' . $token . '", ">" is missing' - ); - } - - if ($minValue === null || $maxValue === null || $tokenCounter > 4) { - throw new RuntimeException( - 'int has not the correct format' - ); - } - - return new IntegerRange($minValue, $maxValue); - } - - /** - * Resolves class string - * - * @param ArrayIterator $tokens - */ - private function resolveInterfaceString(ArrayIterator $tokens, Context $context): Type - { - $tokens->next(); - - $classType = $this->parseTypes($tokens, $context, self::PARSER_IN_COLLECTION_EXPRESSION); - - if (!$classType instanceof Object_ || $classType->getFqsen() === null) { - throw new RuntimeException( - $classType . ' is not a interface string' - ); - } - - $token = $tokens->current(); - if ($token !== '>') { - if (empty($token)) { - throw new RuntimeException( - 'interface-string: ">" is missing' - ); - } - - throw new RuntimeException( - 'Unexpected character "' . $token . '", ">" is missing' - ); - } - - return new InterfaceString($classType->getFqsen()); - } - - /** - * Resolves the collection values and keys - * - * @param ArrayIterator $tokens - * - * @return Array_|Iterable_|Collection - */ - private function resolveCollection(ArrayIterator $tokens, Type $classType, Context $context): Type - { - $isArray = ((string) $classType === 'array'); - $isIterable = ((string) $classType === 'iterable'); - $isList = ((string) $classType === 'list'); - - // allow only "array", "iterable" or class name before "<" if ( - !$isArray && !$isIterable && !$isList - && (!$classType instanceof Object_ || $classType->getFqsen() === null) + $tokenIterator->isCurrentTokenType(Lexer::TOKEN_UNION) || + $tokenIterator->isCurrentTokenType(Lexer::TOKEN_INTERSECTION) ) { - throw new RuntimeException( - $classType . ' is not a collection' + Deprecation::trigger( + 'phpdocumentor/type-resolver', + 'https://github.com/phpDocumentor/TypeResolver/issues/184', + 'Legacy nullable type detected, please update your code as + you are using nullable types in a docblock. support will be removed in v2.0.0', ); } - $tokens->next(); - - $valueType = $this->parseTypes($tokens, $context, self::PARSER_IN_COLLECTION_EXPRESSION); - $keyType = null; - - $token = $tokens->current(); - if ($token !== null && trim($token) === ',' && !$isList) { - // if we have a comma, then we just parsed the key type, not the value type - $keyType = $valueType; - if ($isArray) { - // check the key type for an "array" collection. We allow only - // strings or integers. - if ( - !$keyType instanceof ArrayKey && - !$keyType instanceof String_ && - !$keyType instanceof Integer && - !$keyType instanceof Compound - ) { - throw new RuntimeException( - 'An array can have only integers or strings as keys' - ); - } - - if ($keyType instanceof Compound) { - foreach ($keyType->getIterator() as $item) { - if ( - !$item instanceof ArrayKey && - !$item instanceof String_ && - !$item instanceof Integer - ) { - throw new RuntimeException( - 'An array can have only integers or strings as keys' - ); - } - } - } + $continue = true; + while ($continue) { + $continue = false; + while ($tokenIterator->tryConsumeTokenType(Lexer::TOKEN_UNION)) { + $ast = $this->parse($tokenIterator); + $type2 = $this->createType($ast, $context); + $type = new Compound([$type, $type2]); + $continue = true; } - $tokens->next(); - // now let's parse the value type - $valueType = $this->parseTypes($tokens, $context, self::PARSER_IN_COLLECTION_EXPRESSION); - } - - $token = $tokens->current(); - if ($token !== '>') { - if (empty($token)) { - throw new RuntimeException( - 'Collection: ">" is missing' - ); + while ($tokenIterator->tryConsumeTokenType(Lexer::TOKEN_INTERSECTION)) { + $ast = $this->typeParser->parse($tokenIterator); + $type2 = $this->createType($ast, $context); + $type = new Intersection([$type, $type2]); + $continue = true; } - - throw new RuntimeException( - 'Unexpected character "' . $token . '", ">" is missing' - ); } - if ($isArray) { - return new Array_($valueType, $keyType); - } - - if ($isIterable) { - return new Iterable_($valueType, $keyType); - } - - if ($isList) { - return new List_($valueType); - } - - if ($classType instanceof Object_) { - return $this->makeCollectionFromObject($classType, $valueType, $keyType); - } - - throw new RuntimeException('Invalid $classType provided'); - } - - /** - * @psalm-pure - */ - private function makeCollectionFromObject(Object_ $object, Type $valueType, ?Type $keyType = null): Collection - { - return new Collection($object->getFqsen(), $valueType, $keyType); + return $type; } } diff --git a/vendor/phpdocumentor/type-resolver/src/Types/AggregatedType.php b/vendor/phpdocumentor/type-resolver/src/Types/AggregatedType.php index 257ed516..6f9e8795 100644 --- a/vendor/phpdocumentor/type-resolver/src/Types/AggregatedType.php +++ b/vendor/phpdocumentor/type-resolver/src/Types/AggregatedType.php @@ -106,7 +106,7 @@ abstract class AggregatedType implements Type, IteratorAggregate */ private function add(Type $type): void { - if ($type instanceof self) { + if ($type instanceof static) { foreach ($type->getIterator() as $subType) { $this->add($subType); } diff --git a/vendor/phpdocumentor/type-resolver/src/Types/CallableParameter.php b/vendor/phpdocumentor/type-resolver/src/Types/CallableParameter.php new file mode 100644 index 00000000..1a36d239 --- /dev/null +++ b/vendor/phpdocumentor/type-resolver/src/Types/CallableParameter.php @@ -0,0 +1,72 @@ +type = $type; + $this->isReference = $isReference; + $this->isVariadic = $isVariadic; + $this->isOptional = $isOptional; + $this->name = $name; + } + + public function getName(): ?string + { + return $this->name; + } + + public function getType(): Type + { + return $this->type; + } + + public function isReference(): bool + { + return $this->isReference; + } + + public function isVariadic(): bool + { + return $this->isVariadic; + } + + public function isOptional(): bool + { + return $this->isOptional; + } +} diff --git a/vendor/phpdocumentor/type-resolver/src/Types/Callable_.php b/vendor/phpdocumentor/type-resolver/src/Types/Callable_.php index 4e67aa4a..20c57267 100644 --- a/vendor/phpdocumentor/type-resolver/src/Types/Callable_.php +++ b/vendor/phpdocumentor/type-resolver/src/Types/Callable_.php @@ -22,6 +22,30 @@ use phpDocumentor\Reflection\Type; */ final class Callable_ implements Type { + private ?Type $returnType; + /** @var CallableParameter[] */ + private array $parameters; + + /** + * @param CallableParameter[] $parameters + */ + public function __construct(array $parameters = [], ?Type $returnType = null) + { + $this->parameters = $parameters; + $this->returnType = $returnType; + } + + /** @return CallableParameter[] */ + public function getParameters(): array + { + return $this->parameters; + } + + public function getReturnType(): ?Type + { + return $this->returnType; + } + /** * Returns a rendered output of the Type as it would be used in a DocBlock. */ diff --git a/vendor/phpstan/phpdoc-parser/LICENSE b/vendor/phpstan/phpdoc-parser/LICENSE new file mode 100644 index 00000000..98a854e4 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2016 Ondřej Mirtes + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/vendor/phpstan/phpdoc-parser/README.md b/vendor/phpstan/phpdoc-parser/README.md new file mode 100644 index 00000000..080e25ee --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/README.md @@ -0,0 +1,30 @@ +

PHPDoc-Parser for PHPStan

+ +

+ Build Status + Latest Stable Version + License + PHPStan Enabled +

+ +* [PHPStan](https://phpstan.org) + +------ + +Next generation phpDoc parser with support for intersection types and generics. + +## Code of Conduct + +This project adheres to a [Contributor Code of Conduct](CODE_OF_CONDUCT.md). By participating in this project and its community, you are expected to uphold this code. + +## Building + +Initially you need to run `composer install`, or `composer update` in case you aren't working in a folder which was built before. + +Afterwards you can either run the whole build including linting and coding standards using + + make + +or run only tests using + + make tests diff --git a/vendor/phpstan/phpdoc-parser/composer.json b/vendor/phpstan/phpdoc-parser/composer.json new file mode 100644 index 00000000..3b902ae2 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/composer.json @@ -0,0 +1,42 @@ +{ + "name": "phpstan/phpdoc-parser", + "description": "PHPDoc parser with support for nullable, intersection and generic types", + "license": "MIT", + "require": { + "php": "^7.2 || ^8.0" + }, + "require-dev": { + "php-parallel-lint/php-parallel-lint": "^1.2", + "phpstan/extension-installer": "^1.0", + "phpstan/phpstan": "^1.5", + "phpstan/phpstan-phpunit": "^1.1", + "phpstan/phpstan-strict-rules": "^1.0", + "phpunit/phpunit": "^9.5", + "symfony/process": "^5.2" + }, + "config": { + "platform": { + "php": "7.4.6" + }, + "sort-packages": true, + "allow-plugins": { + "phpstan/extension-installer": true + } + }, + "autoload": { + "psr-4": { + "PHPStan\\PhpDocParser\\": [ + "src/" + ] + } + }, + "autoload-dev": { + "psr-4": { + "PHPStan\\PhpDocParser\\": [ + "tests/PHPStan" + ] + } + }, + "minimum-stability": "dev", + "prefer-stable": true +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprArrayItemNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprArrayItemNode.php new file mode 100644 index 00000000..ef144521 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprArrayItemNode.php @@ -0,0 +1,36 @@ +key = $key; + $this->value = $value; + } + + + public function __toString(): string + { + if ($this->key !== null) { + return sprintf('%s => %s', $this->key, $this->value); + + } + + return (string) $this->value; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprArrayNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprArrayNode.php new file mode 100644 index 00000000..1f9def37 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprArrayNode.php @@ -0,0 +1,30 @@ +items = $items; + } + + + public function __toString(): string + { + return '[' . implode(', ', $this->items) . ']'; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprFalseNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprFalseNode.php new file mode 100644 index 00000000..e6811277 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprFalseNode.php @@ -0,0 +1,17 @@ +value = $value; + } + + + public function __toString(): string + { + return $this->value; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprIntegerNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprIntegerNode.php new file mode 100644 index 00000000..5339bb5a --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprIntegerNode.php @@ -0,0 +1,26 @@ +value = $value; + } + + + public function __toString(): string + { + return $this->value; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprNode.php new file mode 100644 index 00000000..1859f03e --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprNode.php @@ -0,0 +1,10 @@ +value = $value; + } + + + public function __toString(): string + { + return $this->value; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprTrueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprTrueNode.php new file mode 100644 index 00000000..ec980320 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/ConstExpr/ConstExprTrueNode.php @@ -0,0 +1,17 @@ +className = $className; + $this->name = $name; + } + + + public function __toString(): string + { + if ($this->className === '') { + return $this->name; + + } + + return "{$this->className}::{$this->name}"; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Node.php b/vendor/phpstan/phpdoc-parser/src/Ast/Node.php new file mode 100644 index 00000000..51a1a19a --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Node.php @@ -0,0 +1,22 @@ + */ + private $attributes = []; + + /** + * @param mixed $value + */ + public function setAttribute(string $key, $value): void + { + $this->attributes[$key] = $value; + } + + public function hasAttribute(string $key): bool + { + return array_key_exists($key, $this->attributes); + } + + /** + * @return mixed + */ + public function getAttribute(string $key) + { + if ($this->hasAttribute($key)) { + return $this->attributes[$key]; + } + + return null; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagMethodValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagMethodValueNode.php new file mode 100644 index 00000000..cf4f5563 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagMethodValueNode.php @@ -0,0 +1,50 @@ +type = $type; + $this->parameter = $parameter; + $this->method = $method; + $this->isNegated = $isNegated; + $this->isEquality = $isEquality; + $this->description = $description; + } + + + public function __toString(): string + { + $isNegated = $this->isNegated ? '!' : ''; + $isEquality = $this->isEquality ? '=' : ''; + return trim("{$isNegated}{$isEquality}{$this->type} {$this->parameter}->{$this->method}() {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagPropertyValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagPropertyValueNode.php new file mode 100644 index 00000000..4fb31807 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagPropertyValueNode.php @@ -0,0 +1,50 @@ +type = $type; + $this->parameter = $parameter; + $this->property = $property; + $this->isNegated = $isNegated; + $this->isEquality = $isEquality; + $this->description = $description; + } + + + public function __toString(): string + { + $isNegated = $this->isNegated ? '!' : ''; + $isEquality = $this->isEquality ? '=' : ''; + return trim("{$isNegated}{$isEquality}{$this->type} {$this->parameter}->{$this->property} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagValueNode.php new file mode 100644 index 00000000..d6423f50 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/AssertTagValueNode.php @@ -0,0 +1,46 @@ +type = $type; + $this->parameter = $parameter; + $this->isNegated = $isNegated; + $this->isEquality = $isEquality; + $this->description = $description; + } + + + public function __toString(): string + { + $isNegated = $this->isNegated ? '!' : ''; + $isEquality = $this->isEquality ? '=' : ''; + return trim("{$isNegated}{$isEquality}{$this->type} {$this->parameter} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/DeprecatedTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/DeprecatedTagValueNode.php new file mode 100644 index 00000000..abf2f1a6 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/DeprecatedTagValueNode.php @@ -0,0 +1,27 @@ +description = $description; + } + + + public function __toString(): string + { + return trim($this->description); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ExtendsTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ExtendsTagValueNode.php new file mode 100644 index 00000000..3bf53e13 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ExtendsTagValueNode.php @@ -0,0 +1,32 @@ +type = $type; + $this->description = $description; + } + + + public function __toString(): string + { + return trim("{$this->type} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/GenericTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/GenericTagValueNode.php new file mode 100644 index 00000000..026aa153 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/GenericTagValueNode.php @@ -0,0 +1,26 @@ +value = $value; + } + + + public function __toString(): string + { + return $this->value; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ImplementsTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ImplementsTagValueNode.php new file mode 100644 index 00000000..99043d91 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ImplementsTagValueNode.php @@ -0,0 +1,32 @@ +type = $type; + $this->description = $description; + } + + + public function __toString(): string + { + return trim("{$this->type} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/InvalidTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/InvalidTagValueNode.php new file mode 100644 index 00000000..17bf04f2 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/InvalidTagValueNode.php @@ -0,0 +1,52 @@ +value = $value; + $this->exceptionArgs = [ + $exception->getCurrentTokenValue(), + $exception->getCurrentTokenType(), + $exception->getCurrentOffset(), + $exception->getExpectedTokenType(), + $exception->getExpectedTokenValue(), + ]; + } + + public function __get(string $name) + { + if ($name !== 'exception') { + trigger_error(sprintf('Undefined property: %s::$%s', self::class, $name), E_USER_WARNING); + return null; + } + + return new ParserException(...$this->exceptionArgs); + } + + public function __toString(): string + { + return $this->value; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MethodTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MethodTagValueNode.php new file mode 100644 index 00000000..075cec04 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MethodTagValueNode.php @@ -0,0 +1,54 @@ +isStatic = $isStatic; + $this->returnType = $returnType; + $this->methodName = $methodName; + $this->parameters = $parameters; + $this->description = $description; + $this->templateTypes = $templateTypes; + } + + + public function __toString(): string + { + $static = $this->isStatic ? 'static ' : ''; + $returnType = $this->returnType !== null ? "{$this->returnType} " : ''; + $parameters = implode(', ', $this->parameters); + $description = $this->description !== '' ? " {$this->description}" : ''; + $templateTypes = count($this->templateTypes) > 0 ? '<' . implode(', ', $this->templateTypes) . '>' : ''; + return "{$static}{$returnType}{$this->methodName}{$templateTypes}({$parameters}){$description}"; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MethodTagValueParameterNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MethodTagValueParameterNode.php new file mode 100644 index 00000000..7c17e44c --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MethodTagValueParameterNode.php @@ -0,0 +1,49 @@ +type = $type; + $this->isReference = $isReference; + $this->isVariadic = $isVariadic; + $this->parameterName = $parameterName; + $this->defaultValue = $defaultValue; + } + + + public function __toString(): string + { + $type = $this->type !== null ? "{$this->type} " : ''; + $isReference = $this->isReference ? '&' : ''; + $isVariadic = $this->isVariadic ? '...' : ''; + $default = $this->defaultValue !== null ? " = {$this->defaultValue}" : ''; + return "{$type}{$isReference}{$isVariadic}{$this->parameterName}{$default}"; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MixinTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MixinTagValueNode.php new file mode 100644 index 00000000..d9b7d78a --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/MixinTagValueNode.php @@ -0,0 +1,32 @@ +type = $type; + $this->description = $description; + } + + + public function __toString(): string + { + return trim("{$this->type} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ParamOutTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ParamOutTagValueNode.php new file mode 100644 index 00000000..9f374bf1 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ParamOutTagValueNode.php @@ -0,0 +1,35 @@ +type = $type; + $this->parameterName = $parameterName; + $this->description = $description; + } + + public function __toString(): string + { + return trim("{$this->type} {$this->parameterName} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ParamTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ParamTagValueNode.php new file mode 100644 index 00000000..f93af0ea --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ParamTagValueNode.php @@ -0,0 +1,46 @@ +type = $type; + $this->isReference = $isReference; + $this->isVariadic = $isVariadic; + $this->parameterName = $parameterName; + $this->description = $description; + } + + + public function __toString(): string + { + $reference = $this->isReference ? '&' : ''; + $variadic = $this->isVariadic ? '...' : ''; + return trim("{$this->type} {$reference}{$variadic}{$this->parameterName} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocChildNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocChildNode.php new file mode 100644 index 00000000..6162f92d --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocChildNode.php @@ -0,0 +1,10 @@ +children = $children; + } + + + /** + * @return PhpDocTagNode[] + */ + public function getTags(): array + { + return array_filter($this->children, static function (PhpDocChildNode $child): bool { + return $child instanceof PhpDocTagNode; + }); + } + + + /** + * @return PhpDocTagNode[] + */ + public function getTagsByName(string $tagName): array + { + return array_filter($this->getTags(), static function (PhpDocTagNode $tag) use ($tagName): bool { + return $tag->name === $tagName; + }); + } + + + /** + * @return VarTagValueNode[] + */ + public function getVarTagValues(string $tagName = '@var'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof VarTagValueNode; + } + ); + } + + + /** + * @return ParamTagValueNode[] + */ + public function getParamTagValues(string $tagName = '@param'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof ParamTagValueNode; + } + ); + } + + + /** + * @return TypelessParamTagValueNode[] + */ + public function getTypelessParamTagValues(string $tagName = '@param'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof TypelessParamTagValueNode; + } + ); + } + + + /** + * @return TemplateTagValueNode[] + */ + public function getTemplateTagValues(string $tagName = '@template'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof TemplateTagValueNode; + } + ); + } + + + /** + * @return ExtendsTagValueNode[] + */ + public function getExtendsTagValues(string $tagName = '@extends'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof ExtendsTagValueNode; + } + ); + } + + + /** + * @return ImplementsTagValueNode[] + */ + public function getImplementsTagValues(string $tagName = '@implements'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof ImplementsTagValueNode; + } + ); + } + + + /** + * @return UsesTagValueNode[] + */ + public function getUsesTagValues(string $tagName = '@use'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof UsesTagValueNode; + } + ); + } + + + /** + * @return ReturnTagValueNode[] + */ + public function getReturnTagValues(string $tagName = '@return'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof ReturnTagValueNode; + } + ); + } + + + /** + * @return ThrowsTagValueNode[] + */ + public function getThrowsTagValues(string $tagName = '@throws'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof ThrowsTagValueNode; + } + ); + } + + + /** + * @return MixinTagValueNode[] + */ + public function getMixinTagValues(string $tagName = '@mixin'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof MixinTagValueNode; + } + ); + } + + + /** + * @return DeprecatedTagValueNode[] + */ + public function getDeprecatedTagValues(): array + { + return array_filter( + array_column($this->getTagsByName('@deprecated'), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof DeprecatedTagValueNode; + } + ); + } + + + /** + * @return PropertyTagValueNode[] + */ + public function getPropertyTagValues(string $tagName = '@property'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof PropertyTagValueNode; + } + ); + } + + + /** + * @return PropertyTagValueNode[] + */ + public function getPropertyReadTagValues(string $tagName = '@property-read'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof PropertyTagValueNode; + } + ); + } + + + /** + * @return PropertyTagValueNode[] + */ + public function getPropertyWriteTagValues(string $tagName = '@property-write'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof PropertyTagValueNode; + } + ); + } + + + /** + * @return MethodTagValueNode[] + */ + public function getMethodTagValues(string $tagName = '@method'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof MethodTagValueNode; + } + ); + } + + + /** + * @return TypeAliasTagValueNode[] + */ + public function getTypeAliasTagValues(string $tagName = '@phpstan-type'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof TypeAliasTagValueNode; + } + ); + } + + + /** + * @return TypeAliasImportTagValueNode[] + */ + public function getTypeAliasImportTagValues(string $tagName = '@phpstan-import-type'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof TypeAliasImportTagValueNode; + } + ); + } + + + /** + * @return AssertTagValueNode[] + */ + public function getAssertTagValues(string $tagName = '@phpstan-assert'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof AssertTagValueNode; + } + ); + } + + + /** + * @return AssertTagPropertyValueNode[] + */ + public function getAssertPropertyTagValues(string $tagName = '@phpstan-assert'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof AssertTagPropertyValueNode; + } + ); + } + + + /** + * @return AssertTagMethodValueNode[] + */ + public function getAssertMethodTagValues(string $tagName = '@phpstan-assert'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof AssertTagMethodValueNode; + } + ); + } + + + /** + * @return SelfOutTagValueNode[] + */ + public function getSelfOutTypeTagValues(string $tagName = '@phpstan-this-out'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof SelfOutTagValueNode; + } + ); + } + + + /** + * @return ParamOutTagValueNode[] + */ + public function getParamOutTypeTagValues(string $tagName = '@param-out'): array + { + return array_filter( + array_column($this->getTagsByName($tagName), 'value'), + static function (PhpDocTagValueNode $value): bool { + return $value instanceof ParamOutTagValueNode; + } + ); + } + + + public function __toString(): string + { + $children = array_map( + static function (PhpDocChildNode $child): string { + $s = (string) $child; + return $s === '' ? '' : ' ' . $s; + }, + $this->children + ); + return "/**\n *" . implode("\n *", $children) . "\n */"; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocTagNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocTagNode.php new file mode 100644 index 00000000..856cc3f1 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocTagNode.php @@ -0,0 +1,31 @@ +name = $name; + $this->value = $value; + } + + + public function __toString(): string + { + return trim("{$this->name} {$this->value}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocTagValueNode.php new file mode 100644 index 00000000..7723fa0c --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PhpDocTagValueNode.php @@ -0,0 +1,10 @@ +text = $text; + } + + + public function __toString(): string + { + return $this->text; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PropertyTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PropertyTagValueNode.php new file mode 100644 index 00000000..046003d1 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/PropertyTagValueNode.php @@ -0,0 +1,36 @@ +type = $type; + $this->propertyName = $propertyName; + $this->description = $description; + } + + + public function __toString(): string + { + return trim("{$this->type} {$this->propertyName} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ReturnTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ReturnTagValueNode.php new file mode 100644 index 00000000..d53c8c75 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ReturnTagValueNode.php @@ -0,0 +1,32 @@ +type = $type; + $this->description = $description; + } + + + public function __toString(): string + { + return trim("{$this->type} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/SelfOutTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/SelfOutTagValueNode.php new file mode 100644 index 00000000..83169aff --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/SelfOutTagValueNode.php @@ -0,0 +1,32 @@ +type = $type; + $this->description = $description; + } + + + public function __toString(): string + { + return trim($this->type . ' ' . $this->description); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TemplateTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TemplateTagValueNode.php new file mode 100644 index 00000000..1d3c70e4 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TemplateTagValueNode.php @@ -0,0 +1,42 @@ +name = $name; + $this->bound = $bound; + $this->default = $default; + $this->description = $description; + } + + + public function __toString(): string + { + $bound = $this->bound !== null ? " of {$this->bound}" : ''; + $default = $this->default !== null ? " = {$this->default}" : ''; + return trim("{$this->name}{$bound}{$default} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ThrowsTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ThrowsTagValueNode.php new file mode 100644 index 00000000..62d2aed3 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/ThrowsTagValueNode.php @@ -0,0 +1,32 @@ +type = $type; + $this->description = $description; + } + + + public function __toString(): string + { + return trim("{$this->type} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypeAliasImportTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypeAliasImportTagValueNode.php new file mode 100644 index 00000000..ad6b85a5 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypeAliasImportTagValueNode.php @@ -0,0 +1,38 @@ +importedAlias = $importedAlias; + $this->importedFrom = $importedFrom; + $this->importedAs = $importedAs; + } + + public function __toString(): string + { + return trim( + "{$this->importedAlias} from {$this->importedFrom}" + . ($this->importedAs !== null ? " as {$this->importedAs}" : '') + ); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypeAliasTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypeAliasTagValueNode.php new file mode 100644 index 00000000..4ccaaac4 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypeAliasTagValueNode.php @@ -0,0 +1,32 @@ +alias = $alias; + $this->type = $type; + } + + + public function __toString(): string + { + return trim("{$this->alias} {$this->type}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypelessParamTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypelessParamTagValueNode.php new file mode 100644 index 00000000..8b982954 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/TypelessParamTagValueNode.php @@ -0,0 +1,41 @@ +isReference = $isReference; + $this->isVariadic = $isVariadic; + $this->parameterName = $parameterName; + $this->description = $description; + } + + + public function __toString(): string + { + $reference = $this->isReference ? '&' : ''; + $variadic = $this->isVariadic ? '...' : ''; + return trim("{$reference}{$variadic}{$this->parameterName} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/UsesTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/UsesTagValueNode.php new file mode 100644 index 00000000..cd573d97 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/UsesTagValueNode.php @@ -0,0 +1,32 @@ +type = $type; + $this->description = $description; + } + + + public function __toString(): string + { + return trim("{$this->type} {$this->description}"); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/VarTagValueNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/VarTagValueNode.php new file mode 100644 index 00000000..afb941a8 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/PhpDoc/VarTagValueNode.php @@ -0,0 +1,36 @@ +type = $type; + $this->variableName = $variableName; + $this->description = $description; + } + + + public function __toString(): string + { + return trim("$this->type " . trim("{$this->variableName} {$this->description}")); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayShapeItemNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayShapeItemNode.php new file mode 100644 index 00000000..660c6c9d --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayShapeItemNode.php @@ -0,0 +1,49 @@ +keyName = $keyName; + $this->optional = $optional; + $this->valueType = $valueType; + } + + + public function __toString(): string + { + if ($this->keyName !== null) { + return sprintf( + '%s%s: %s', + (string) $this->keyName, + $this->optional ? '?' : '', + (string) $this->valueType + ); + } + + return (string) $this->valueType; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayShapeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayShapeNode.php new file mode 100644 index 00000000..41941f80 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayShapeNode.php @@ -0,0 +1,47 @@ +items = $items; + $this->sealed = $sealed; + $this->kind = $kind; + } + + + public function __toString(): string + { + $items = $this->items; + + if (! $this->sealed) { + $items[] = '...'; + } + + return $this->kind . '{' . implode(', ', $items) . '}'; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayTypeNode.php new file mode 100644 index 00000000..90cb9f08 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayTypeNode.php @@ -0,0 +1,26 @@ +type = $type; + } + + + public function __toString(): string + { + return $this->type . '[]'; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/CallableTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/CallableTypeNode.php new file mode 100644 index 00000000..83ade94c --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/CallableTypeNode.php @@ -0,0 +1,36 @@ +identifier = $identifier; + $this->parameters = $parameters; + $this->returnType = $returnType; + } + + + public function __toString(): string + { + $parameters = implode(', ', $this->parameters); + return "{$this->identifier}({$parameters}): {$this->returnType}"; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/CallableTypeParameterNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/CallableTypeParameterNode.php new file mode 100644 index 00000000..7ab2d7e3 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/CallableTypeParameterNode.php @@ -0,0 +1,48 @@ +type = $type; + $this->isReference = $isReference; + $this->isVariadic = $isVariadic; + $this->parameterName = $parameterName; + $this->isOptional = $isOptional; + } + + + public function __toString(): string + { + $type = "{$this->type} "; + $isReference = $this->isReference ? '&' : ''; + $isVariadic = $this->isVariadic ? '...' : ''; + $default = $this->isOptional ? ' = default' : ''; + return trim("{$type}{$isReference}{$isVariadic}{$this->parameterName}") . $default; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConditionalTypeForParameterNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConditionalTypeForParameterNode.php new file mode 100644 index 00000000..fbfcae95 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConditionalTypeForParameterNode.php @@ -0,0 +1,49 @@ +parameterName = $parameterName; + $this->targetType = $targetType; + $this->if = $if; + $this->else = $else; + $this->negated = $negated; + } + + public function __toString(): string + { + return sprintf( + '(%s %s %s ? %s : %s)', + $this->parameterName, + $this->negated ? 'is not' : 'is', + $this->targetType, + $this->if, + $this->else + ); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConditionalTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConditionalTypeNode.php new file mode 100644 index 00000000..bfdb0db1 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConditionalTypeNode.php @@ -0,0 +1,49 @@ +subjectType = $subjectType; + $this->targetType = $targetType; + $this->if = $if; + $this->else = $else; + $this->negated = $negated; + } + + public function __toString(): string + { + return sprintf( + '(%s %s %s ? %s : %s)', + $this->subjectType, + $this->negated ? 'is not' : 'is', + $this->targetType, + $this->if, + $this->else + ); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConstTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConstTypeNode.php new file mode 100644 index 00000000..0096055b --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ConstTypeNode.php @@ -0,0 +1,26 @@ +constExpr = $constExpr; + } + + public function __toString(): string + { + return $this->constExpr->__toString(); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/GenericTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/GenericTypeNode.php new file mode 100644 index 00000000..179de55a --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/GenericTypeNode.php @@ -0,0 +1,54 @@ +type = $type; + $this->genericTypes = $genericTypes; + $this->variances = $variances; + } + + + public function __toString(): string + { + $genericTypes = []; + + foreach ($this->genericTypes as $index => $type) { + $variance = $this->variances[$index] ?? self::VARIANCE_INVARIANT; + if ($variance === self::VARIANCE_INVARIANT) { + $genericTypes[] = (string) $type; + } elseif ($variance === self::VARIANCE_BIVARIANT) { + $genericTypes[] = '*'; + } else { + $genericTypes[] = sprintf('%s %s', $variance, $type); + } + } + + return $this->type . '<' . implode(', ', $genericTypes) . '>'; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/IdentifierTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/IdentifierTypeNode.php new file mode 100644 index 00000000..29bac308 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/IdentifierTypeNode.php @@ -0,0 +1,26 @@ +name = $name; + } + + + public function __toString(): string + { + return $this->name; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/IntersectionTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/IntersectionTypeNode.php new file mode 100644 index 00000000..7f9aff33 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/IntersectionTypeNode.php @@ -0,0 +1,27 @@ +types = $types; + } + + + public function __toString(): string + { + return '(' . implode(' & ', $this->types) . ')'; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/NullableTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/NullableTypeNode.php new file mode 100644 index 00000000..73f438cd --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/NullableTypeNode.php @@ -0,0 +1,26 @@ +type = $type; + } + + + public function __toString(): string + { + return '?' . $this->type; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/OffsetAccessTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/OffsetAccessTypeNode.php new file mode 100644 index 00000000..1d5b04ef --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/OffsetAccessTypeNode.php @@ -0,0 +1,29 @@ +type = $type; + $this->offset = $offset; + } + + public function __toString(): string + { + return $this->type . '[' . $this->offset . ']'; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Ast/Type/ThisTypeNode.php b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ThisTypeNode.php new file mode 100644 index 00000000..d94e6f83 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Ast/Type/ThisTypeNode.php @@ -0,0 +1,17 @@ +types = $types; + } + + + public function __toString(): string + { + return '(' . implode(' | ', $this->types) . ')'; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Lexer/Lexer.php b/vendor/phpstan/phpdoc-parser/src/Lexer/Lexer.php new file mode 100644 index 00000000..1b98839d --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Lexer/Lexer.php @@ -0,0 +1,170 @@ + '\'&\'', + self::TOKEN_UNION => '\'|\'', + self::TOKEN_INTERSECTION => '\'&\'', + self::TOKEN_NULLABLE => '\'?\'', + self::TOKEN_NEGATED => '\'!\'', + self::TOKEN_OPEN_PARENTHESES => '\'(\'', + self::TOKEN_CLOSE_PARENTHESES => '\')\'', + self::TOKEN_OPEN_ANGLE_BRACKET => '\'<\'', + self::TOKEN_CLOSE_ANGLE_BRACKET => '\'>\'', + self::TOKEN_OPEN_SQUARE_BRACKET => '\'[\'', + self::TOKEN_CLOSE_SQUARE_BRACKET => '\']\'', + self::TOKEN_OPEN_CURLY_BRACKET => '\'{\'', + self::TOKEN_CLOSE_CURLY_BRACKET => '\'}\'', + self::TOKEN_COMMA => '\',\'', + self::TOKEN_COLON => '\':\'', + self::TOKEN_VARIADIC => '\'...\'', + self::TOKEN_DOUBLE_COLON => '\'::\'', + self::TOKEN_DOUBLE_ARROW => '\'=>\'', + self::TOKEN_ARROW => '\'->\'', + self::TOKEN_EQUAL => '\'=\'', + self::TOKEN_OPEN_PHPDOC => '\'/**\'', + self::TOKEN_CLOSE_PHPDOC => '\'*/\'', + self::TOKEN_PHPDOC_TAG => 'TOKEN_PHPDOC_TAG', + self::TOKEN_PHPDOC_EOL => 'TOKEN_PHPDOC_EOL', + self::TOKEN_FLOAT => 'TOKEN_FLOAT', + self::TOKEN_INTEGER => 'TOKEN_INTEGER', + self::TOKEN_SINGLE_QUOTED_STRING => 'TOKEN_SINGLE_QUOTED_STRING', + self::TOKEN_DOUBLE_QUOTED_STRING => 'TOKEN_DOUBLE_QUOTED_STRING', + self::TOKEN_IDENTIFIER => 'type', + self::TOKEN_THIS_VARIABLE => '\'$this\'', + self::TOKEN_VARIABLE => 'variable', + self::TOKEN_HORIZONTAL_WS => 'TOKEN_HORIZONTAL_WS', + self::TOKEN_OTHER => 'TOKEN_OTHER', + self::TOKEN_END => 'TOKEN_END', + self::TOKEN_WILDCARD => '*', + ]; + + public const VALUE_OFFSET = 0; + public const TYPE_OFFSET = 1; + + /** @var string|null */ + private $regexp; + + public function tokenize(string $s): array + { + if ($this->regexp === null) { + $this->regexp = $this->generateRegexp(); + } + + preg_match_all($this->regexp, $s, $matches, PREG_SET_ORDER); + + $tokens = []; + foreach ($matches as $match) { + $tokens[] = [$match[0], (int) $match['MARK']]; + } + + $tokens[] = ['', self::TOKEN_END]; + + return $tokens; + } + + + private function generateRegexp(): string + { + $patterns = [ + self::TOKEN_HORIZONTAL_WS => '[\\x09\\x20]++', + + self::TOKEN_IDENTIFIER => '(?:[\\\\]?+[a-z_\\x80-\\xFF][0-9a-z_\\x80-\\xFF-]*+)++', + self::TOKEN_THIS_VARIABLE => '\\$this(?![0-9a-z_\\x80-\\xFF])', + self::TOKEN_VARIABLE => '\\$[a-z_\\x80-\\xFF][0-9a-z_\\x80-\\xFF]*+', + + // '&' followed by TOKEN_VARIADIC, TOKEN_VARIABLE, TOKEN_EQUAL, TOKEN_EQUAL or TOKEN_CLOSE_PARENTHESES + self::TOKEN_REFERENCE => '&(?=\\s*+(?:[.,=)]|(?:\\$(?!this(?![0-9a-z_\\x80-\\xFF])))))', + self::TOKEN_UNION => '\\|', + self::TOKEN_INTERSECTION => '&', + self::TOKEN_NULLABLE => '\\?', + self::TOKEN_NEGATED => '!', + + self::TOKEN_OPEN_PARENTHESES => '\\(', + self::TOKEN_CLOSE_PARENTHESES => '\\)', + self::TOKEN_OPEN_ANGLE_BRACKET => '<', + self::TOKEN_CLOSE_ANGLE_BRACKET => '>', + self::TOKEN_OPEN_SQUARE_BRACKET => '\\[', + self::TOKEN_CLOSE_SQUARE_BRACKET => '\\]', + self::TOKEN_OPEN_CURLY_BRACKET => '\\{', + self::TOKEN_CLOSE_CURLY_BRACKET => '\\}', + + self::TOKEN_COMMA => ',', + self::TOKEN_VARIADIC => '\\.\\.\\.', + self::TOKEN_DOUBLE_COLON => '::', + self::TOKEN_DOUBLE_ARROW => '=>', + self::TOKEN_ARROW => '->', + self::TOKEN_EQUAL => '=', + self::TOKEN_COLON => ':', + + self::TOKEN_OPEN_PHPDOC => '/\\*\\*(?=\\s)\\x20?+', + self::TOKEN_CLOSE_PHPDOC => '\\*/', + self::TOKEN_PHPDOC_TAG => '@(?:[a-z][a-z0-9-\\\\]+:)?[a-z][a-z0-9-\\\\]*+', + self::TOKEN_PHPDOC_EOL => '\\r?+\\n[\\x09\\x20]*+(?:\\*(?!/)\\x20?+)?', + + self::TOKEN_FLOAT => '(?:-?[0-9]++\\.[0-9]*+(?:e-?[0-9]++)?)|(?:-?[0-9]*+\\.[0-9]++(?:e-?[0-9]++)?)|(?:-?[0-9]++e-?[0-9]++)', + self::TOKEN_INTEGER => '-?(?:(?:0b[0-1]++)|(?:0o[0-7]++)|(?:0x[0-9a-f]++)|(?:[0-9]++))', + self::TOKEN_SINGLE_QUOTED_STRING => '\'(?:\\\\[^\\r\\n]|[^\'\\r\\n\\\\])*+\'', + self::TOKEN_DOUBLE_QUOTED_STRING => '"(?:\\\\[^\\r\\n]|[^"\\r\\n\\\\])*+"', + + self::TOKEN_WILDCARD => '\\*', + + // anything but TOKEN_CLOSE_PHPDOC or TOKEN_HORIZONTAL_WS or TOKEN_EOL + self::TOKEN_OTHER => '(?:(?!\\*/)[^\\s])++', + ]; + + foreach ($patterns as $type => &$pattern) { + $pattern = '(?:' . $pattern . ')(*MARK:' . $type . ')'; + } + + return '~' . implode('|', $patterns) . '~Asi'; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Parser/ConstExprParser.php b/vendor/phpstan/phpdoc-parser/src/Parser/ConstExprParser.php new file mode 100644 index 00000000..d7876303 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Parser/ConstExprParser.php @@ -0,0 +1,230 @@ + '\\', + 'n' => "\n", + 'r' => "\r", + 't' => "\t", + 'f' => "\f", + 'v' => "\v", + 'e' => "\x1B", + ]; + + /** @var bool */ + private $unescapeStrings; + + public function __construct(bool $unescapeStrings = false) + { + $this->unescapeStrings = $unescapeStrings; + } + + public function parse(TokenIterator $tokens, bool $trimStrings = false): Ast\ConstExpr\ConstExprNode + { + if ($tokens->isCurrentTokenType(Lexer::TOKEN_FLOAT)) { + $value = $tokens->currentTokenValue(); + $tokens->next(); + return new Ast\ConstExpr\ConstExprFloatNode($value); + } + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_INTEGER)) { + $value = $tokens->currentTokenValue(); + $tokens->next(); + return new Ast\ConstExpr\ConstExprIntegerNode($value); + } + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_SINGLE_QUOTED_STRING, Lexer::TOKEN_DOUBLE_QUOTED_STRING)) { + $value = $tokens->currentTokenValue(); + if ($trimStrings) { + if ($this->unescapeStrings) { + $value = self::unescapeString($value); + } else { + $value = substr($value, 1, -1); + } + } + $tokens->next(); + return new Ast\ConstExpr\ConstExprStringNode($value); + + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_IDENTIFIER)) { + $identifier = $tokens->currentTokenValue(); + $tokens->next(); + + switch (strtolower($identifier)) { + case 'true': + return new Ast\ConstExpr\ConstExprTrueNode(); + case 'false': + return new Ast\ConstExpr\ConstExprFalseNode(); + case 'null': + return new Ast\ConstExpr\ConstExprNullNode(); + case 'array': + $tokens->consumeTokenType(Lexer::TOKEN_OPEN_PARENTHESES); + return $this->parseArray($tokens, Lexer::TOKEN_CLOSE_PARENTHESES); + } + + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_DOUBLE_COLON)) { + $classConstantName = ''; + $lastType = null; + while (true) { + if ($lastType !== Lexer::TOKEN_IDENTIFIER && $tokens->currentTokenType() === Lexer::TOKEN_IDENTIFIER) { + $classConstantName .= $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + $lastType = Lexer::TOKEN_IDENTIFIER; + + continue; + } + + if ($lastType !== Lexer::TOKEN_WILDCARD && $tokens->tryConsumeTokenType(Lexer::TOKEN_WILDCARD)) { + $classConstantName .= '*'; + $lastType = Lexer::TOKEN_WILDCARD; + + if ($tokens->getSkippedHorizontalWhiteSpaceIfAny() !== '') { + break; + } + + continue; + } + + if ($lastType === null) { + // trigger parse error if nothing valid was consumed + $tokens->consumeTokenType(Lexer::TOKEN_WILDCARD); + } + + break; + } + + return new Ast\ConstExpr\ConstFetchNode($identifier, $classConstantName); + + } + + return new Ast\ConstExpr\ConstFetchNode('', $identifier); + + } elseif ($tokens->tryConsumeTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET)) { + return $this->parseArray($tokens, Lexer::TOKEN_CLOSE_SQUARE_BRACKET); + } + + throw new ParserException( + $tokens->currentTokenValue(), + $tokens->currentTokenType(), + $tokens->currentTokenOffset(), + Lexer::TOKEN_IDENTIFIER + ); + } + + + private function parseArray(TokenIterator $tokens, int $endToken): Ast\ConstExpr\ConstExprArrayNode + { + $items = []; + + if (!$tokens->tryConsumeTokenType($endToken)) { + do { + $items[] = $this->parseArrayItem($tokens); + } while ($tokens->tryConsumeTokenType(Lexer::TOKEN_COMMA) && !$tokens->isCurrentTokenType($endToken)); + $tokens->consumeTokenType($endToken); + } + + return new Ast\ConstExpr\ConstExprArrayNode($items); + } + + + private function parseArrayItem(TokenIterator $tokens): Ast\ConstExpr\ConstExprArrayItemNode + { + $expr = $this->parse($tokens); + + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_DOUBLE_ARROW)) { + $key = $expr; + $value = $this->parse($tokens); + + } else { + $key = null; + $value = $expr; + } + + return new Ast\ConstExpr\ConstExprArrayItemNode($key, $value); + } + + private static function unescapeString(string $string): string + { + $quote = $string[0]; + + if ($quote === '\'') { + return str_replace( + ['\\\\', '\\\''], + ['\\', '\''], + substr($string, 1, -1) + ); + } + + return self::parseEscapeSequences(substr($string, 1, -1), '"'); + } + + /** + * Implementation based on https://github.com/nikic/PHP-Parser/blob/b0edd4c41111042d43bb45c6c657b2e0db367d9e/lib/PhpParser/Node/Scalar/String_.php#L90-L130 + */ + private static function parseEscapeSequences(string $str, string $quote): string + { + $str = str_replace('\\' . $quote, $quote, $str); + + return preg_replace_callback( + '~\\\\([\\\\nrtfve]|[xX][0-9a-fA-F]{1,2}|[0-7]{1,3}|u\{([0-9a-fA-F]+)\})~', + static function ($matches) { + $str = $matches[1]; + + if (isset(self::REPLACEMENTS[$str])) { + return self::REPLACEMENTS[$str]; + } + if ($str[0] === 'x' || $str[0] === 'X') { + return chr(hexdec(substr($str, 1))); + } + if ($str[0] === 'u') { + return self::codePointToUtf8(hexdec($matches[2])); + } + + return chr(octdec($str)); + }, + $str + ); + } + + /** + * Implementation based on https://github.com/nikic/PHP-Parser/blob/b0edd4c41111042d43bb45c6c657b2e0db367d9e/lib/PhpParser/Node/Scalar/String_.php#L132-L154 + */ + private static function codePointToUtf8(int $num): string + { + if ($num <= 0x7F) { + return chr($num); + } + if ($num <= 0x7FF) { + return chr(($num >> 6) + 0xC0) + . chr(($num & 0x3F) + 0x80); + } + if ($num <= 0xFFFF) { + return chr(($num >> 12) + 0xE0) + . chr((($num >> 6) & 0x3F) + 0x80) + . chr(($num & 0x3F) + 0x80); + } + if ($num <= 0x1FFFFF) { + return chr(($num >> 18) + 0xF0) + . chr((($num >> 12) & 0x3F) + 0x80) + . chr((($num >> 6) & 0x3F) + 0x80) + . chr(($num & 0x3F) + 0x80); + } + + // Invalid UTF-8 codepoint escape sequence: Codepoint too large + return "\xef\xbf\xbd"; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Parser/ParserException.php b/vendor/phpstan/phpdoc-parser/src/Parser/ParserException.php new file mode 100644 index 00000000..badcdcbb --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Parser/ParserException.php @@ -0,0 +1,93 @@ +currentTokenValue = $currentTokenValue; + $this->currentTokenType = $currentTokenType; + $this->currentOffset = $currentOffset; + $this->expectedTokenType = $expectedTokenType; + $this->expectedTokenValue = $expectedTokenValue; + + parent::__construct(sprintf( + 'Unexpected token %s, expected %s%s at offset %d', + $this->formatValue($currentTokenValue), + Lexer::TOKEN_LABELS[$expectedTokenType], + $expectedTokenValue !== null ? sprintf(' (%s)', $this->formatValue($expectedTokenValue)) : '', + $currentOffset + )); + } + + + public function getCurrentTokenValue(): string + { + return $this->currentTokenValue; + } + + + public function getCurrentTokenType(): int + { + return $this->currentTokenType; + } + + + public function getCurrentOffset(): int + { + return $this->currentOffset; + } + + + public function getExpectedTokenType(): int + { + return $this->expectedTokenType; + } + + + public function getExpectedTokenValue(): ?string + { + return $this->expectedTokenValue; + } + + + private function formatValue(string $value): string + { + $json = json_encode($value, JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES); + assert($json !== false); + + return $json; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Parser/PhpDocParser.php b/vendor/phpstan/phpdoc-parser/src/Parser/PhpDocParser.php new file mode 100644 index 00000000..d9942b3d --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Parser/PhpDocParser.php @@ -0,0 +1,598 @@ +typeParser = $typeParser; + $this->constantExprParser = $constantExprParser; + $this->requireWhitespaceBeforeDescription = $requireWhitespaceBeforeDescription; + } + + + public function parse(TokenIterator $tokens): Ast\PhpDoc\PhpDocNode + { + $tokens->consumeTokenType(Lexer::TOKEN_OPEN_PHPDOC); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + $children = []; + + if (!$tokens->isCurrentTokenType(Lexer::TOKEN_CLOSE_PHPDOC)) { + $children[] = $this->parseChild($tokens); + while ($tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL) && !$tokens->isCurrentTokenType(Lexer::TOKEN_CLOSE_PHPDOC)) { + $children[] = $this->parseChild($tokens); + } + } + + try { + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_PHPDOC); + } catch (ParserException $e) { + $name = ''; + if (count($children) > 0) { + $lastChild = $children[count($children) - 1]; + if ($lastChild instanceof Ast\PhpDoc\PhpDocTagNode) { + $name = $lastChild->name; + } + } + $tokens->forwardToTheEnd(); + return new Ast\PhpDoc\PhpDocNode([ + new Ast\PhpDoc\PhpDocTagNode($name, new Ast\PhpDoc\InvalidTagValueNode($e->getMessage(), $e)), + ]); + } + + return new Ast\PhpDoc\PhpDocNode(array_values($children)); + } + + + private function parseChild(TokenIterator $tokens): Ast\PhpDoc\PhpDocChildNode + { + if ($tokens->isCurrentTokenType(Lexer::TOKEN_PHPDOC_TAG)) { + return $this->parseTag($tokens); + + } + + return $this->parseText($tokens); + } + + + private function parseText(TokenIterator $tokens): Ast\PhpDoc\PhpDocTextNode + { + $text = ''; + + while (!$tokens->isCurrentTokenType(Lexer::TOKEN_PHPDOC_EOL)) { + $text .= $tokens->getSkippedHorizontalWhiteSpaceIfAny() . $tokens->joinUntil(Lexer::TOKEN_PHPDOC_EOL, Lexer::TOKEN_CLOSE_PHPDOC, Lexer::TOKEN_END); + + if (!$tokens->isCurrentTokenType(Lexer::TOKEN_PHPDOC_EOL)) { + break; + } + + $tokens->pushSavePoint(); + $tokens->next(); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_PHPDOC_TAG, Lexer::TOKEN_PHPDOC_EOL, Lexer::TOKEN_CLOSE_PHPDOC, Lexer::TOKEN_END)) { + $tokens->rollback(); + break; + } + + $tokens->dropSavePoint(); + $text .= "\n"; + } + + return new Ast\PhpDoc\PhpDocTextNode(trim($text, " \t")); + } + + + public function parseTag(TokenIterator $tokens): Ast\PhpDoc\PhpDocTagNode + { + $tag = $tokens->currentTokenValue(); + $tokens->next(); + $value = $this->parseTagValue($tokens, $tag); + + return new Ast\PhpDoc\PhpDocTagNode($tag, $value); + } + + + public function parseTagValue(TokenIterator $tokens, string $tag): Ast\PhpDoc\PhpDocTagValueNode + { + try { + $tokens->pushSavePoint(); + + switch ($tag) { + case '@param': + case '@phpstan-param': + case '@psalm-param': + $tagValue = $this->parseParamTagValue($tokens); + break; + + case '@var': + case '@phpstan-var': + case '@psalm-var': + $tagValue = $this->parseVarTagValue($tokens); + break; + + case '@return': + case '@phpstan-return': + case '@psalm-return': + $tagValue = $this->parseReturnTagValue($tokens); + break; + + case '@throws': + case '@phpstan-throws': + $tagValue = $this->parseThrowsTagValue($tokens); + break; + + case '@mixin': + $tagValue = $this->parseMixinTagValue($tokens); + break; + + case '@deprecated': + $tagValue = $this->parseDeprecatedTagValue($tokens); + break; + + case '@property': + case '@property-read': + case '@property-write': + case '@phpstan-property': + case '@phpstan-property-read': + case '@phpstan-property-write': + case '@psalm-property': + case '@psalm-property-read': + case '@psalm-property-write': + $tagValue = $this->parsePropertyTagValue($tokens); + break; + + case '@method': + case '@phpstan-method': + case '@psalm-method': + $tagValue = $this->parseMethodTagValue($tokens); + break; + + case '@template': + case '@phpstan-template': + case '@psalm-template': + case '@template-covariant': + case '@phpstan-template-covariant': + case '@psalm-template-covariant': + case '@template-contravariant': + case '@phpstan-template-contravariant': + case '@psalm-template-contravariant': + $tagValue = $this->parseTemplateTagValue($tokens, true); + break; + + case '@extends': + case '@phpstan-extends': + case '@template-extends': + $tagValue = $this->parseExtendsTagValue('@extends', $tokens); + break; + + case '@implements': + case '@phpstan-implements': + case '@template-implements': + $tagValue = $this->parseExtendsTagValue('@implements', $tokens); + break; + + case '@use': + case '@phpstan-use': + case '@template-use': + $tagValue = $this->parseExtendsTagValue('@use', $tokens); + break; + + case '@phpstan-type': + case '@psalm-type': + $tagValue = $this->parseTypeAliasTagValue($tokens); + break; + + case '@phpstan-import-type': + case '@psalm-import-type': + $tagValue = $this->parseTypeAliasImportTagValue($tokens); + break; + + case '@phpstan-assert': + case '@phpstan-assert-if-true': + case '@phpstan-assert-if-false': + case '@psalm-assert': + case '@psalm-assert-if-true': + case '@psalm-assert-if-false': + $tagValue = $this->parseAssertTagValue($tokens); + break; + + case '@phpstan-this-out': + case '@phpstan-self-out': + case '@psalm-this-out': + case '@psalm-self-out': + $tagValue = $this->parseSelfOutTagValue($tokens); + break; + + case '@param-out': + case '@phpstan-param-out': + case '@psalm-param-out': + $tagValue = $this->parseParamOutTagValue($tokens); + break; + + default: + $tagValue = new Ast\PhpDoc\GenericTagValueNode($this->parseOptionalDescription($tokens)); + break; + } + + $tokens->dropSavePoint(); + + } catch (ParserException $e) { + $tokens->rollback(); + $tagValue = new Ast\PhpDoc\InvalidTagValueNode($this->parseOptionalDescription($tokens), $e); + } + + return $tagValue; + } + + + /** + * @return Ast\PhpDoc\ParamTagValueNode|Ast\PhpDoc\TypelessParamTagValueNode + */ + private function parseParamTagValue(TokenIterator $tokens): Ast\PhpDoc\PhpDocTagValueNode + { + if ( + $tokens->isCurrentTokenType(Lexer::TOKEN_REFERENCE) + || $tokens->isCurrentTokenType(Lexer::TOKEN_VARIADIC) + || $tokens->isCurrentTokenType(Lexer::TOKEN_VARIABLE) + ) { + $type = null; + } else { + $type = $this->typeParser->parse($tokens); + } + + $isReference = $tokens->tryConsumeTokenType(Lexer::TOKEN_REFERENCE); + $isVariadic = $tokens->tryConsumeTokenType(Lexer::TOKEN_VARIADIC); + $parameterName = $this->parseRequiredVariableName($tokens); + $description = $this->parseOptionalDescription($tokens); + + if ($type !== null) { + return new Ast\PhpDoc\ParamTagValueNode($type, $isVariadic, $parameterName, $description, $isReference); + } + + return new Ast\PhpDoc\TypelessParamTagValueNode($isVariadic, $parameterName, $description, $isReference); + } + + + private function parseVarTagValue(TokenIterator $tokens): Ast\PhpDoc\VarTagValueNode + { + $type = $this->typeParser->parse($tokens); + $variableName = $this->parseOptionalVariableName($tokens); + $description = $this->parseOptionalDescription($tokens, $variableName === ''); + return new Ast\PhpDoc\VarTagValueNode($type, $variableName, $description); + } + + + private function parseReturnTagValue(TokenIterator $tokens): Ast\PhpDoc\ReturnTagValueNode + { + $type = $this->typeParser->parse($tokens); + $description = $this->parseOptionalDescription($tokens, true); + return new Ast\PhpDoc\ReturnTagValueNode($type, $description); + } + + + private function parseThrowsTagValue(TokenIterator $tokens): Ast\PhpDoc\ThrowsTagValueNode + { + $type = $this->typeParser->parse($tokens); + $description = $this->parseOptionalDescription($tokens, true); + return new Ast\PhpDoc\ThrowsTagValueNode($type, $description); + } + + private function parseMixinTagValue(TokenIterator $tokens): Ast\PhpDoc\MixinTagValueNode + { + $type = $this->typeParser->parse($tokens); + $description = $this->parseOptionalDescription($tokens, true); + return new Ast\PhpDoc\MixinTagValueNode($type, $description); + } + + private function parseDeprecatedTagValue(TokenIterator $tokens): Ast\PhpDoc\DeprecatedTagValueNode + { + $description = $this->parseOptionalDescription($tokens); + return new Ast\PhpDoc\DeprecatedTagValueNode($description); + } + + + private function parsePropertyTagValue(TokenIterator $tokens): Ast\PhpDoc\PropertyTagValueNode + { + $type = $this->typeParser->parse($tokens); + $parameterName = $this->parseRequiredVariableName($tokens); + $description = $this->parseOptionalDescription($tokens); + return new Ast\PhpDoc\PropertyTagValueNode($type, $parameterName, $description); + } + + + private function parseMethodTagValue(TokenIterator $tokens): Ast\PhpDoc\MethodTagValueNode + { + $isStatic = $tokens->tryConsumeTokenValue('static'); + $returnTypeOrMethodName = $this->typeParser->parse($tokens); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_IDENTIFIER)) { + $returnType = $returnTypeOrMethodName; + $methodName = $tokens->currentTokenValue(); + $tokens->next(); + + } elseif ($returnTypeOrMethodName instanceof Ast\Type\IdentifierTypeNode) { + $returnType = $isStatic ? new Ast\Type\IdentifierTypeNode('static') : null; + $methodName = $returnTypeOrMethodName->name; + $isStatic = false; + + } else { + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); // will throw exception + exit; + } + + $templateTypes = []; + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_OPEN_ANGLE_BRACKET)) { + do { + $templateTypes[] = $this->parseTemplateTagValue($tokens, false); + } while ($tokens->tryConsumeTokenType(Lexer::TOKEN_COMMA)); + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_ANGLE_BRACKET); + } + + $parameters = []; + $tokens->consumeTokenType(Lexer::TOKEN_OPEN_PARENTHESES); + if (!$tokens->isCurrentTokenType(Lexer::TOKEN_CLOSE_PARENTHESES)) { + $parameters[] = $this->parseMethodTagValueParameter($tokens); + while ($tokens->tryConsumeTokenType(Lexer::TOKEN_COMMA)) { + $parameters[] = $this->parseMethodTagValueParameter($tokens); + } + } + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_PARENTHESES); + + $description = $this->parseOptionalDescription($tokens); + return new Ast\PhpDoc\MethodTagValueNode($isStatic, $returnType, $methodName, $parameters, $description, $templateTypes); + } + + private function parseMethodTagValueParameter(TokenIterator $tokens): Ast\PhpDoc\MethodTagValueParameterNode + { + switch ($tokens->currentTokenType()) { + case Lexer::TOKEN_IDENTIFIER: + case Lexer::TOKEN_OPEN_PARENTHESES: + case Lexer::TOKEN_NULLABLE: + $parameterType = $this->typeParser->parse($tokens); + break; + + default: + $parameterType = null; + } + + $isReference = $tokens->tryConsumeTokenType(Lexer::TOKEN_REFERENCE); + $isVariadic = $tokens->tryConsumeTokenType(Lexer::TOKEN_VARIADIC); + + $parameterName = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_VARIABLE); + + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_EQUAL)) { + $defaultValue = $this->constantExprParser->parse($tokens); + + } else { + $defaultValue = null; + } + + return new Ast\PhpDoc\MethodTagValueParameterNode($parameterType, $isReference, $isVariadic, $parameterName, $defaultValue); + } + + private function parseTemplateTagValue(TokenIterator $tokens, bool $parseDescription): Ast\PhpDoc\TemplateTagValueNode + { + $name = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + + if ($tokens->tryConsumeTokenValue('of') || $tokens->tryConsumeTokenValue('as')) { + $bound = $this->typeParser->parse($tokens); + + } else { + $bound = null; + } + + if ($tokens->tryConsumeTokenValue('=')) { + $default = $this->typeParser->parse($tokens); + } else { + $default = null; + } + + if ($parseDescription) { + $description = $this->parseOptionalDescription($tokens); + } else { + $description = ''; + } + + return new Ast\PhpDoc\TemplateTagValueNode($name, $bound, $description, $default); + } + + private function parseExtendsTagValue(string $tagName, TokenIterator $tokens): Ast\PhpDoc\PhpDocTagValueNode + { + $baseType = new IdentifierTypeNode($tokens->currentTokenValue()); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + + $type = $this->typeParser->parseGeneric($tokens, $baseType); + + $description = $this->parseOptionalDescription($tokens); + + switch ($tagName) { + case '@extends': + return new Ast\PhpDoc\ExtendsTagValueNode($type, $description); + case '@implements': + return new Ast\PhpDoc\ImplementsTagValueNode($type, $description); + case '@use': + return new Ast\PhpDoc\UsesTagValueNode($type, $description); + } + + throw new ShouldNotHappenException(); + } + + private function parseTypeAliasTagValue(TokenIterator $tokens): Ast\PhpDoc\TypeAliasTagValueNode + { + $alias = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + + // support psalm-type syntax + $tokens->tryConsumeTokenType(Lexer::TOKEN_EQUAL); + + $type = $this->typeParser->parse($tokens); + + return new Ast\PhpDoc\TypeAliasTagValueNode($alias, $type); + } + + private function parseTypeAliasImportTagValue(TokenIterator $tokens): Ast\PhpDoc\TypeAliasImportTagValueNode + { + $importedAlias = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + + $tokens->consumeTokenValue(Lexer::TOKEN_IDENTIFIER, 'from'); + + $importedFrom = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + + $importedAs = null; + if ($tokens->tryConsumeTokenValue('as')) { + $importedAs = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + } + + return new Ast\PhpDoc\TypeAliasImportTagValueNode($importedAlias, new IdentifierTypeNode($importedFrom), $importedAs); + } + + /** + * @return Ast\PhpDoc\AssertTagValueNode|Ast\PhpDoc\AssertTagPropertyValueNode|Ast\PhpDoc\AssertTagMethodValueNode + */ + private function parseAssertTagValue(TokenIterator $tokens): Ast\PhpDoc\PhpDocTagValueNode + { + $isNegated = $tokens->tryConsumeTokenType(Lexer::TOKEN_NEGATED); + $isEquality = $tokens->tryConsumeTokenType(Lexer::TOKEN_EQUAL); + $type = $this->typeParser->parse($tokens); + $parameter = $this->parseAssertParameter($tokens); + $description = $this->parseOptionalDescription($tokens); + + if (array_key_exists('method', $parameter)) { + return new Ast\PhpDoc\AssertTagMethodValueNode($type, $parameter['parameter'], $parameter['method'], $isNegated, $description, $isEquality); + } elseif (array_key_exists('property', $parameter)) { + return new Ast\PhpDoc\AssertTagPropertyValueNode($type, $parameter['parameter'], $parameter['property'], $isNegated, $description, $isEquality); + } + + return new Ast\PhpDoc\AssertTagValueNode($type, $parameter['parameter'], $isNegated, $description, $isEquality); + } + + /** + * @return array{parameter: string}|array{parameter: string, property: string}|array{parameter: string, method: string} + */ + private function parseAssertParameter(TokenIterator $tokens): array + { + if ($tokens->isCurrentTokenType(Lexer::TOKEN_THIS_VARIABLE)) { + $parameter = '$this'; + $requirePropertyOrMethod = true; + $tokens->next(); + } else { + $parameter = $tokens->currentTokenValue(); + $requirePropertyOrMethod = false; + $tokens->consumeTokenType(Lexer::TOKEN_VARIABLE); + } + + if ($requirePropertyOrMethod || $tokens->isCurrentTokenType(Lexer::TOKEN_ARROW)) { + $tokens->consumeTokenType(Lexer::TOKEN_ARROW); + + $propertyOrMethod = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_OPEN_PARENTHESES)) { + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_PARENTHESES); + + return ['parameter' => $parameter, 'method' => $propertyOrMethod]; + } + + return ['parameter' => $parameter, 'property' => $propertyOrMethod]; + } + + return ['parameter' => $parameter]; + } + + private function parseSelfOutTagValue(TokenIterator $tokens): Ast\PhpDoc\SelfOutTagValueNode + { + $type = $this->typeParser->parse($tokens); + $description = $this->parseOptionalDescription($tokens); + + return new Ast\PhpDoc\SelfOutTagValueNode($type, $description); + } + + private function parseParamOutTagValue(TokenIterator $tokens): Ast\PhpDoc\ParamOutTagValueNode + { + $type = $this->typeParser->parse($tokens); + $parameterName = $this->parseRequiredVariableName($tokens); + $description = $this->parseOptionalDescription($tokens); + + return new Ast\PhpDoc\ParamOutTagValueNode($type, $parameterName, $description); + } + + private function parseOptionalVariableName(TokenIterator $tokens): string + { + if ($tokens->isCurrentTokenType(Lexer::TOKEN_VARIABLE)) { + $parameterName = $tokens->currentTokenValue(); + $tokens->next(); + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_THIS_VARIABLE)) { + $parameterName = '$this'; + $tokens->next(); + + } else { + $parameterName = ''; + } + + return $parameterName; + } + + + private function parseRequiredVariableName(TokenIterator $tokens): string + { + $parameterName = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_VARIABLE); + + return $parameterName; + } + + private function parseOptionalDescription(TokenIterator $tokens, bool $limitStartToken = false): string + { + if ($limitStartToken) { + foreach (self::DISALLOWED_DESCRIPTION_START_TOKENS as $disallowedStartToken) { + if (!$tokens->isCurrentTokenType($disallowedStartToken)) { + continue; + } + + $tokens->consumeTokenType(Lexer::TOKEN_OTHER); // will throw exception + } + + if ( + $this->requireWhitespaceBeforeDescription + && !$tokens->isCurrentTokenType(Lexer::TOKEN_PHPDOC_EOL, Lexer::TOKEN_CLOSE_PHPDOC, Lexer::TOKEN_END) + && !$tokens->isPrecededByHorizontalWhitespace() + ) { + $tokens->consumeTokenType(Lexer::TOKEN_HORIZONTAL_WS); // will throw exception + } + } + + return $this->parseText($tokens)->text; + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Parser/TokenIterator.php b/vendor/phpstan/phpdoc-parser/src/Parser/TokenIterator.php new file mode 100644 index 00000000..569a9321 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Parser/TokenIterator.php @@ -0,0 +1,224 @@ +tokens = $tokens; + $this->index = $index; + + if ($this->tokens[$this->index][Lexer::TYPE_OFFSET] !== Lexer::TOKEN_HORIZONTAL_WS) { + return; + } + + $this->index++; + } + + + public function currentTokenValue(): string + { + return $this->tokens[$this->index][Lexer::VALUE_OFFSET]; + } + + + public function currentTokenType(): int + { + return $this->tokens[$this->index][Lexer::TYPE_OFFSET]; + } + + + public function currentTokenOffset(): int + { + $offset = 0; + for ($i = 0; $i < $this->index; $i++) { + $offset += strlen($this->tokens[$i][Lexer::VALUE_OFFSET]); + } + + return $offset; + } + + + public function isCurrentTokenValue(string $tokenValue): bool + { + return $this->tokens[$this->index][Lexer::VALUE_OFFSET] === $tokenValue; + } + + + public function isCurrentTokenType(int ...$tokenType): bool + { + return in_array($this->tokens[$this->index][Lexer::TYPE_OFFSET], $tokenType, true); + } + + + public function isPrecededByHorizontalWhitespace(): bool + { + return ($this->tokens[$this->index - 1][Lexer::TYPE_OFFSET] ?? -1) === Lexer::TOKEN_HORIZONTAL_WS; + } + + + /** + * @throws ParserException + */ + public function consumeTokenType(int $tokenType): void + { + if ($this->tokens[$this->index][Lexer::TYPE_OFFSET] !== $tokenType) { + $this->throwError($tokenType); + } + + $this->index++; + + if (($this->tokens[$this->index][Lexer::TYPE_OFFSET] ?? -1) !== Lexer::TOKEN_HORIZONTAL_WS) { + return; + } + + $this->index++; + } + + + /** + * @throws ParserException + */ + public function consumeTokenValue(int $tokenType, string $tokenValue): void + { + if ($this->tokens[$this->index][Lexer::TYPE_OFFSET] !== $tokenType || $this->tokens[$this->index][Lexer::VALUE_OFFSET] !== $tokenValue) { + $this->throwError($tokenType, $tokenValue); + } + + $this->index++; + + if (($this->tokens[$this->index][Lexer::TYPE_OFFSET] ?? -1) !== Lexer::TOKEN_HORIZONTAL_WS) { + return; + } + + $this->index++; + } + + + /** @phpstan-impure */ + public function tryConsumeTokenValue(string $tokenValue): bool + { + if ($this->tokens[$this->index][Lexer::VALUE_OFFSET] !== $tokenValue) { + return false; + } + + $this->index++; + + if ($this->tokens[$this->index][Lexer::TYPE_OFFSET] === Lexer::TOKEN_HORIZONTAL_WS) { + $this->index++; + } + + return true; + } + + + /** @phpstan-impure */ + public function tryConsumeTokenType(int $tokenType): bool + { + if ($this->tokens[$this->index][Lexer::TYPE_OFFSET] !== $tokenType) { + return false; + } + + $this->index++; + + if ($this->tokens[$this->index][Lexer::TYPE_OFFSET] === Lexer::TOKEN_HORIZONTAL_WS) { + $this->index++; + } + + return true; + } + + + public function getSkippedHorizontalWhiteSpaceIfAny(): string + { + if ($this->index > 0 && $this->tokens[$this->index - 1][Lexer::TYPE_OFFSET] === Lexer::TOKEN_HORIZONTAL_WS) { + return $this->tokens[$this->index - 1][Lexer::VALUE_OFFSET]; + } + + return ''; + } + + + /** @phpstan-impure */ + public function joinUntil(int ...$tokenType): string + { + $s = ''; + while (!in_array($this->tokens[$this->index][Lexer::TYPE_OFFSET], $tokenType, true)) { + $s .= $this->tokens[$this->index++][Lexer::VALUE_OFFSET]; + } + return $s; + } + + + public function next(): void + { + $this->index++; + + if ($this->tokens[$this->index][Lexer::TYPE_OFFSET] !== Lexer::TOKEN_HORIZONTAL_WS) { + return; + } + + $this->index++; + } + + /** @phpstan-impure */ + public function forwardToTheEnd(): void + { + $lastToken = count($this->tokens) - 1; + $this->index = $lastToken; + } + + + public function pushSavePoint(): void + { + $this->savePoints[] = $this->index; + } + + + public function dropSavePoint(): void + { + array_pop($this->savePoints); + } + + + public function rollback(): void + { + $index = array_pop($this->savePoints); + assert($index !== null); + $this->index = $index; + } + + + /** + * @throws ParserException + */ + private function throwError(int $expectedTokenType, ?string $expectedTokenValue = null): void + { + throw new ParserException( + $this->currentTokenValue(), + $this->currentTokenType(), + $this->currentTokenOffset(), + $expectedTokenType, + $expectedTokenValue + ); + } + +} diff --git a/vendor/phpstan/phpdoc-parser/src/Parser/TypeParser.php b/vendor/phpstan/phpdoc-parser/src/Parser/TypeParser.php new file mode 100644 index 00000000..d196eb94 --- /dev/null +++ b/vendor/phpstan/phpdoc-parser/src/Parser/TypeParser.php @@ -0,0 +1,585 @@ +constExprParser = $constExprParser; + } + + /** @phpstan-impure */ + public function parse(TokenIterator $tokens): Ast\Type\TypeNode + { + if ($tokens->isCurrentTokenType(Lexer::TOKEN_NULLABLE)) { + $type = $this->parseNullable($tokens); + + } else { + $type = $this->parseAtomic($tokens); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_UNION)) { + $type = $this->parseUnion($tokens, $type); + + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_INTERSECTION)) { + $type = $this->parseIntersection($tokens, $type); + } + } + + return $type; + } + + /** @phpstan-impure */ + private function subParse(TokenIterator $tokens): Ast\Type\TypeNode + { + if ($tokens->isCurrentTokenType(Lexer::TOKEN_NULLABLE)) { + $type = $this->parseNullable($tokens); + + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_VARIABLE)) { + $type = $this->parseConditionalForParameter($tokens, $tokens->currentTokenValue()); + + } else { + $type = $this->parseAtomic($tokens); + + if ($tokens->isCurrentTokenValue('is')) { + $type = $this->parseConditional($tokens, $type); + } else { + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_UNION)) { + $type = $this->subParseUnion($tokens, $type); + + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_INTERSECTION)) { + $type = $this->subParseIntersection($tokens, $type); + } + } + } + + return $type; + } + + + /** @phpstan-impure */ + private function parseAtomic(TokenIterator $tokens): Ast\Type\TypeNode + { + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_OPEN_PARENTHESES)) { + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $type = $this->subParse($tokens); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_PARENTHESES); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET)) { + return $this->tryParseArrayOrOffsetAccess($tokens, $type); + } + + return $type; + } + + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_THIS_VARIABLE)) { + $type = new Ast\Type\ThisTypeNode(); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET)) { + return $this->tryParseArrayOrOffsetAccess($tokens, $type); + } + + return $type; + } + + $currentTokenValue = $tokens->currentTokenValue(); + $tokens->pushSavePoint(); // because of ConstFetchNode + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_IDENTIFIER)) { + $type = new Ast\Type\IdentifierTypeNode($currentTokenValue); + + if (!$tokens->isCurrentTokenType(Lexer::TOKEN_DOUBLE_COLON)) { + $tokens->dropSavePoint(); // because of ConstFetchNode + if ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_ANGLE_BRACKET)) { + $tokens->pushSavePoint(); + + $isHtml = $this->isHtml($tokens); + $tokens->rollback(); + if ($isHtml) { + return $type; + } + + $type = $this->parseGeneric($tokens, $type); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET)) { + $type = $this->tryParseArrayOrOffsetAccess($tokens, $type); + } + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_PARENTHESES)) { + $type = $this->tryParseCallable($tokens, $type); + + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET)) { + $type = $this->tryParseArrayOrOffsetAccess($tokens, $type); + + } elseif (in_array($type->name, ['array', 'list'], true) && $tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_CURLY_BRACKET) && !$tokens->isPrecededByHorizontalWhitespace()) { + $type = $this->parseArrayShape($tokens, $type, $type->name); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET)) { + $type = $this->tryParseArrayOrOffsetAccess($tokens, $type); + } + } + + return $type; + } else { + $tokens->rollback(); // because of ConstFetchNode + } + } else { + $tokens->dropSavePoint(); // because of ConstFetchNode + } + + $exception = new ParserException( + $tokens->currentTokenValue(), + $tokens->currentTokenType(), + $tokens->currentTokenOffset(), + Lexer::TOKEN_IDENTIFIER + ); + + if ($this->constExprParser === null) { + throw $exception; + } + + try { + $constExpr = $this->constExprParser->parse($tokens, true); + if ($constExpr instanceof Ast\ConstExpr\ConstExprArrayNode) { + throw $exception; + } + + return new Ast\Type\ConstTypeNode($constExpr); + } catch (LogicException $e) { + throw $exception; + } + } + + + /** @phpstan-impure */ + private function parseUnion(TokenIterator $tokens, Ast\Type\TypeNode $type): Ast\Type\TypeNode + { + $types = [$type]; + + while ($tokens->tryConsumeTokenType(Lexer::TOKEN_UNION)) { + $types[] = $this->parseAtomic($tokens); + } + + return new Ast\Type\UnionTypeNode($types); + } + + + /** @phpstan-impure */ + private function subParseUnion(TokenIterator $tokens, Ast\Type\TypeNode $type): Ast\Type\TypeNode + { + $types = [$type]; + + while ($tokens->tryConsumeTokenType(Lexer::TOKEN_UNION)) { + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $types[] = $this->parseAtomic($tokens); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + } + + return new Ast\Type\UnionTypeNode($types); + } + + + /** @phpstan-impure */ + private function parseIntersection(TokenIterator $tokens, Ast\Type\TypeNode $type): Ast\Type\TypeNode + { + $types = [$type]; + + while ($tokens->tryConsumeTokenType(Lexer::TOKEN_INTERSECTION)) { + $types[] = $this->parseAtomic($tokens); + } + + return new Ast\Type\IntersectionTypeNode($types); + } + + + /** @phpstan-impure */ + private function subParseIntersection(TokenIterator $tokens, Ast\Type\TypeNode $type): Ast\Type\TypeNode + { + $types = [$type]; + + while ($tokens->tryConsumeTokenType(Lexer::TOKEN_INTERSECTION)) { + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $types[] = $this->parseAtomic($tokens); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + } + + return new Ast\Type\IntersectionTypeNode($types); + } + + + /** @phpstan-impure */ + private function parseConditional(TokenIterator $tokens, Ast\Type\TypeNode $subjectType): Ast\Type\TypeNode + { + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + + $negated = false; + if ($tokens->isCurrentTokenValue('not')) { + $negated = true; + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + } + + $targetType = $this->parse($tokens); + + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $tokens->consumeTokenType(Lexer::TOKEN_NULLABLE); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + $ifType = $this->parse($tokens); + + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $tokens->consumeTokenType(Lexer::TOKEN_COLON); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + $elseType = $this->subParse($tokens); + + return new Ast\Type\ConditionalTypeNode($subjectType, $targetType, $ifType, $elseType, $negated); + } + + /** @phpstan-impure */ + private function parseConditionalForParameter(TokenIterator $tokens, string $parameterName): Ast\Type\TypeNode + { + $tokens->consumeTokenType(Lexer::TOKEN_VARIABLE); + $tokens->consumeTokenValue(Lexer::TOKEN_IDENTIFIER, 'is'); + + $negated = false; + if ($tokens->isCurrentTokenValue('not')) { + $negated = true; + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + } + + $targetType = $this->parse($tokens); + + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $tokens->consumeTokenType(Lexer::TOKEN_NULLABLE); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + $ifType = $this->parse($tokens); + + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $tokens->consumeTokenType(Lexer::TOKEN_COLON); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + $elseType = $this->subParse($tokens); + + return new Ast\Type\ConditionalTypeForParameterNode($parameterName, $targetType, $ifType, $elseType, $negated); + } + + + /** @phpstan-impure */ + private function parseNullable(TokenIterator $tokens): Ast\Type\TypeNode + { + $tokens->consumeTokenType(Lexer::TOKEN_NULLABLE); + + $type = $this->parseAtomic($tokens); + + return new Ast\Type\NullableTypeNode($type); + } + + /** @phpstan-impure */ + public function isHtml(TokenIterator $tokens): bool + { + $tokens->consumeTokenType(Lexer::TOKEN_OPEN_ANGLE_BRACKET); + + if (!$tokens->isCurrentTokenType(Lexer::TOKEN_IDENTIFIER)) { + return false; + } + + $htmlTagName = $tokens->currentTokenValue(); + + $tokens->next(); + + if (!$tokens->tryConsumeTokenType(Lexer::TOKEN_CLOSE_ANGLE_BRACKET)) { + return false; + } + + while (!$tokens->isCurrentTokenType(Lexer::TOKEN_END)) { + if ( + $tokens->tryConsumeTokenType(Lexer::TOKEN_OPEN_ANGLE_BRACKET) + && strpos($tokens->currentTokenValue(), '/' . $htmlTagName . '>') !== false + ) { + return true; + } + + $tokens->next(); + } + + return false; + } + + /** @phpstan-impure */ + public function parseGeneric(TokenIterator $tokens, Ast\Type\IdentifierTypeNode $baseType): Ast\Type\GenericTypeNode + { + $tokens->consumeTokenType(Lexer::TOKEN_OPEN_ANGLE_BRACKET); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + $genericTypes = []; + $variances = []; + + [$genericTypes[], $variances[]] = $this->parseGenericTypeArgument($tokens); + + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + while ($tokens->tryConsumeTokenType(Lexer::TOKEN_COMMA)) { + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_CLOSE_ANGLE_BRACKET)) { + // trailing comma case + return new Ast\Type\GenericTypeNode($baseType, $genericTypes, $variances); + } + [$genericTypes[], $variances[]] = $this->parseGenericTypeArgument($tokens); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + } + + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_ANGLE_BRACKET); + + return new Ast\Type\GenericTypeNode($baseType, $genericTypes, $variances); + } + + + /** + * @phpstan-impure + * @return array{Ast\Type\TypeNode, Ast\Type\GenericTypeNode::VARIANCE_*} + */ + public function parseGenericTypeArgument(TokenIterator $tokens): array + { + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_WILDCARD)) { + return [ + new Ast\Type\IdentifierTypeNode('mixed'), + Ast\Type\GenericTypeNode::VARIANCE_BIVARIANT, + ]; + } + + if ($tokens->tryConsumeTokenValue('contravariant')) { + $variance = Ast\Type\GenericTypeNode::VARIANCE_CONTRAVARIANT; + } elseif ($tokens->tryConsumeTokenValue('covariant')) { + $variance = Ast\Type\GenericTypeNode::VARIANCE_COVARIANT; + } else { + $variance = Ast\Type\GenericTypeNode::VARIANCE_INVARIANT; + } + + $type = $this->parse($tokens); + return [$type, $variance]; + } + + + /** @phpstan-impure */ + private function parseCallable(TokenIterator $tokens, Ast\Type\IdentifierTypeNode $identifier): Ast\Type\TypeNode + { + $tokens->consumeTokenType(Lexer::TOKEN_OPEN_PARENTHESES); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + $parameters = []; + if (!$tokens->isCurrentTokenType(Lexer::TOKEN_CLOSE_PARENTHESES)) { + $parameters[] = $this->parseCallableParameter($tokens); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + while ($tokens->tryConsumeTokenType(Lexer::TOKEN_COMMA)) { + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + if ($tokens->isCurrentTokenType(Lexer::TOKEN_CLOSE_PARENTHESES)) { + break; + } + $parameters[] = $this->parseCallableParameter($tokens); + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + } + } + + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_PARENTHESES); + $tokens->consumeTokenType(Lexer::TOKEN_COLON); + $returnType = $this->parseCallableReturnType($tokens); + + return new Ast\Type\CallableTypeNode($identifier, $parameters, $returnType); + } + + + /** @phpstan-impure */ + private function parseCallableParameter(TokenIterator $tokens): Ast\Type\CallableTypeParameterNode + { + $type = $this->parse($tokens); + $isReference = $tokens->tryConsumeTokenType(Lexer::TOKEN_REFERENCE); + $isVariadic = $tokens->tryConsumeTokenType(Lexer::TOKEN_VARIADIC); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_VARIABLE)) { + $parameterName = $tokens->currentTokenValue(); + $tokens->consumeTokenType(Lexer::TOKEN_VARIABLE); + + } else { + $parameterName = ''; + } + + $isOptional = $tokens->tryConsumeTokenType(Lexer::TOKEN_EQUAL); + return new Ast\Type\CallableTypeParameterNode($type, $isReference, $isVariadic, $parameterName, $isOptional); + } + + + /** @phpstan-impure */ + private function parseCallableReturnType(TokenIterator $tokens): Ast\Type\TypeNode + { + if ($tokens->isCurrentTokenType(Lexer::TOKEN_NULLABLE)) { + $type = $this->parseNullable($tokens); + + } elseif ($tokens->tryConsumeTokenType(Lexer::TOKEN_OPEN_PARENTHESES)) { + $type = $this->parse($tokens); + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_PARENTHESES); + + } else { + $type = new Ast\Type\IdentifierTypeNode($tokens->currentTokenValue()); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_ANGLE_BRACKET)) { + $type = $this->parseGeneric($tokens, $type); + + } elseif (in_array($type->name, ['array', 'list'], true) && $tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_CURLY_BRACKET) && !$tokens->isPrecededByHorizontalWhitespace()) { + $type = $this->parseArrayShape($tokens, $type, $type->name); + } + } + + if ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET)) { + $type = $this->tryParseArrayOrOffsetAccess($tokens, $type); + } + + return $type; + } + + + /** @phpstan-impure */ + private function tryParseCallable(TokenIterator $tokens, Ast\Type\IdentifierTypeNode $identifier): Ast\Type\TypeNode + { + try { + $tokens->pushSavePoint(); + $type = $this->parseCallable($tokens, $identifier); + $tokens->dropSavePoint(); + + } catch (ParserException $e) { + $tokens->rollback(); + $type = $identifier; + } + + return $type; + } + + + /** @phpstan-impure */ + private function tryParseArrayOrOffsetAccess(TokenIterator $tokens, Ast\Type\TypeNode $type): Ast\Type\TypeNode + { + try { + while ($tokens->isCurrentTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET)) { + $tokens->pushSavePoint(); + + $canBeOffsetAccessType = !$tokens->isPrecededByHorizontalWhitespace(); + $tokens->consumeTokenType(Lexer::TOKEN_OPEN_SQUARE_BRACKET); + + if ($canBeOffsetAccessType && !$tokens->isCurrentTokenType(Lexer::TOKEN_CLOSE_SQUARE_BRACKET)) { + $offset = $this->parse($tokens); + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_SQUARE_BRACKET); + $tokens->dropSavePoint(); + $type = new Ast\Type\OffsetAccessTypeNode($type, $offset); + } else { + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_SQUARE_BRACKET); + $tokens->dropSavePoint(); + $type = new Ast\Type\ArrayTypeNode($type); + } + } + + } catch (ParserException $e) { + $tokens->rollback(); + } + + return $type; + } + + + /** + * @phpstan-impure + * @param Ast\Type\ArrayShapeNode::KIND_* $kind + */ + private function parseArrayShape(TokenIterator $tokens, Ast\Type\TypeNode $type, string $kind): Ast\Type\ArrayShapeNode + { + $tokens->consumeTokenType(Lexer::TOKEN_OPEN_CURLY_BRACKET); + + $items = []; + $sealed = true; + + do { + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_CLOSE_CURLY_BRACKET)) { + return new Ast\Type\ArrayShapeNode($items, true, $kind); + } + + if ($tokens->tryConsumeTokenType(Lexer::TOKEN_VARIADIC)) { + $sealed = false; + $tokens->tryConsumeTokenType(Lexer::TOKEN_COMMA); + break; + } + + $items[] = $this->parseArrayShapeItem($tokens); + + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + } while ($tokens->tryConsumeTokenType(Lexer::TOKEN_COMMA)); + + $tokens->tryConsumeTokenType(Lexer::TOKEN_PHPDOC_EOL); + $tokens->consumeTokenType(Lexer::TOKEN_CLOSE_CURLY_BRACKET); + + return new Ast\Type\ArrayShapeNode($items, $sealed, $kind); + } + + + /** @phpstan-impure */ + private function parseArrayShapeItem(TokenIterator $tokens): Ast\Type\ArrayShapeItemNode + { + try { + $tokens->pushSavePoint(); + $key = $this->parseArrayShapeKey($tokens); + $optional = $tokens->tryConsumeTokenType(Lexer::TOKEN_NULLABLE); + $tokens->consumeTokenType(Lexer::TOKEN_COLON); + $value = $this->parse($tokens); + $tokens->dropSavePoint(); + + return new Ast\Type\ArrayShapeItemNode($key, $optional, $value); + } catch (ParserException $e) { + $tokens->rollback(); + $value = $this->parse($tokens); + + return new Ast\Type\ArrayShapeItemNode(null, false, $value); + } + } + + /** + * @phpstan-impure + * @return Ast\ConstExpr\ConstExprIntegerNode|Ast\ConstExpr\ConstExprStringNode|Ast\Type\IdentifierTypeNode + */ + private function parseArrayShapeKey(TokenIterator $tokens) + { + if ($tokens->isCurrentTokenType(Lexer::TOKEN_INTEGER)) { + $key = new Ast\ConstExpr\ConstExprIntegerNode($tokens->currentTokenValue()); + $tokens->next(); + + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_SINGLE_QUOTED_STRING)) { + $key = new Ast\ConstExpr\ConstExprStringNode(trim($tokens->currentTokenValue(), "'")); + $tokens->next(); + + } elseif ($tokens->isCurrentTokenType(Lexer::TOKEN_DOUBLE_QUOTED_STRING)) { + $key = new Ast\ConstExpr\ConstExprStringNode(trim($tokens->currentTokenValue(), '"')); + $tokens->next(); + + } else { + $key = new Ast\Type\IdentifierTypeNode($tokens->currentTokenValue()); + $tokens->consumeTokenType(Lexer::TOKEN_IDENTIFIER); + } + + return $key; + } + +} diff --git a/vendor/phpstan/phpstan-deprecation-rules/src/Rules/Deprecations/AccessDeprecatedStaticPropertyRule.php b/vendor/phpstan/phpstan-deprecation-rules/src/Rules/Deprecations/AccessDeprecatedStaticPropertyRule.php index db128cc5..beb9891f 100644 --- a/vendor/phpstan/phpstan-deprecation-rules/src/Rules/Deprecations/AccessDeprecatedStaticPropertyRule.php +++ b/vendor/phpstan/phpstan-deprecation-rules/src/Rules/Deprecations/AccessDeprecatedStaticPropertyRule.php @@ -53,7 +53,7 @@ class AccessDeprecatedStaticPropertyRule implements Rule $referencedClasses = []; if ($node->class instanceof Name) { - $referencedClasses[] = (string) $node->class; + $referencedClasses[] = $scope->resolveName($node->class); } else { $classTypeResult = $this->ruleLevelHelper->findTypeToCheck( $scope, @@ -87,14 +87,14 @@ class AccessDeprecatedStaticPropertyRule implements Rule return [sprintf( 'Access to deprecated static property $%s of class %s.', $propertyName, - $referencedClass + $property->getDeclaringClass()->getName() )]; } return [sprintf( "Access to deprecated static property $%s of class %s:\n%s", $propertyName, - $referencedClass, + $property->getDeclaringClass()->getName(), $description )]; } diff --git a/vendor/phpstan/phpstan/composer.json b/vendor/phpstan/phpstan/composer.json index 55182f6c..07faa85b 100644 --- a/vendor/phpstan/phpstan/composer.json +++ b/vendor/phpstan/phpstan/composer.json @@ -15,5 +15,12 @@ ], "autoload": { "files": ["bootstrap.php"] + }, + "support": { + "issues": "https://github.com/phpstan/phpstan/issues", + "forum": "https://github.com/phpstan/phpstan/discussions", + "source": "https://github.com/phpstan/phpstan-src", + "docs": "https://phpstan.org/user-guide/getting-started", + "security": "https://github.com/phpstan/phpstan/security/policy" } } diff --git a/vendor/phpstan/phpstan/phpstan.phar b/vendor/phpstan/phpstan/phpstan.phar index f96912fb..947d5ab0 100755 Binary files a/vendor/phpstan/phpstan/phpstan.phar and b/vendor/phpstan/phpstan/phpstan.phar differ diff --git a/vendor/phpstan/phpstan/phpstan.phar.asc b/vendor/phpstan/phpstan/phpstan.phar.asc index 89f0c673..7d0dcea9 100644 --- a/vendor/phpstan/phpstan/phpstan.phar.asc +++ b/vendor/phpstan/phpstan/phpstan.phar.asc @@ -1,16 +1,16 @@ -----BEGIN PGP SIGNATURE----- -iQIzBAABCgAdFiEE0yaA1ZV9xxFr4pwUzxoQjQ565yAFAmQHatYACgkQzxoQjQ56 -5yAU7A/8CLVE46kub8QEP/s8/w9T4uOyG1vsFwv9dafa4PySyvhZCr/vliCuYyF9 -JUUSXqyGIFi+VKsuY8y7u5zaVqpq6O6qJBkzsUK/X9BHZfFEo1k2v/NNJD7t3p0b -or5u9bOTlSJnXV+1hPNjkW4wcnxR6kuJQIoz9XwNsQC07mPVxNrHknxnkgGFVDNR -ITjpW3rBW3vRtoOWajPJMXZt6f+pJCl8ccISK97gskAzK75t2Ymle9fV9FdQYGWt -8X/gfQtVfJOkEmHV6F+pUE9o++aNCPljNo1O+1eS62TTOSRlS6fNhppu/o7Z4IIi -9QS3DHhDTGQPLUCXbMToK/kwRCAzDe9lFgjpKIUQhmEGKOjTNup2NPqWGtQNQj7h -WTP6W2GNpGh5g+d7Tm667FKej/AgixwvpdJqR1VGk2PI2EYMryMz17nQ1cvGinOW -X3auWZe/HWuyqFtt5r85ffZGVS/4xKxeAK85HPrn3mzotiXr/KZf8S525BuGqUaZ -lQ7paCM6kZ9rn9vMmLEe57Ypl7bMzfUV6c2k5KYYR2EV9LXzNPS9G7Yhpg/Q3G2S -cTqxKuBk+hvXd3rp4OwzrjAUps8w4XzyHBpDl9k1n2oB+1Plygrkew8Z5CRglTL4 -lSQAD2FLSTEAvPcFi3kkiBxxeoXSSnjP2iruPsAkcfzsENBFTdM= -=4/CB +iQIzBAABCgAdFiEEynwsejDI6OEnSoR2UcZzBf/C5cAFAmQdeygACgkQUcZzBf/C +5cAe5Q//YDKPvVm4HlLT90M/Ov0IJ8brPP6LN0fbMV93TJlXFhh6Ph79YUwxRWve +FPYr93HDCSOdlg3q3xRNgPcUim5+7U5xf5ze5RWIBR07IDY5+i9Os66CLRALlO4u +ToXHCO2k0hw26sSskRXmF2IrNIibvPjVjR+ephFGFenWI0S7vq5cYGqOnzwdURyu +ZNIswHWQsJSGLn4AXfDnushBCy3w5IsSgnENIWD7L9a37A45kek+iHETcX1OLTOd +AlJOvQ0l2OAE4kMx8tailGYtJo9yLnjtSLw6xQbdw5mf47iapm1U09C52XvYsZg4 +oZNCJ8QFHR1YbbLpdMxPFcMQgbVLGKBwHYcpsi2VdMKdR+7altlF9govkvBLxxm7 +Polq9ya0fS7wAJP0vMESGeP6UJi68DMWH7hxJ7d9tyBieYJHSpm5q5QSYjj4RxM5 +LiTTv9ug8DFIsLJiw1CplE4pxtJ82arXBqggpqO15MRNxwzyJmY7XIHtEZI2dl+d +BImd5bWl6nCkhKEYPs+6SEt/caXIz/XERap5gO9Q8UBx5jaKPHEKRbuvTgbW1Ods +fFNDgIsQyg+56LzIxgp2a6IUVeeQSrL4kjeHYQDBMzG0P78ZXjXdUl3kYG3TJHmb +QNWgYcz3jJJd/F5YSMPpAPT/gpcD4FBnHZ+mlLnGvXvuuGh+MyU= +=vW1l -----END PGP SIGNATURE----- diff --git a/vendor/sebastian/diff/ChangeLog.md b/vendor/sebastian/diff/ChangeLog.md index 7db073c7..ab8640c8 100644 --- a/vendor/sebastian/diff/ChangeLog.md +++ b/vendor/sebastian/diff/ChangeLog.md @@ -2,7 +2,13 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles. -## [5.0.0] - 2022-02-03 +## [5.0.1] - 2023-03-23 + +### Fixed + +* [#115](https://github.com/sebastianbergmann/diff/pull/115): `Parser::parseFileDiff()` does not handle diffs correctly that only add lines or only remove lines + +## [5.0.0] - 2023-02-03 ### Changed @@ -86,6 +92,7 @@ All notable changes are documented in this file using the [Keep a CHANGELOG](htt * This component is no longer supported on PHP 5.6 +[5.0.1]: https://github.com/sebastianbergmann/diff/compare/5.0.0...5.0.1 [5.0.0]: https://github.com/sebastianbergmann/diff/compare/4.0.4...5.0.0 [4.0.4]: https://github.com/sebastianbergmann/diff/compare/4.0.3...4.0.4 [4.0.3]: https://github.com/sebastianbergmann/diff/compare/4.0.2...4.0.3 diff --git a/vendor/sebastian/diff/SECURITY.md b/vendor/sebastian/diff/SECURITY.md index d4ee967b..778f018b 100644 --- a/vendor/sebastian/diff/SECURITY.md +++ b/vendor/sebastian/diff/SECURITY.md @@ -1,9 +1,30 @@ # Security Policy -This library is intended to be used in development environments only. For instance, it is used by the testing framework PHPUnit. There is no reason why this library should be installed on a webserver. +If you believe you have found a security vulnerability in the library that is developed in this repository, please report it to us through coordinated disclosure. -**If you upload this library to a webserver then your deployment process is broken. On a more general note, if your `vendor` directory is publicly accessible on your webserver then your deployment process is also broken.** +**Please do not report security vulnerabilities through public GitHub issues, discussions, or pull requests.** -## Security Contact Information +Instead, please send an email to `sebastian@phpunit.de`. + +Please include as much of the information listed below as you can to help us better understand and resolve the issue: + +* The type of issue +* Full paths of source file(s) related to the manifestation of the issue +* The location of the affected source code (tag/branch/commit or direct URL) +* Any special configuration required to reproduce the issue +* Step-by-step instructions to reproduce the issue +* Proof-of-concept or exploit code (if possible) +* Impact of the issue, including how an attacker might exploit the issue + +This information will help us triage your report more quickly. + +## Web Context + +The library that is developed in this repository was either extracted from [PHPUnit](https://github.com/sebastianbergmann/phpunit) or developed specifically as a dependency for PHPUnit. + +The library is developed with a focus on development environments and the command-line. No specific testing or hardening with regard to using the library in a HTTP or web context or with untrusted input data is performed. The library might also contain functionality that intentionally exposes internal application data for debugging purposes. + +If the library is used in a web application, the application developer is responsible for filtering inputs or escaping outputs as necessary and for verifying that the used functionality is safe for use within the intended context. + +Vulnerabilities specific to the use outside of a development context will be fixed as applicable, provided that the fix does not have an averse effect on the primary use case for development purposes. -After the above, if you still would like to report a security vulnerability, please email `sebastian@phpunit.de`. diff --git a/vendor/sebastian/diff/composer.json b/vendor/sebastian/diff/composer.json index b8e778b5..cd37ef6b 100644 --- a/vendor/sebastian/diff/composer.json +++ b/vendor/sebastian/diff/composer.json @@ -14,6 +14,10 @@ "email": "mail@kore-nordmann.de" } ], + "support": { + "issues": "https://github.com/sebastianbergmann/diff/issues", + "security": "https://github.com/sebastianbergmann/diff/security/policy" + }, "prefer-stable": true, "config": { "platform": { diff --git a/vendor/sebastian/diff/src/Parser.php b/vendor/sebastian/diff/src/Parser.php index b0ec6403..698b815c 100644 --- a/vendor/sebastian/diff/src/Parser.php +++ b/vendor/sebastian/diff/src/Parser.php @@ -74,12 +74,12 @@ final class Parser $diffLines = []; foreach ($lines as $line) { - if (preg_match('/^@@\s+-(?P\d+)(?:,\s*(?P\d+))?\s+\+(?P\d+)(?:,\s*(?P\d+))?\s+@@/', $line, $match)) { + if (preg_match('/^@@\s+-(?P\d+)(?:,\s*(?P\d+))?\s+\+(?P\d+)(?:,\s*(?P\d+))?\s+@@/', $line, $match, PREG_UNMATCHED_AS_NULL)) { $chunk = new Chunk( (int) $match['start'], - isset($match['startrange']) ? max(1, (int) $match['startrange']) : 1, + isset($match['startrange']) ? max(0, (int) $match['startrange']) : 1, (int) $match['end'], - isset($match['endrange']) ? max(1, (int) $match['endrange']) : 1 + isset($match['endrange']) ? max(0, (int) $match['endrange']) : 1 ); $chunks[] = $chunk; diff --git a/vendor/vimeo/psalm/composer.json b/vendor/vimeo/psalm/composer.json index d62c80c2..ed857f9a 100644 --- a/vendor/vimeo/psalm/composer.json +++ b/vendor/vimeo/psalm/composer.json @@ -25,7 +25,7 @@ "ext-tokenizer": "*", "amphp/amp": "^2.4.2", "amphp/byte-stream": "^1.5", - "composer/package-versions-deprecated": "^1.10.0", + "composer-runtime-api": "^2", "composer/semver": "^1.4 || ^2.0 || ^3.0", "composer/xdebug-handler": "^2.0 || ^3.0", "dnoegel/php-xdg-base-dir": "^0.1.1", @@ -33,7 +33,7 @@ "felixfbecker/language-server-protocol": "^1.5.2", "fidry/cpu-core-counter": "^0.4.1 || ^0.5.1", "netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0 || ^4.0", - "nikic/php-parser": "^4.13", + "nikic/php-parser": "^4.14", "sebastian/diff": "^4.0 || ^5.0", "spatie/array-to-xml": "^2.17.0 || ^3.0", "symfony/console": "^4.1.6 || ^5.0 || ^6.0", @@ -117,7 +117,7 @@ "Composer\\Config::disableProcessTimeout", "phpunit" ], - "verify-callmap": "phpunit tests/Internal/Codebase/InternalCallMapHandlerTest.php", + "verify-callmap": "@php phpunit tests/Internal/Codebase/InternalCallMapHandlerTest.php", "psalm": "@php ./psalm", "psalm-set-baseline": "@php ./psalm --set-baseline=psalm-baseline.xml", "tests": [ diff --git a/vendor/vimeo/psalm/config.xsd b/vendor/vimeo/psalm/config.xsd index 9d08a678..f4302e20 100644 --- a/vendor/vimeo/psalm/config.xsd +++ b/vendor/vimeo/psalm/config.xsd @@ -407,6 +407,7 @@ + @@ -725,6 +726,7 @@ + diff --git a/vendor/vimeo/psalm/dictionaries/CallMap.php b/vendor/vimeo/psalm/dictionaries/CallMap.php index 4cc19235..2e1191c8 100644 --- a/vendor/vimeo/psalm/dictionaries/CallMap.php +++ b/vendor/vimeo/psalm/dictionaries/CallMap.php @@ -2,7 +2,7 @@ namespace Phan\Language\Internal; /** - * CURRENT PHP TARGET VERSION: 8.2 + * CURRENT PHP TARGET VERSION: 8.3 * The version above has to match Psalm\Internal\Codebase\InternalCallMapHandler::PHP_(MAJOR|MINOR)_VERSION * * Format @@ -359,29 +359,29 @@ return [ 'ArithmeticError::getPrevious' => ['?Throwable'], 'ArithmeticError::getTrace' => ['list\',args?:array}>'], 'ArithmeticError::getTraceAsString' => ['string'], -'array_change_key_case' => ['associative-array', 'array'=>'array', 'case='=>'int'], +'array_change_key_case' => ['array', 'array'=>'array', 'case='=>'int'], 'array_chunk' => ['list', 'array'=>'array', 'length'=>'int', 'preserve_keys='=>'bool'], 'array_column' => ['array', 'array'=>'array', 'column_key'=>'int|string|null', 'index_key='=>'int|string|null'], -'array_combine' => ['associative-array', 'keys'=>'string[]|int[]', 'values'=>'array'], -'array_count_values' => ['associative-array', 'array'=>'array'], -'array_diff' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], -'array_diff_assoc' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], -'array_diff_key' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], -'array_diff_uassoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int'], -'array_diff_uassoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], -'array_diff_ukey' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'key_comp_func'=>'callable(mixed,mixed):int'], -'array_diff_ukey\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], +'array_combine' => ['array', 'keys'=>'string[]|int[]', 'values'=>'array'], +'array_count_values' => ['array', 'array'=>'array'], +'array_diff' => ['array', 'array'=>'array', '...arrays='=>'array'], +'array_diff_assoc' => ['array', 'array'=>'array', '...arrays='=>'array'], +'array_diff_key' => ['array', 'array'=>'array', '...arrays='=>'array'], +'array_diff_uassoc' => ['array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int'], +'array_diff_uassoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], +'array_diff_ukey' => ['array', 'array'=>'array', 'rest'=>'array', 'key_comp_func'=>'callable(mixed,mixed):int'], +'array_diff_ukey\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], 'array_fill' => ['array', 'start_index'=>'int', 'count'=>'int', 'value'=>'mixed'], 'array_fill_keys' => ['array', 'keys'=>'array', 'value'=>'mixed'], -'array_filter' => ['associative-array', 'array'=>'array', 'callback='=>'callable(mixed,mixed=):scalar|null', 'mode='=>'int'], -'array_flip' => ['associative-array|associative-array', 'array'=>'array'], -'array_intersect' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], -'array_intersect_assoc' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], -'array_intersect_key' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], -'array_intersect_uassoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'key_compare_func'=>'callable(mixed,mixed):int'], -'array_intersect_uassoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest'=>'array|callable(mixed,mixed):int'], -'array_intersect_ukey' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'key_compare_func'=>'callable(mixed,mixed):int'], -'array_intersect_ukey\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest'=>'array|callable(mixed,mixed):int'], +'array_filter' => ['array', 'array'=>'array', 'callback='=>'callable(mixed,mixed=):scalar|null', 'mode='=>'int'], +'array_flip' => ['array', 'array'=>'array'], +'array_intersect' => ['array', 'array'=>'array', '...arrays='=>'array'], +'array_intersect_assoc' => ['array', 'array'=>'array', '...arrays='=>'array'], +'array_intersect_key' => ['array', 'array'=>'array', '...arrays='=>'array'], +'array_intersect_uassoc' => ['array', 'array'=>'array', 'rest'=>'array', 'key_compare_func'=>'callable(mixed,mixed):int'], +'array_intersect_uassoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest'=>'array|callable(mixed,mixed):int'], +'array_intersect_ukey' => ['array', 'array'=>'array', 'rest'=>'array', 'key_compare_func'=>'callable(mixed,mixed):int'], +'array_intersect_ukey\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest'=>'array|callable(mixed,mixed):int'], 'array_is_list' => ['bool', 'array'=>'array'], 'array_key_exists' => ['bool', 'key'=>'string|int', 'array'=>'array'], 'array_key_first' => ['int|string|null', 'array'=>'array'], @@ -406,18 +406,18 @@ return [ 'array_slice' => ['array', 'array'=>'array', 'offset'=>'int', 'length='=>'?int', 'preserve_keys='=>'bool'], 'array_splice' => ['array', '&rw_array'=>'array', 'offset'=>'int', 'length='=>'?int', 'replacement='=>'array|string'], 'array_sum' => ['int|float', 'array'=>'array'], -'array_udiff' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int'], -'array_udiff\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], -'array_udiff_assoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'key_comp_func'=>'callable(mixed,mixed):int'], -'array_udiff_assoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], -'array_udiff_uassoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int', 'key_comp_func'=>'callable(mixed,mixed):int'], -'array_udiff_uassoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', 'arg5'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], -'array_uintersect' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int'], -'array_uintersect\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], -'array_uintersect_assoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int'], -'array_uintersect_assoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable(mixed,mixed):int'], -'array_uintersect_uassoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int', 'key_compare_func'=>'callable(mixed,mixed):int'], -'array_uintersect_uassoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', 'arg5'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], +'array_udiff' => ['array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int'], +'array_udiff\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], +'array_udiff_assoc' => ['array', 'array'=>'array', 'rest'=>'array', 'key_comp_func'=>'callable(mixed,mixed):int'], +'array_udiff_assoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], +'array_udiff_uassoc' => ['array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int', 'key_comp_func'=>'callable(mixed,mixed):int'], +'array_udiff_uassoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', 'arg5'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], +'array_uintersect' => ['array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int'], +'array_uintersect\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], +'array_uintersect_assoc' => ['array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int'], +'array_uintersect_assoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable(mixed,mixed):int'], +'array_uintersect_uassoc' => ['array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int', 'key_compare_func'=>'callable(mixed,mixed):int'], +'array_uintersect_uassoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', 'arg5'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], 'array_unique' => ['array', 'array'=>'array', 'flags='=>'0'], 'array_unique\'1' => ['array', 'array'=>'array', 'flags='=>'1'], 'array_unique\'2' => ['array', 'array'=>'array', 'flags='=>'2|5'], @@ -433,50 +433,50 @@ return [ 'ArrayAccess::offsetUnset' => ['void', 'offset'=>'mixed'], 'ArrayIterator::__construct' => ['void', 'array='=>'array|object', 'flags='=>'int'], 'ArrayIterator::append' => ['void', 'value'=>'mixed'], -'ArrayIterator::asort' => ['void'], +'ArrayIterator::asort' => ['true', 'flags='=>'int'], 'ArrayIterator::count' => ['int'], 'ArrayIterator::current' => ['mixed'], 'ArrayIterator::getArrayCopy' => ['array'], 'ArrayIterator::getFlags' => ['int'], 'ArrayIterator::key' => ['int|string|null'], -'ArrayIterator::ksort' => ['void'], +'ArrayIterator::ksort' => ['true', 'flags='=>'int'], 'ArrayIterator::natcasesort' => ['true'], 'ArrayIterator::natsort' => ['true'], 'ArrayIterator::next' => ['void'], -'ArrayIterator::offsetExists' => ['bool', 'index'=>'string|int'], -'ArrayIterator::offsetGet' => ['mixed', 'index'=>'string|int'], -'ArrayIterator::offsetSet' => ['void', 'index'=>'string|int', 'newval'=>'mixed'], -'ArrayIterator::offsetUnset' => ['void', 'index'=>'string|int'], +'ArrayIterator::offsetExists' => ['bool', 'key'=>'string|int'], +'ArrayIterator::offsetGet' => ['mixed', 'key'=>'string|int'], +'ArrayIterator::offsetSet' => ['void', 'key'=>'string|int', 'value'=>'mixed'], +'ArrayIterator::offsetUnset' => ['void', 'key'=>'string|int'], 'ArrayIterator::rewind' => ['void'], -'ArrayIterator::seek' => ['void', 'position'=>'int'], +'ArrayIterator::seek' => ['void', 'offset'=>'int'], 'ArrayIterator::serialize' => ['string'], -'ArrayIterator::setFlags' => ['void', 'flags'=>'string'], -'ArrayIterator::uasort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], -'ArrayIterator::uksort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], -'ArrayIterator::unserialize' => ['void', 'serialized'=>'string'], +'ArrayIterator::setFlags' => ['void', 'flags'=>'int'], +'ArrayIterator::uasort' => ['true', 'callback'=>'callable(mixed,mixed):int'], +'ArrayIterator::uksort' => ['true', 'callback'=>'callable(mixed,mixed):int'], +'ArrayIterator::unserialize' => ['void', 'data'=>'string'], 'ArrayIterator::valid' => ['bool'], -'ArrayObject::__construct' => ['void', 'input='=>'array|object', 'flags='=>'int', 'iterator_class='=>'string'], +'ArrayObject::__construct' => ['void', 'array='=>'array|object', 'flags='=>'int', 'iteratorClass='=>'class-string'], 'ArrayObject::append' => ['void', 'value'=>'mixed'], -'ArrayObject::asort' => ['void'], +'ArrayObject::asort' => ['true', 'flags='=>'int'], 'ArrayObject::count' => ['int'], -'ArrayObject::exchangeArray' => ['array', 'ar'=>'mixed'], +'ArrayObject::exchangeArray' => ['array', 'array'=>'array|object'], 'ArrayObject::getArrayCopy' => ['array'], 'ArrayObject::getFlags' => ['int'], 'ArrayObject::getIterator' => ['ArrayIterator'], 'ArrayObject::getIteratorClass' => ['string'], -'ArrayObject::ksort' => ['void'], +'ArrayObject::ksort' => ['true', 'flags='=>'int'], 'ArrayObject::natcasesort' => ['true'], 'ArrayObject::natsort' => ['true'], -'ArrayObject::offsetExists' => ['bool', 'index'=>'int|string'], -'ArrayObject::offsetGet' => ['mixed|null', 'index'=>'int|string'], -'ArrayObject::offsetSet' => ['void', 'index'=>'int|string', 'newval'=>'mixed'], -'ArrayObject::offsetUnset' => ['void', 'index'=>'int|string'], +'ArrayObject::offsetExists' => ['bool', 'key'=>'int|string'], +'ArrayObject::offsetGet' => ['mixed|null', 'key'=>'int|string'], +'ArrayObject::offsetSet' => ['void', 'key'=>'int|string', 'value'=>'mixed'], +'ArrayObject::offsetUnset' => ['void', 'key'=>'int|string'], 'ArrayObject::serialize' => ['string'], 'ArrayObject::setFlags' => ['void', 'flags'=>'int'], -'ArrayObject::setIteratorClass' => ['void', 'iterator_class'=>'string'], -'ArrayObject::uasort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], -'ArrayObject::uksort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], -'ArrayObject::unserialize' => ['void', 'serialized'=>'string'], +'ArrayObject::setIteratorClass' => ['void', 'iteratorClass'=>'class-string'], +'ArrayObject::uasort' => ['true', 'callback'=>'callable(mixed,mixed):int'], +'ArrayObject::uksort' => ['true', 'callback'=>'callable(mixed,mixed):int'], +'ArrayObject::unserialize' => ['void', 'data'=>'string'], 'arsort' => ['true', '&rw_array'=>'array', 'flags='=>'int'], 'asin' => ['float', 'num'=>'float'], 'asinh' => ['float', 'num'=>'float'], @@ -587,10 +587,10 @@ return [ 'CachingIterator::hasNext' => ['bool'], 'CachingIterator::key' => ['int|string|float|bool'], 'CachingIterator::next' => ['void'], -'CachingIterator::offsetExists' => ['bool', 'index'=>'string'], -'CachingIterator::offsetGet' => ['mixed', 'index'=>'string'], -'CachingIterator::offsetSet' => ['void', 'index'=>'string', 'newval'=>'mixed'], -'CachingIterator::offsetUnset' => ['void', 'index'=>'string'], +'CachingIterator::offsetExists' => ['bool', 'key'=>'string'], +'CachingIterator::offsetGet' => ['mixed', 'key'=>'string'], +'CachingIterator::offsetSet' => ['void', 'key'=>'string', 'value'=>'mixed'], +'CachingIterator::offsetUnset' => ['void', 'key'=>'string'], 'CachingIterator::rewind' => ['void'], 'CachingIterator::setFlags' => ['void', 'flags'=>'int'], 'CachingIterator::valid' => ['bool'], @@ -604,7 +604,7 @@ return [ 'call_user_func_array' => ['mixed|false', 'callback'=>'callable', 'args'=>'list'], 'call_user_method' => ['mixed', 'method_name'=>'string', 'object'=>'object', 'parameter='=>'mixed', '...args='=>'mixed'], 'call_user_method_array' => ['mixed', 'method_name'=>'string', 'object'=>'object', 'params'=>'list'], -'CallbackFilterIterator::__construct' => ['void', 'iterator'=>'Iterator', 'func'=>'callable(mixed):bool|callable(mixed,mixed):bool|callable(mixed,mixed,mixed):bool'], +'CallbackFilterIterator::__construct' => ['void', 'iterator'=>'Iterator', 'callback'=>'callable(mixed,mixed=,mixed=):bool'], 'CallbackFilterIterator::accept' => ['bool'], 'CallbackFilterIterator::current' => ['mixed'], 'CallbackFilterIterator::getInnerIterator' => ['Iterator'], @@ -685,19 +685,19 @@ return [ 'clusterObj::setFilter' => ['int', 'expression'=>'string'], 'clusterObj::setGroup' => ['int', 'expression'=>'string'], 'Collator::__construct' => ['void', 'locale'=>'string'], -'Collator::asort' => ['bool', '&rw_arr'=>'array', 'sort_flag='=>'int'], +'Collator::asort' => ['bool', '&rw_array'=>'array', 'flags='=>'int'], 'Collator::compare' => ['int|false', 'string1'=>'string', 'string2'=>'string'], 'Collator::create' => ['?Collator', 'locale'=>'string'], -'Collator::getAttribute' => ['int|false', 'attr'=>'int'], +'Collator::getAttribute' => ['int|false', 'attribute'=>'int'], 'Collator::getErrorCode' => ['int'], 'Collator::getErrorMessage' => ['string'], 'Collator::getLocale' => ['string', 'type'=>'int'], 'Collator::getSortKey' => ['string|false', 'string'=>'string'], 'Collator::getStrength' => ['int'], -'Collator::setAttribute' => ['bool', 'attr'=>'int', 'value'=>'int'], +'Collator::setAttribute' => ['bool', 'attribute'=>'int', 'value'=>'int'], 'Collator::setStrength' => ['bool', 'strength'=>'int'], -'Collator::sort' => ['bool', '&rw_arr'=>'array', 'sort_flags='=>'int'], -'Collator::sortWithSortKeys' => ['bool', '&rw_arr'=>'array'], +'Collator::sort' => ['bool', '&rw_array'=>'array', 'flags='=>'int'], +'Collator::sortWithSortKeys' => ['bool', '&rw_array'=>'array'], 'collator_asort' => ['bool', 'object'=>'collator', '&rw_array'=>'array', 'flags='=>'int'], 'collator_compare' => ['int', 'object'=>'collator', 'string1'=>'string', 'string2'=>'string'], 'collator_create' => ['?Collator', 'locale'=>'string'], @@ -1292,13 +1292,13 @@ return [ 'curl_upkeep' => ['bool', 'handle'=>'CurlHandle'], 'curl_unescape' => ['string|false', 'handle'=>'CurlHandle', 'string'=>'string'], 'curl_version' => ['array', 'version='=>'int'], -'CURLFile::__construct' => ['void', 'filename'=>'string', 'mimetype='=>'string', 'postfilename='=>'string'], +'CURLFile::__construct' => ['void', 'filename'=>'string', 'mime_type='=>'?string', 'posted_filename='=>'?string'], 'CURLFile::__wakeup' => ['void'], 'CURLFile::getFilename' => ['string'], 'CURLFile::getMimeType' => ['string'], 'CURLFile::getPostFilename' => ['string'], -'CURLFile::setMimeType' => ['void', 'mime'=>'string'], -'CURLFile::setPostFilename' => ['void', 'name'=>'string'], +'CURLFile::setMimeType' => ['void', 'mime_type'=>'string'], +'CURLFile::setPostFilename' => ['void', 'posted_filename'=>'string'], 'CURLStringFile::__construct' => ['void', 'data'=>'string', 'postname'=>'string', 'mime='=>'string'], 'current' => ['mixed|false', 'array'=>'array|object'], 'cyrus_authenticate' => ['void', 'connection'=>'resource', 'mechlist='=>'string', 'service='=>'string', 'user='=>'string', 'minssf='=>'int', 'maxssf='=>'int', 'authname='=>'string', 'password='=>'string'], @@ -1355,10 +1355,10 @@ return [ 'datefmt_set_lenient' => ['void', 'formatter'=>'IntlDateFormatter', 'lenient'=>'bool'], 'datefmt_set_pattern' => ['bool', 'formatter'=>'IntlDateFormatter', 'pattern'=>'string'], 'datefmt_set_timezone' => ['false|null', 'formatter'=>'IntlDateFormatter', 'timezone'=>'IntlTimeZone|DateTimeZone|string|null'], -'DateInterval::__construct' => ['void', 'spec'=>'string'], +'DateInterval::__construct' => ['void', 'duration'=>'string'], 'DateInterval::__set_state' => ['DateInterval', 'array'=>'array'], 'DateInterval::__wakeup' => ['void'], -'DateInterval::createFromDateString' => ['DateInterval|false', 'time'=>'string'], +'DateInterval::createFromDateString' => ['DateInterval|false', 'datetime'=>'string'], 'DateInterval::format' => ['string', 'format'=>'string'], 'DatePeriod::__construct' => ['void', 'start'=>'DateTimeInterface', 'interval'=>'DateInterval', 'recur'=>'int', 'options='=>'int'], 'DatePeriod::__construct\'1' => ['void', 'start'=>'DateTimeInterface', 'interval'=>'DateInterval', 'end'=>'DateTimeInterface', 'options='=>'int'], @@ -1371,20 +1371,20 @@ return [ 'DateTime::__construct\'1' => ['void', 'time'=>'?string', 'timezone'=>'?DateTimeZone'], 'DateTime::__wakeup' => ['void'], 'DateTime::add' => ['static', 'interval'=>'DateInterval'], -'DateTime::createFromFormat' => ['static|false', 'format'=>'string', 'time'=>'string', 'timezone='=>'?DateTimeZone'], +'DateTime::createFromFormat' => ['static|false', 'format'=>'string', 'datetime'=>'string', 'timezone='=>'?DateTimeZone'], 'DateTime::createFromImmutable' => ['static', 'object'=>'DateTimeImmutable'], 'DateTime::createFromInterface' => ['static', 'object' => 'DateTimeInterface'], -'DateTime::diff' => ['DateInterval', 'datetime2'=>'DateTimeInterface', 'absolute='=>'bool'], +'DateTime::diff' => ['DateInterval', 'targetObject'=>'DateTimeInterface', 'absolute='=>'bool'], 'DateTime::format' => ['string', 'format'=>'string'], 'DateTime::getLastErrors' => ['array{warning_count:int,warnings:array,error_count:int,errors:array}|false'], 'DateTime::getOffset' => ['int'], 'DateTime::getTimestamp' => ['int'], 'DateTime::getTimezone' => ['DateTimeZone|false'], -'DateTime::modify' => ['static|false', 'modify'=>'string'], +'DateTime::modify' => ['static|false', 'modifier'=>'string'], 'DateTime::setDate' => ['static', 'year'=>'int', 'month'=>'int', 'day'=>'int'], -'DateTime::setISODate' => ['static', 'year'=>'int', 'week'=>'int', 'day='=>'int'], -'DateTime::setTime' => ['static', 'hour'=>'int', 'minute'=>'int', 'second='=>'int', 'microseconds='=>'int'], -'DateTime::setTimestamp' => ['static', 'unixtimestamp'=>'int'], +'DateTime::setISODate' => ['static', 'year'=>'int', 'week'=>'int', 'dayOfWeek='=>'int'], +'DateTime::setTime' => ['static', 'hour'=>'int', 'minute'=>'int', 'second='=>'int', 'microsecond='=>'int'], +'DateTime::setTimestamp' => ['static', 'timestamp'=>'int'], 'DateTime::setTimezone' => ['static', 'timezone'=>'DateTimeZone'], 'DateTime::sub' => ['static', 'interval'=>'DateInterval'], 'DateTimeImmutable::__wakeup' => ['void'], @@ -1403,65 +1403,65 @@ return [ 'DateTimeZone::getLocation' => ['array|false'], 'DateTimeZone::getName' => ['string'], 'DateTimeZone::getOffset' => ['int', 'datetime'=>'DateTimeInterface'], -'DateTimeZone::getTransitions' => ['list|false', 'timestamp_begin='=>'int', 'timestamp_end='=>'int'], +'DateTimeZone::getTransitions' => ['list|false', 'timestampBegin='=>'int', 'timestampEnd='=>'int'], 'DateTimeZone::listAbbreviations' => ['array>'], 'DateTimeZone::listIdentifiers' => ['list', 'timezoneGroup='=>'int', 'countryCode='=>'string|null'], -'db2_autocommit' => ['mixed', 'connection'=>'resource', 'value='=>'int'], +'db2_autocommit' => ['0|1|bool', 'connection'=>'resource', 'value='=>'0|1'], 'db2_bind_param' => ['bool', 'stmt'=>'resource', 'parameter_number'=>'int', 'variable_name'=>'string', 'parameter_type='=>'int', 'data_type='=>'int', 'precision='=>'int', 'scale='=>'int'], -'db2_client_info' => ['object|false', 'connection'=>'resource'], +'db2_client_info' => ['stdClass|false', 'connection'=>'resource'], 'db2_close' => ['bool', 'connection'=>'resource'], -'db2_column_privileges' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'column_name='=>'string'], -'db2_columns' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'column_name='=>'string'], +'db2_column_privileges' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'?string', 'schema='=>'?string', 'table_name='=>'?string', 'column_name='=>'?string'], +'db2_columns' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'?string', 'schema='=>'?string', 'table_name='=>'?string', 'column_name='=>'?string'], 'db2_commit' => ['bool', 'connection'=>'resource'], 'db2_conn_error' => ['string', 'connection='=>'resource'], 'db2_conn_errormsg' => ['string', 'connection='=>'resource'], -'db2_connect' => ['resource|false', 'database'=>'string', 'username'=>'string', 'password'=>'string', 'options='=>'array'], +'db2_connect' => ['resource|false', 'database'=>'string', 'username'=>'?string', 'password'=>'?string', 'options='=>'array'], 'db2_cursor_type' => ['int', 'stmt'=>'resource'], 'db2_escape_string' => ['string', 'string_literal'=>'string'], 'db2_exec' => ['resource|false', 'connection'=>'resource', 'statement'=>'string', 'options='=>'array'], 'db2_execute' => ['bool', 'stmt'=>'resource', 'parameters='=>'array'], -'db2_fetch_array' => ['array|false', 'stmt'=>'resource', 'row_number='=>'int'], -'db2_fetch_assoc' => ['array|false', 'stmt'=>'resource', 'row_number='=>'int'], -'db2_fetch_both' => ['array|false', 'stmt'=>'resource', 'row_number='=>'int'], -'db2_fetch_object' => ['object|false', 'stmt'=>'resource', 'row_number='=>'int'], -'db2_fetch_row' => ['bool', 'stmt'=>'resource', 'row_number='=>'int'], -'db2_field_display_size' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], -'db2_field_name' => ['string|false', 'stmt'=>'resource', 'column'=>'mixed'], -'db2_field_num' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], -'db2_field_precision' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], -'db2_field_scale' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], -'db2_field_type' => ['string|false', 'stmt'=>'resource', 'column'=>'mixed'], -'db2_field_width' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], -'db2_foreign_keys' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string'], +'db2_fetch_array' => ['array|false', 'stmt'=>'resource', 'row_number='=>'?int'], +'db2_fetch_assoc' => ['array|false', 'stmt'=>'resource', 'row_number='=>'?int'], +'db2_fetch_both' => ['array|false', 'stmt'=>'resource', 'row_number='=>'?int'], +'db2_fetch_object' => ['stdClass|false', 'stmt'=>'resource', 'row_number='=>'?int'], +'db2_fetch_row' => ['bool', 'stmt'=>'resource', 'row_number='=>'?int'], +'db2_field_display_size' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], +'db2_field_name' => ['string|false', 'stmt'=>'resource', 'column'=>'string|int'], +'db2_field_num' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], +'db2_field_precision' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], +'db2_field_scale' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], +'db2_field_type' => ['string|false', 'stmt'=>'resource', 'column'=>'string|int'], +'db2_field_width' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], +'db2_foreign_keys' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'?string', 'table_name'=>'string'], 'db2_free_result' => ['bool', 'stmt'=>'resource'], 'db2_free_stmt' => ['bool', 'stmt'=>'resource'], 'db2_get_option' => ['string|false', 'resource'=>'resource', 'option'=>'string'], -'db2_last_insert_id' => ['string', 'resource'=>'resource'], +'db2_last_insert_id' => ['string|null', 'resource'=>'resource'], 'db2_lob_read' => ['string|false', 'stmt'=>'resource', 'colnum'=>'int', 'length'=>'int'], 'db2_next_result' => ['resource|false', 'stmt'=>'resource'], 'db2_num_fields' => ['int|false', 'stmt'=>'resource'], -'db2_num_rows' => ['int', 'stmt'=>'resource'], +'db2_num_rows' => ['int|false', 'stmt'=>'resource'], 'db2_pclose' => ['bool', 'resource'=>'resource'], -'db2_pconnect' => ['resource|false', 'database'=>'string', 'username'=>'string', 'password'=>'string', 'options='=>'array'], +'db2_pconnect' => ['resource|false', 'database'=>'string', 'username'=>'?string', 'password'=>'?string', 'options='=>'array'], 'db2_prepare' => ['resource|false', 'connection'=>'resource', 'statement'=>'string', 'options='=>'array'], -'db2_primary_keys' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string'], +'db2_primary_keys' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'?string', 'table_name'=>'string'], 'db2_primarykeys' => [''], -'db2_procedure_columns' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'procedure'=>'string', 'parameter'=>'string'], +'db2_procedure_columns' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'string', 'procedure'=>'string', 'parameter'=>'?string'], 'db2_procedurecolumns' => [''], -'db2_procedures' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'procedure'=>'string'], -'db2_result' => ['mixed', 'stmt'=>'resource', 'column'=>'mixed'], +'db2_procedures' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'string', 'procedure'=>'string'], +'db2_result' => ['mixed', 'stmt'=>'resource', 'column'=>'string|int'], 'db2_rollback' => ['bool', 'connection'=>'resource'], -'db2_server_info' => ['object|false', 'connection'=>'resource'], +'db2_server_info' => ['stdClass|false', 'connection'=>'resource'], 'db2_set_option' => ['bool', 'resource'=>'resource', 'options'=>'array', 'type'=>'int'], 'db2_setoption' => [''], -'db2_special_columns' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string', 'scope'=>'int'], +'db2_special_columns' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'string', 'table_name'=>'string', 'scope'=>'int'], 'db2_specialcolumns' => [''], -'db2_statistics' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string', 'unique'=>'bool'], +'db2_statistics' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'?string', 'table_name'=>'string', 'unique'=>'bool'], 'db2_stmt_error' => ['string', 'stmt='=>'resource'], 'db2_stmt_errormsg' => ['string', 'stmt='=>'resource'], -'db2_table_privileges' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string'], +'db2_table_privileges' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'?string', 'schema='=>'?string', 'table_name='=>'?string'], 'db2_tableprivileges' => [''], -'db2_tables' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'table_type='=>'string'], +'db2_tables' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'?string', 'schema='=>'?string', 'table_name='=>'?string', 'table_type='=>'?string'], 'dba_close' => ['void', 'dba'=>'resource'], 'dba_delete' => ['bool', 'key'=>'string', 'dba'=>'resource'], 'dba_exists' => ['bool', 'key'=>'string', 'dba'=>'resource'], @@ -1579,14 +1579,14 @@ return [ 'Directory::close' => ['void'], 'Directory::read' => ['string|false'], 'Directory::rewind' => ['void'], -'DirectoryIterator::__construct' => ['void', 'path'=>'string'], +'DirectoryIterator::__construct' => ['void', 'directory'=>'string'], 'DirectoryIterator::__toString' => ['string'], 'DirectoryIterator::current' => ['DirectoryIterator'], 'DirectoryIterator::getATime' => ['int'], 'DirectoryIterator::getBasename' => ['string', 'suffix='=>'string'], 'DirectoryIterator::getCTime' => ['int'], 'DirectoryIterator::getExtension' => ['string'], -'DirectoryIterator::getFileInfo' => ['SplFileInfo', 'class_name='=>'string'], +'DirectoryIterator::getFileInfo' => ['SplFileInfo', 'class='=>'?class-string'], 'DirectoryIterator::getFilename' => ['string'], 'DirectoryIterator::getGroup' => ['int'], 'DirectoryIterator::getInode' => ['int'], @@ -1594,7 +1594,7 @@ return [ 'DirectoryIterator::getMTime' => ['int'], 'DirectoryIterator::getOwner' => ['int'], 'DirectoryIterator::getPath' => ['string'], -'DirectoryIterator::getPathInfo' => ['SplFileInfo', 'class_name='=>'string'], +'DirectoryIterator::getPathInfo' => ['?SplFileInfo', 'class='=>'?class-string'], 'DirectoryIterator::getPathname' => ['string'], 'DirectoryIterator::getPerms' => ['int'], 'DirectoryIterator::getRealPath' => ['string'], @@ -1609,11 +1609,11 @@ return [ 'DirectoryIterator::isWritable' => ['bool'], 'DirectoryIterator::key' => ['string'], 'DirectoryIterator::next' => ['void'], -'DirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>'resource'], +'DirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], 'DirectoryIterator::rewind' => ['void'], -'DirectoryIterator::seek' => ['void', 'position'=>'int'], -'DirectoryIterator::setFileClass' => ['void', 'class_name='=>'string'], -'DirectoryIterator::setInfoClass' => ['void', 'class_name='=>'string'], +'DirectoryIterator::seek' => ['void', 'offset'=>'int'], +'DirectoryIterator::setFileClass' => ['void', 'class='=>'class-string'], +'DirectoryIterator::setInfoClass' => ['void', 'class='=>'class-string'], 'DirectoryIterator::valid' => ['bool'], 'dirname' => ['string', 'path'=>'string', 'levels='=>'int'], 'disk_free_space' => ['float|false', 'directory'=>'string'], @@ -1651,48 +1651,48 @@ return [ 'DOMAttr::getNodePath' => ['?string'], 'DOMAttr::hasAttributes' => ['bool'], 'DOMAttr::hasChildNodes' => ['bool'], -'DOMAttr::insertBefore' => ['DOMNode', 'newnode'=>'DOMNode', 'refnode='=>'DOMNode'], -'DOMAttr::isDefaultNamespace' => ['bool', 'namespaceuri'=>'string'], +'DOMAttr::insertBefore' => ['DOMNode|false', 'node'=>'DOMNode', 'child='=>'?DOMNode'], +'DOMAttr::isDefaultNamespace' => ['bool', 'namespace'=>'string'], 'DOMAttr::isId' => ['bool'], -'DOMAttr::isSameNode' => ['bool', 'node'=>'DOMNode'], +'DOMAttr::isSameNode' => ['bool', 'otherNode'=>'DOMNode'], 'DOMAttr::isSupported' => ['bool', 'feature'=>'string', 'version'=>'string'], 'DOMAttr::lookupNamespaceUri' => ['string|null', 'prefix'=>'string|null'], -'DOMAttr::lookupPrefix' => ['string|null', 'namespaceuri'=>'string'], +'DOMAttr::lookupPrefix' => ['string|null', 'namespace'=>'string'], 'DOMAttr::normalize' => ['void'], -'DOMAttr::removeChild' => ['DOMNode', 'oldnode'=>'DOMNode'], -'DOMAttr::replaceChild' => ['DOMNode', 'newnode'=>'DOMNode', 'oldnode'=>'DOMNode'], +'DOMAttr::removeChild' => ['DOMNode|false', 'child'=>'DOMNode'], +'DOMAttr::replaceChild' => ['DOMNode|false', 'node'=>'DOMNode', 'child'=>'DOMNode'], 'DomAttribute::name' => ['string'], 'DomAttribute::set_value' => ['bool', 'content'=>'string'], 'DomAttribute::specified' => ['bool'], 'DomAttribute::value' => ['string'], -'DOMCdataSection::__construct' => ['void', 'value'=>'string'], +'DOMCdataSection::__construct' => ['void', 'data'=>'string'], 'DOMCharacterData::appendData' => ['true', 'data'=>'string'], 'DOMCharacterData::deleteData' => ['bool', 'offset'=>'int', 'count'=>'int'], 'DOMCharacterData::insertData' => ['bool', 'offset'=>'int', 'data'=>'string'], 'DOMCharacterData::replaceData' => ['bool', 'offset'=>'int', 'count'=>'int', 'data'=>'string'], 'DOMCharacterData::substringData' => ['string', 'offset'=>'int', 'count'=>'int'], -'DOMComment::__construct' => ['void', 'value='=>'string'], +'DOMComment::__construct' => ['void', 'data='=>'string'], 'DOMDocument::__construct' => ['void', 'version='=>'string', 'encoding='=>'string'], -'DOMDocument::createAttribute' => ['DOMAttr|false', 'name'=>'string'], -'DOMDocument::createAttributeNS' => ['DOMAttr|false', 'namespaceuri'=>'string|null', 'qualifiedname'=>'string'], +'DOMDocument::createAttribute' => ['DOMAttr|false', 'localName'=>'string'], +'DOMDocument::createAttributeNS' => ['DOMAttr|false', 'namespace'=>'string|null', 'qualifiedName'=>'string'], 'DOMDocument::createCDATASection' => ['DOMCDATASection|false', 'data'=>'string'], 'DOMDocument::createComment' => ['DOMComment', 'data'=>'string'], 'DOMDocument::createDocumentFragment' => ['DOMDocumentFragment'], -'DOMDocument::createElement' => ['DOMElement|false', 'name'=>'string', 'value='=>'string'], -'DOMDocument::createElementNS' => ['DOMElement|false', 'namespaceuri'=>'string|null', 'qualifiedname'=>'string', 'value='=>'string'], +'DOMDocument::createElement' => ['DOMElement|false', 'localName'=>'string', 'value='=>'string'], +'DOMDocument::createElementNS' => ['DOMElement|false', 'namespace'=>'string|null', 'qualifiedName'=>'string', 'value='=>'string'], 'DOMDocument::createEntityReference' => ['DOMEntityReference|false', 'name'=>'string'], 'DOMDocument::createProcessingInstruction' => ['DOMProcessingInstruction|false', 'target'=>'string', 'data='=>'string'], -'DOMDocument::createTextNode' => ['DOMText|false', 'content'=>'string'], -'DOMDocument::getElementById' => ['?DOMElement', 'elementid'=>'string'], -'DOMDocument::getElementsByTagName' => ['DOMNodeList', 'name'=>'string'], -'DOMDocument::getElementsByTagNameNS' => ['DOMNodeList', 'namespaceuri'=>'string|null', 'localname'=>'string'], -'DOMDocument::importNode' => ['DOMNode|false', 'importednode'=>'DOMNode', 'deep='=>'bool'], +'DOMDocument::createTextNode' => ['DOMText', 'data'=>'string'], +'DOMDocument::getElementById' => ['?DOMElement', 'elementId'=>'string'], +'DOMDocument::getElementsByTagName' => ['DOMNodeList', 'qualifiedName'=>'string'], +'DOMDocument::getElementsByTagNameNS' => ['DOMNodeList', 'namespace'=>'?string', 'localName'=>'string'], +'DOMDocument::importNode' => ['DOMNode|false', 'node'=>'DOMNode', 'deep='=>'bool'], 'DOMDocument::load' => ['DOMDocument|bool', 'filename'=>'string', 'options='=>'int'], 'DOMDocument::loadHTML' => ['bool', 'source'=>'non-empty-string', 'options='=>'int'], 'DOMDocument::loadHTMLFile' => ['bool', 'filename'=>'string', 'options='=>'int'], 'DOMDocument::loadXML' => ['DOMDocument|bool', 'source'=>'non-empty-string', 'options='=>'int'], 'DOMDocument::normalizeDocument' => ['void'], -'DOMDocument::registerNodeClass' => ['bool', 'baseclass'=>'string', 'extendedclass'=>'string'], +'DOMDocument::registerNodeClass' => ['bool', 'baseClass'=>'string', 'extendedClass'=>'?string'], 'DOMDocument::relaxNGValidate' => ['bool', 'filename'=>'string'], 'DOMDocument::relaxNGValidateSource' => ['bool', 'source'=>'string'], 'DOMDocument::save' => ['int|false', 'filename'=>'string', 'options='=>'int'], @@ -1705,55 +1705,55 @@ return [ 'DOMDocument::xinclude' => ['int', 'options='=>'int'], 'DOMDocumentFragment::__construct' => ['void'], 'DOMDocumentFragment::appendXML' => ['bool', 'data'=>'string'], -'DOMElement::__construct' => ['void', 'name'=>'string', 'value='=>'string', 'uri='=>'string'], -'DOMElement::getAttribute' => ['string', 'name'=>'string'], -'DOMElement::getAttributeNode' => ['DOMAttr', 'name'=>'string'], -'DOMElement::getAttributeNodeNS' => ['DOMAttr', 'namespaceuri'=>'string|null', 'localname'=>'string'], -'DOMElement::getAttributeNS' => ['string', 'namespaceuri'=>'string|null', 'localname'=>'string'], -'DOMElement::getElementsByTagName' => ['DOMNodeList', 'name'=>'string'], -'DOMElement::getElementsByTagNameNS' => ['DOMNodeList', 'namespaceuri'=>'string|null', 'localname'=>'string'], -'DOMElement::hasAttribute' => ['bool', 'name'=>'string'], -'DOMElement::hasAttributeNS' => ['bool', 'namespaceuri'=>'string|null', 'localname'=>'string'], -'DOMElement::removeAttribute' => ['bool', 'name'=>'string'], -'DOMElement::removeAttributeNode' => ['bool', 'oldnode'=>'DOMAttr'], -'DOMElement::removeAttributeNS' => ['bool', 'namespaceuri'=>'string|null', 'localname'=>'string'], -'DOMElement::setAttribute' => ['DOMAttr|false', 'name'=>'string', 'value'=>'string'], +'DOMElement::__construct' => ['void', 'qualifiedName'=>'string', 'value='=>'?string', 'namespace='=>'string'], +'DOMElement::getAttribute' => ['string', 'qualifiedName'=>'string'], +'DOMElement::getAttributeNode' => ['DOMAttr', 'qualifiedName'=>'string'], +'DOMElement::getAttributeNodeNS' => ['DOMAttr', 'namespace'=>'string|null', 'localName'=>'string'], +'DOMElement::getAttributeNS' => ['string', 'namespace'=>'string|null', 'localName'=>'string'], +'DOMElement::getElementsByTagName' => ['DOMNodeList', 'qualifiedName'=>'string'], +'DOMElement::getElementsByTagNameNS' => ['DOMNodeList', 'namespace'=>'string|null', 'localName'=>'string'], +'DOMElement::hasAttribute' => ['bool', 'qualifiedName'=>'string'], +'DOMElement::hasAttributeNS' => ['bool', 'namespace'=>'string|null', 'localName'=>'string'], +'DOMElement::removeAttribute' => ['bool', 'qualifiedName'=>'string'], +'DOMElement::removeAttributeNode' => ['DOMAttr|false', 'attr'=>'DOMAttr'], +'DOMElement::removeAttributeNS' => ['void', 'namespace'=>'string|null', 'localName'=>'string'], +'DOMElement::setAttribute' => ['DOMAttr|false', 'qualifiedName'=>'string', 'value'=>'string'], 'DOMElement::setAttributeNode' => ['?DOMAttr', 'attr'=>'DOMAttr'], 'DOMElement::setAttributeNodeNS' => ['DOMAttr', 'attr'=>'DOMAttr'], -'DOMElement::setAttributeNS' => ['void', 'namespaceuri'=>'string|null', 'qualifiedname'=>'string', 'value'=>'string'], -'DOMElement::setIdAttribute' => ['void', 'name'=>'string', 'isid'=>'bool'], -'DOMElement::setIdAttributeNode' => ['void', 'attr'=>'DOMAttr', 'isid'=>'bool'], -'DOMElement::setIdAttributeNS' => ['void', 'namespaceuri'=>'string', 'localname'=>'string', 'isid'=>'bool'], +'DOMElement::setAttributeNS' => ['void', 'namespace'=>'string|null', 'qualifiedName'=>'string', 'value'=>'string'], +'DOMElement::setIdAttribute' => ['void', 'qualifiedName'=>'string', 'isId'=>'bool'], +'DOMElement::setIdAttributeNode' => ['void', 'attr'=>'DOMAttr', 'isId'=>'bool'], +'DOMElement::setIdAttributeNS' => ['void', 'namespace'=>'string', 'qualifiedName'=>'string', 'isId'=>'bool'], 'DOMEntityReference::__construct' => ['void', 'name'=>'string'], 'DOMImplementation::__construct' => ['void'], -'DOMImplementation::createDocument' => ['DOMDocument', 'namespaceuri='=>'string', 'qualifiedname='=>'string', 'doctype='=>'DOMDocumentType'], -'DOMImplementation::createDocumentType' => ['DOMDocumentType', 'qualifiedname='=>'string', 'publicid='=>'string', 'systemid='=>'string'], +'DOMImplementation::createDocument' => ['DOMDocument|false', 'namespace='=>'?string', 'qualifiedName='=>'string', 'doctype='=>'?DOMDocumentType'], +'DOMImplementation::createDocumentType' => ['DOMDocumentType|false', 'qualifiedName'=>'string', 'publicId='=>'string', 'systemId='=>'string'], 'DOMImplementation::hasFeature' => ['bool', 'feature'=>'string', 'version'=>'string'], 'DOMNamedNodeMap::count' => ['int'], -'DOMNamedNodeMap::getNamedItem' => ['?DOMNode', 'name'=>'string'], -'DOMNamedNodeMap::getNamedItemNS' => ['?DOMNode', 'namespaceuri'=>'string', 'localname'=>'string'], +'DOMNamedNodeMap::getNamedItem' => ['?DOMNode', 'qualifiedName'=>'string'], +'DOMNamedNodeMap::getNamedItemNS' => ['?DOMNode', 'namespace'=>'?string', 'localName'=>'string'], 'DOMNamedNodeMap::item' => ['?DOMNode', 'index'=>'int'], -'DOMNode::appendChild' => ['DOMNode', 'newnode'=>'DOMNode'], -'DOMNode::C14N' => ['string', 'exclusive='=>'bool', 'with_comments='=>'bool', 'xpath='=>'array', 'ns_prefixes='=>'array'], -'DOMNode::C14NFile' => ['int|false', 'uri='=>'string', 'exclusive='=>'bool', 'with_comments='=>'bool', 'xpath='=>'array', 'ns_prefixes='=>'array'], +'DOMNode::appendChild' => ['DOMNode|false', 'node'=>'DOMNode'], +'DOMNode::C14N' => ['string|false', 'exclusive='=>'bool', 'withComments='=>'bool', 'xpath='=>'?array', 'nsPrefixes='=>'?array'], +'DOMNode::C14NFile' => ['int|false', 'uri'=>'string', 'exclusive='=>'bool', 'withComments='=>'bool', 'xpath='=>'?array', 'nsPrefixes='=>'?array'], 'DOMNode::cloneNode' => ['DOMNode', 'deep='=>'bool'], 'DOMNode::getLineNo' => ['int'], 'DOMNode::getNodePath' => ['?string'], 'DOMNode::hasAttributes' => ['bool'], 'DOMNode::hasChildNodes' => ['bool'], -'DOMNode::insertBefore' => ['DOMNode', 'newnode'=>'DOMNode', 'refnode='=>'DOMNode|null'], -'DOMNode::isDefaultNamespace' => ['bool', 'namespaceuri'=>'string'], -'DOMNode::isSameNode' => ['bool', 'node'=>'DOMNode'], +'DOMNode::insertBefore' => ['DOMNode|false', 'node'=>'DOMNode', 'child='=>'?DOMNode'], +'DOMNode::isDefaultNamespace' => ['bool', 'namespace'=>'string'], +'DOMNode::isSameNode' => ['bool', 'otherNode'=>'DOMNode'], 'DOMNode::isSupported' => ['bool', 'feature'=>'string', 'version'=>'string'], 'DOMNode::lookupNamespaceURI' => ['string|null', 'prefix'=>'string|null'], -'DOMNode::lookupPrefix' => ['string|null', 'namespaceuri'=>'string'], +'DOMNode::lookupPrefix' => ['string|null', 'namespace'=>'string'], 'DOMNode::normalize' => ['void'], -'DOMNode::removeChild' => ['DOMNode', 'oldnode'=>'DOMNode'], -'DOMNode::replaceChild' => ['DOMNode|false', 'newnode'=>'DOMNode', 'oldnode'=>'DOMNode'], +'DOMNode::removeChild' => ['DOMNode|false', 'child'=>'DOMNode'], +'DOMNode::replaceChild' => ['DOMNode|false', 'node'=>'DOMNode', 'child'=>'DOMNode'], 'DOMNodeList::count' => ['int'], 'DOMNodeList::item' => ['?DOMNode', 'index'=>'int'], -'DOMProcessingInstruction::__construct' => ['void', 'name'=>'string', 'value'=>'string'], -'DOMText::__construct' => ['void', 'value='=>'string'], +'DOMProcessingInstruction::__construct' => ['void', 'name'=>'string', 'value='=>'string'], +'DOMText::__construct' => ['void', 'data='=>'string'], 'DOMText::isElementContentWhitespace' => ['bool'], 'DOMText::isWhitespaceInElementContent' => ['bool'], 'DOMText::splitText' => ['DOMText', 'offset'=>'int'], @@ -1766,11 +1766,11 @@ return [ 'domxml_xslt_stylesheet_doc' => ['DomXsltStylesheet', 'xsl_doc'=>'DOMDocument'], 'domxml_xslt_stylesheet_file' => ['DomXsltStylesheet', 'xsl_file'=>'string'], 'domxml_xslt_version' => ['int'], -'DOMXPath::__construct' => ['void', 'doc'=>'DOMDocument'], -'DOMXPath::evaluate' => ['mixed', 'expression'=>'string', 'contextnode='=>'?DOMNode', 'registernodens='=>'bool'], -'DOMXPath::query' => ['DOMNodeList|false', 'expression'=>'string', 'contextnode='=>'DOMNode|null', 'registernodens='=>'bool'], -'DOMXPath::registerNamespace' => ['bool', 'prefix'=>'string', 'namespaceuri'=>'string'], -'DOMXPath::registerPhpFunctions' => ['void', 'restrict='=>'mixed'], +'DOMXPath::__construct' => ['void', 'document'=>'DOMDocument', 'registerNodeNS='=>'bool'], +'DOMXPath::evaluate' => ['mixed', 'expression'=>'string', 'contextNode='=>'?DOMNode', 'registerNodeNS='=>'bool'], +'DOMXPath::query' => ['DOMNodeList|false', 'expression'=>'string', 'contextNode='=>'?DOMNode', 'registerNodeNS='=>'bool'], +'DOMXPath::registerNamespace' => ['bool', 'prefix'=>'string', 'namespace'=>'string'], +'DOMXPath::registerPhpFunctions' => ['void', 'restrict='=>'array|string|null'], 'DomXsltStylesheet::process' => ['DomDocument', 'xml_doc'=>'DOMDocument', 'xslt_params='=>'array', 'is_xpath_param='=>'bool', 'profile_filename='=>'string'], 'DomXsltStylesheet::result_dump_file' => ['string', 'xmldoc'=>'DOMDocument', 'filename'=>'string'], 'DomXsltStylesheet::result_dump_mem' => ['string', 'xmldoc'=>'DOMDocument'], @@ -2817,14 +2817,14 @@ return [ 'filepro_retrieve' => ['string', 'row_number'=>'int', 'field_number'=>'int'], 'filepro_rowcount' => ['int'], 'filesize' => ['int|false', 'filename'=>'string'], -'FilesystemIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'], +'FilesystemIterator::__construct' => ['void', 'directory'=>'string', 'flags='=>'int'], 'FilesystemIterator::__toString' => ['string'], 'FilesystemIterator::current' => ['SplFileInfo|FilesystemIterator|string'], 'FilesystemIterator::getATime' => ['int'], 'FilesystemIterator::getBasename' => ['string', 'suffix='=>'string'], 'FilesystemIterator::getCTime' => ['int'], 'FilesystemIterator::getExtension' => ['string'], -'FilesystemIterator::getFileInfo' => ['SplFileInfo', 'class_name='=>'string'], +'FilesystemIterator::getFileInfo' => ['SplFileInfo', 'class='=>'?class-string'], 'FilesystemIterator::getFilename' => ['string'], 'FilesystemIterator::getFlags' => ['int'], 'FilesystemIterator::getGroup' => ['int'], @@ -2833,7 +2833,7 @@ return [ 'FilesystemIterator::getMTime' => ['int'], 'FilesystemIterator::getOwner' => ['int'], 'FilesystemIterator::getPath' => ['string'], -'FilesystemIterator::getPathInfo' => ['SplFileInfo', 'class_name='=>'string'], +'FilesystemIterator::getPathInfo' => ['?SplFileInfo', 'class='=>'?class-string'], 'FilesystemIterator::getPathname' => ['string'], 'FilesystemIterator::getPerms' => ['int'], 'FilesystemIterator::getRealPath' => ['string'], @@ -2848,12 +2848,12 @@ return [ 'FilesystemIterator::isWritable' => ['bool'], 'FilesystemIterator::key' => ['string'], 'FilesystemIterator::next' => ['void'], -'FilesystemIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>'resource'], +'FilesystemIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], 'FilesystemIterator::rewind' => ['void'], -'FilesystemIterator::seek' => ['void', 'position'=>'int'], -'FilesystemIterator::setFileClass' => ['void', 'class_name='=>'string'], -'FilesystemIterator::setFlags' => ['void', 'flags='=>'int'], -'FilesystemIterator::setInfoClass' => ['void', 'class_name='=>'string'], +'FilesystemIterator::seek' => ['void', 'offset'=>'int'], +'FilesystemIterator::setFileClass' => ['void', 'class='=>'class-string'], +'FilesystemIterator::setFlags' => ['void', 'flags'=>'int'], +'FilesystemIterator::setInfoClass' => ['void', 'class='=>'class-string'], 'FilesystemIterator::valid' => ['bool'], 'filetype' => ['string|false', 'filename'=>'string'], 'filter_has_var' => ['bool', 'input_type'=>'int', 'var_name'=>'string'], @@ -2951,7 +2951,7 @@ return [ 'gc_enable' => ['void'], 'gc_enabled' => ['bool'], 'gc_mem_caches' => ['int'], -'gc_status' => ['array{runs:int,collected:int,threshold:int,roots:int}'], +'gc_status' => ['array{runs:int,collected:int,threshold:int,roots:int,running:bool,protected:bool,full:bool,buffer_size:int}'], 'gd_info' => ['array'], 'gearman_bugreport' => [''], 'gearman_client_add_options' => ['', 'client_object'=>'', 'option'=>''], @@ -3334,14 +3334,14 @@ return [ 'gettimeofday\'1' => ['float', 'as_float='=>'true'], 'gettype' => ['string', 'value'=>'mixed'], 'glob' => ['list|false', 'pattern'=>'string', 'flags='=>'int'], -'GlobIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'], +'GlobIterator::__construct' => ['void', 'pattern'=>'string', 'flags='=>'int'], 'GlobIterator::count' => ['int'], 'GlobIterator::current' => ['FilesystemIterator|SplFileInfo|string'], 'GlobIterator::getATime' => ['int'], 'GlobIterator::getBasename' => ['string', 'suffix='=>'string'], 'GlobIterator::getCTime' => ['int'], 'GlobIterator::getExtension' => ['string'], -'GlobIterator::getFileInfo' => ['SplFileInfo'], +'GlobIterator::getFileInfo' => ['SplFileInfo', 'class='=>'?class-string'], 'GlobIterator::getFilename' => ['string'], 'GlobIterator::getFlags' => ['int'], 'GlobIterator::getGroup' => ['int'], @@ -3350,7 +3350,7 @@ return [ 'GlobIterator::getMTime' => ['int'], 'GlobIterator::getOwner' => ['int'], 'GlobIterator::getPath' => ['string'], -'GlobIterator::getPathInfo' => ['?SplFileInfo'], +'GlobIterator::getPathInfo' => ['?SplFileInfo', 'class='=>'?class-string'], 'GlobIterator::getPathname' => ['string'], 'GlobIterator::getPerms' => ['int'], 'GlobIterator::getRealPath' => ['string|false'], @@ -3365,12 +3365,12 @@ return [ 'GlobIterator::isWritable' => ['bool'], 'GlobIterator::key' => ['string'], 'GlobIterator::next' => ['void'], -'GlobIterator::openFile' => ['SplFileObject'], +'GlobIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], 'GlobIterator::rewind' => ['void'], -'GlobIterator::seek' => ['void', 'position'=>'int'], -'GlobIterator::setFileClass' => ['void'], -'GlobIterator::setFlags' => ['void', 'flags='=>'int'], -'GlobIterator::setInfoClass' => ['void'], +'GlobIterator::seek' => ['void', 'offset'=>'int'], +'GlobIterator::setFileClass' => ['void', 'class='=>'class-string'], +'GlobIterator::setFlags' => ['void', 'flags'=>'int'], +'GlobIterator::setInfoClass' => ['void', 'class='=>'class-string'], 'GlobIterator::valid' => ['bool'], 'Gmagick::__construct' => ['void', 'filename='=>'string'], 'Gmagick::addimage' => ['Gmagick', 'gmagick'=>'gmagick'], @@ -5735,8 +5735,8 @@ return [ 'IntlBreakIterator::following' => ['int', 'offset'=>'int'], 'IntlBreakIterator::getErrorCode' => ['int'], 'IntlBreakIterator::getErrorMessage' => ['string'], -'IntlBreakIterator::getLocale' => ['string', 'locale_type'=>'string'], -'IntlBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'key_type='=>'int'], +'IntlBreakIterator::getLocale' => ['string|false', 'type'=>'int'], +'IntlBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'type='=>'string'], 'IntlBreakIterator::getText' => ['?string'], 'IntlBreakIterator::isBoundary' => ['bool', 'offset'=>'int'], 'IntlBreakIterator::last' => ['int'], @@ -5750,8 +5750,8 @@ return [ 'intlcal_clear' => ['bool', 'calendar'=>'IntlCalendar', 'field='=>'?int'], 'intlcal_create_instance' => ['?IntlCalendar', 'timezone='=>'mixed', 'locale='=>'?string'], 'intlcal_equals' => ['bool', 'calendar'=>'IntlCalendar', 'other'=>'IntlCalendar'], -'intlcal_field_difference' => ['int', 'calendar'=>'IntlCalendar', 'timestamp'=>'float', 'field'=>'int'], -'intlcal_from_date_time' => ['IntlCalendar', 'datetime'=>'DateTime|string'], +'intlcal_field_difference' => ['int|false', 'calendar'=>'IntlCalendar', 'timestamp'=>'float', 'field'=>'int'], +'intlcal_from_date_time' => ['?IntlCalendar', 'datetime'=>'DateTime|string', 'locale='=>'?string'], 'intlcal_get' => ['int|false', 'calendar'=>'IntlCalendar', 'field'=>'int'], 'intlcal_get_actual_maximum' => ['int', 'calendar'=>'IntlCalendar', 'field'=>'int'], 'intlcal_get_actual_minimum' => ['int', 'calendar'=>'IntlCalendar', 'field'=>'int'], @@ -5771,7 +5771,7 @@ return [ 'intlcal_get_time' => ['float', 'calendar'=>'IntlCalendar'], 'intlcal_get_time_zone' => ['IntlTimeZone', 'calendar'=>'IntlCalendar'], 'intlcal_get_type' => ['string', 'calendar'=>'IntlCalendar'], -'intlcal_get_weekend_transition' => ['int', 'calendar'=>'IntlCalendar', 'dayOfWeek'=>'string'], +'intlcal_get_weekend_transition' => ['int|false', 'calendar'=>'IntlCalendar', 'dayOfWeek'=>'int'], 'intlcal_in_daylight_time' => ['bool', 'calendar'=>'IntlCalendar'], 'intlcal_is_equivalent_to' => ['bool', 'calendar'=>'IntlCalendar', 'other'=>'IntlCalendar'], 'intlcal_is_lenient' => ['bool', 'calendar'=>'IntlCalendar'], @@ -5782,20 +5782,20 @@ return [ 'intlcal_set\'1' => ['bool', 'calendar'=>'IntlCalendar', 'year'=>'int', 'month'=>'int', 'dayOfMonth='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'], 'intlcal_set_first_day_of_week' => ['bool', 'calendar'=>'IntlCalendar', 'dayOfWeek'=>'int'], 'intlcal_set_lenient' => ['bool', 'calendar'=>'IntlCalendar', 'lenient'=>'bool'], -'intlcal_set_repeated_wall_time_option' => ['bool', 'calendar'=>'IntlCalendar', 'option'=>'int'], -'intlcal_set_skipped_wall_time_option' => ['bool', 'calendar'=>'IntlCalendar', 'option'=>'int'], +'intlcal_set_repeated_wall_time_option' => ['true', 'calendar'=>'IntlCalendar', 'option'=>'int'], +'intlcal_set_skipped_wall_time_option' => ['true', 'calendar'=>'IntlCalendar', 'option'=>'int'], 'intlcal_set_time' => ['bool', 'calendar'=>'IntlCalendar', 'timestamp'=>'float'], 'intlcal_set_time_zone' => ['bool', 'calendar'=>'IntlCalendar', 'timezone'=>'mixed'], 'intlcal_to_date_time' => ['DateTime|false', 'calendar'=>'IntlCalendar'], 'IntlCalendar::__construct' => ['void'], -'IntlCalendar::add' => ['bool', 'field'=>'int', 'amount'=>'int'], +'IntlCalendar::add' => ['bool', 'field'=>'int', 'value'=>'int'], 'IntlCalendar::after' => ['bool', 'other'=>'IntlCalendar'], 'IntlCalendar::before' => ['bool', 'other'=>'IntlCalendar'], 'IntlCalendar::clear' => ['bool', 'field='=>'?int'], -'IntlCalendar::createInstance' => ['IntlCalendar', 'timeZone='=>'mixed', 'locale='=>'string'], +'IntlCalendar::createInstance' => ['?IntlCalendar', 'timezone='=>'IntlTimeZone|DateTimeZone|string|null', 'locale='=>'?string'], 'IntlCalendar::equals' => ['bool', 'other'=>'IntlCalendar'], -'IntlCalendar::fieldDifference' => ['int', 'when'=>'float', 'field'=>'int'], -'IntlCalendar::fromDateTime' => ['IntlCalendar', 'dateTime'=>'DateTime|string'], +'IntlCalendar::fieldDifference' => ['int|false', 'timestamp'=>'float', 'field'=>'int'], +'IntlCalendar::fromDateTime' => ['?IntlCalendar', 'datetime'=>'DateTime|string', 'locale='=>'?string'], 'IntlCalendar::get' => ['int', 'field'=>'int'], 'IntlCalendar::getActualMaximum' => ['int', 'field'=>'int'], 'IntlCalendar::getActualMinimum' => ['int', 'field'=>'int'], @@ -5805,9 +5805,9 @@ return [ 'IntlCalendar::getErrorMessage' => ['string'], 'IntlCalendar::getFirstDayOfWeek' => ['int'], 'IntlCalendar::getGreatestMinimum' => ['int', 'field'=>'int'], -'IntlCalendar::getKeywordValuesForLocale' => ['Iterator|false', 'key'=>'string', 'locale'=>'string', 'commonlyUsed'=>'bool'], +'IntlCalendar::getKeywordValuesForLocale' => ['IntlIterator|false', 'keyword'=>'string', 'locale'=>'string', 'onlyCommon'=>'bool'], 'IntlCalendar::getLeastMaximum' => ['int', 'field'=>'int'], -'IntlCalendar::getLocale' => ['string', 'localeType'=>'int'], +'IntlCalendar::getLocale' => ['string|false', 'type'=>'int'], 'IntlCalendar::getMaximum' => ['int|false', 'field'=>'int'], 'IntlCalendar::getMinimalDaysInFirstWeek' => ['int'], 'IntlCalendar::getMinimum' => ['int', 'field'=>'int'], @@ -5817,82 +5817,82 @@ return [ 'IntlCalendar::getTime' => ['float'], 'IntlCalendar::getTimeZone' => ['IntlTimeZone'], 'IntlCalendar::getType' => ['string'], -'IntlCalendar::getWeekendTransition' => ['int', 'dayOfWeek'=>'string'], +'IntlCalendar::getWeekendTransition' => ['int|false', 'dayOfWeek'=>'int'], 'IntlCalendar::inDaylightTime' => ['bool'], 'IntlCalendar::isEquivalentTo' => ['bool', 'other'=>'IntlCalendar'], 'IntlCalendar::isLenient' => ['bool'], 'IntlCalendar::isSet' => ['bool', 'field'=>'int'], -'IntlCalendar::isWeekend' => ['bool', 'date='=>'?float'], -'IntlCalendar::roll' => ['bool', 'field'=>'int', 'amountOrUpOrDown'=>'mixed'], +'IntlCalendar::isWeekend' => ['bool', 'timestamp='=>'?float'], +'IntlCalendar::roll' => ['bool', 'field'=>'int', 'value'=>'int|bool'], 'IntlCalendar::set' => ['bool', 'field'=>'int', 'value'=>'int'], 'IntlCalendar::set\'1' => ['bool', 'year'=>'int', 'month'=>'int', 'dayOfMonth='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'], 'IntlCalendar::setFirstDayOfWeek' => ['bool', 'dayOfWeek'=>'int'], -'IntlCalendar::setLenient' => ['bool', 'isLenient'=>'string'], -'IntlCalendar::setMinimalDaysInFirstWeek' => ['bool', 'minimalDays'=>'int'], -'IntlCalendar::setRepeatedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'], -'IntlCalendar::setSkippedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'], -'IntlCalendar::setTime' => ['bool', 'date'=>'float'], -'IntlCalendar::setTimeZone' => ['bool', 'timeZone'=>'mixed'], +'IntlCalendar::setLenient' => ['true', 'lenient'=>'bool'], +'IntlCalendar::setMinimalDaysInFirstWeek' => ['bool', 'days'=>'int'], +'IntlCalendar::setRepeatedWallTimeOption' => ['true', 'option'=>'int'], +'IntlCalendar::setSkippedWallTimeOption' => ['true', 'option'=>'int'], +'IntlCalendar::setTime' => ['bool', 'timestamp'=>'float'], +'IntlCalendar::setTimeZone' => ['bool', 'timezone'=>'IntlTimeZone|DateTimeZone|string|null'], 'IntlCalendar::toDateTime' => ['DateTime|false'], -'IntlChar::charAge' => ['array', 'char'=>'int|string'], -'IntlChar::charDigitValue' => ['int', 'codepoint'=>'mixed'], -'IntlChar::charDirection' => ['int', 'codepoint'=>'mixed'], -'IntlChar::charFromName' => ['?int', 'name'=>'string', 'namechoice='=>'int'], -'IntlChar::charMirror' => ['mixed', 'codepoint'=>'mixed'], -'IntlChar::charName' => ['string', 'char'=>'int|string', 'namechoice='=>'int'], -'IntlChar::charType' => ['int', 'codepoint'=>'mixed'], -'IntlChar::chr' => ['string', 'codepoint'=>'mixed'], -'IntlChar::digit' => ['int|false', 'char'=>'int|string', 'radix='=>'int'], -'IntlChar::enumCharNames' => ['void', 'start'=>'mixed', 'limit'=>'mixed', 'callback'=>'callable', 'nameChoice='=>'int'], -'IntlChar::enumCharTypes' => ['void', 'cb='=>'callable'], -'IntlChar::foldCase' => ['int|string', 'char'=>'int|string', 'options='=>'int'], -'IntlChar::forDigit' => ['int', 'digit'=>'int', 'radix'=>'int'], -'IntlChar::getBidiPairedBracket' => ['mixed', 'codepoint'=>'mixed'], -'IntlChar::getBlockCode' => ['int', 'char'=>'int|string'], -'IntlChar::getCombiningClass' => ['int', 'codepoint'=>'mixed'], -'IntlChar::getFC_NFKC_Closure' => ['string', 'char'=>'int|string'], +'IntlChar::charAge' => ['?array', 'codepoint'=>'int|string'], +'IntlChar::charDigitValue' => ['?int', 'codepoint'=>'int|string'], +'IntlChar::charDirection' => ['?int', 'codepoint'=>'int|string'], +'IntlChar::charFromName' => ['?int', 'name'=>'string', 'type='=>'int'], +'IntlChar::charMirror' => ['int|string|null', 'codepoint'=>'int|string'], +'IntlChar::charName' => ['?string', 'codepoint'=>'int|string', 'type='=>'int'], +'IntlChar::charType' => ['?int', 'codepoint'=>'int|string'], +'IntlChar::chr' => ['?string', 'codepoint'=>'int|string'], +'IntlChar::digit' => ['int|false|null', 'codepoint'=>'int|string', 'base='=>'int'], +'IntlChar::enumCharNames' => ['?bool', 'start'=>'string|int', 'end'=>'string|int', 'callback'=>'callable(int,int,int):void', 'type='=>'int'], +'IntlChar::enumCharTypes' => ['void', 'callback'=>'callable(int,int,int):void'], +'IntlChar::foldCase' => ['int|string|null', 'codepoint'=>'int|string', 'options='=>'int'], +'IntlChar::forDigit' => ['int', 'digit'=>'int', 'base='=>'int'], +'IntlChar::getBidiPairedBracket' => ['int|string|null', 'codepoint'=>'int|string'], +'IntlChar::getBlockCode' => ['?int', 'codepoint'=>'int|string'], +'IntlChar::getCombiningClass' => ['?int', 'codepoint'=>'int|string'], +'IntlChar::getFC_NFKC_Closure' => ['?string', 'codepoint'=>'int|string'], 'IntlChar::getIntPropertyMaxValue' => ['int', 'property'=>'int'], 'IntlChar::getIntPropertyMinValue' => ['int', 'property'=>'int'], -'IntlChar::getIntPropertyValue' => ['int', 'char'=>'int|string', 'property'=>'int'], -'IntlChar::getNumericValue' => ['float', 'char'=>'int|string'], +'IntlChar::getIntPropertyValue' => ['?int', 'codepoint'=>'int|string', 'property'=>'int'], +'IntlChar::getNumericValue' => ['?float', 'codepoint'=>'int|string'], 'IntlChar::getPropertyEnum' => ['int', 'alias'=>'string'], -'IntlChar::getPropertyName' => ['string|false', 'property'=>'int', 'namechoice='=>'int'], +'IntlChar::getPropertyName' => ['string|false', 'property'=>'int', 'type='=>'int'], 'IntlChar::getPropertyValueEnum' => ['int', 'property'=>'int', 'name'=>'string'], -'IntlChar::getPropertyValueName' => ['string|false', 'prop'=>'int', 'value'=>'int', 'namechoice='=>'int'], +'IntlChar::getPropertyValueName' => ['string|false', 'property'=>'int', 'value'=>'int', 'type='=>'int'], 'IntlChar::getUnicodeVersion' => ['array'], -'IntlChar::hasBinaryProperty' => ['bool', 'char'=>'int|string', 'property'=>'int'], -'IntlChar::isalnum' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isalpha' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isbase' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isblank' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::iscntrl' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isdefined' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isdigit' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isgraph' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isIDIgnorable' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isIDPart' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isIDStart' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isISOControl' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isJavaIDPart' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isJavaIDStart' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isJavaSpaceChar' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::islower' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isMirrored' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isprint' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::ispunct' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isspace' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::istitle' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isUAlphabetic' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isULowercase' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isupper' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isUUppercase' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isUWhiteSpace' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isWhitespace' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::isxdigit' => ['bool', 'codepoint'=>'mixed'], -'IntlChar::ord' => ['int', 'character'=>'mixed'], -'IntlChar::tolower' => ['mixed', 'codepoint'=>'mixed'], -'IntlChar::totitle' => ['mixed', 'codepoint'=>'mixed'], -'IntlChar::toupper' => ['mixed', 'codepoint'=>'mixed'], +'IntlChar::hasBinaryProperty' => ['?bool', 'codepoint'=>'int|string', 'property'=>'int'], +'IntlChar::isalnum' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isalpha' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isbase' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isblank' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::iscntrl' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isdefined' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isdigit' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isgraph' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isIDIgnorable' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isIDPart' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isIDStart' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isISOControl' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isJavaIDPart' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isJavaIDStart' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isJavaSpaceChar' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::islower' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isMirrored' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isprint' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::ispunct' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isspace' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::istitle' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isUAlphabetic' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isULowercase' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isupper' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isUUppercase' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isUWhiteSpace' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isWhitespace' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::isxdigit' => ['?bool', 'codepoint'=>'int|string'], +'IntlChar::ord' => ['?int', 'character'=>'int|string'], +'IntlChar::tolower' => ['int|string|null', 'codepoint'=>'int|string'], +'IntlChar::totitle' => ['int|string|null', 'codepoint'=>'int|string'], +'IntlChar::toupper' => ['int|string|null', 'codepoint'=>'int|string'], 'IntlCodePointBreakIterator::__construct' => ['void'], 'IntlCodePointBreakIterator::createCharacterInstance' => ['?IntlRuleBasedBreakIterator', 'locale='=>'?string'], 'IntlCodePointBreakIterator::createCodePointInstance' => ['IntlCodePointBreakIterator'], @@ -5902,17 +5902,17 @@ return [ 'IntlCodePointBreakIterator::createWordInstance' => ['?IntlRuleBasedBreakIterator', 'locale='=>'?string'], 'IntlCodePointBreakIterator::current' => ['int'], 'IntlCodePointBreakIterator::first' => ['int'], -'IntlCodePointBreakIterator::following' => ['int', 'offset'=>'string'], +'IntlCodePointBreakIterator::following' => ['int', 'offset'=>'int'], 'IntlCodePointBreakIterator::getErrorCode' => ['int'], 'IntlCodePointBreakIterator::getErrorMessage' => ['string'], 'IntlCodePointBreakIterator::getLastCodePoint' => ['int'], -'IntlCodePointBreakIterator::getLocale' => ['string', 'locale_type'=>'string'], -'IntlCodePointBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'key_type='=>'string'], +'IntlCodePointBreakIterator::getLocale' => ['string|false', 'type'=>'int'], +'IntlCodePointBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'type='=>'string'], 'IntlCodePointBreakIterator::getText' => ['?string'], -'IntlCodePointBreakIterator::isBoundary' => ['bool', 'offset'=>'string'], +'IntlCodePointBreakIterator::isBoundary' => ['bool', 'offset'=>'int'], 'IntlCodePointBreakIterator::last' => ['int'], -'IntlCodePointBreakIterator::next' => ['int', 'offset='=>'string'], -'IntlCodePointBreakIterator::preceding' => ['int', 'offset'=>'string'], +'IntlCodePointBreakIterator::next' => ['int', 'offset='=>'?int'], +'IntlCodePointBreakIterator::preceding' => ['int', 'offset'=>'int'], 'IntlCodePointBreakIterator::previous' => ['int'], 'IntlCodePointBreakIterator::setText' => ['?bool', 'text'=>'string'], 'IntlDateFormatter::__construct' => ['void', 'locale'=>'?string', 'dateType='=>'int', 'timeType='=>'int', 'timezone='=>'IntlTimeZone|DateTimeZone|string|null', 'calendar='=>'IntlCalendar|int|null', 'pattern='=>'?string'], @@ -5937,7 +5937,7 @@ return [ 'IntlDateFormatter::setPattern' => ['bool', 'pattern'=>'string'], 'IntlDateFormatter::setTimeZone' => ['null|false', 'timezone'=>'IntlTimeZone|DateTimeZone|string|null'], 'IntlException::__clone' => ['void'], -'IntlException::__construct' => ['void'], +'IntlException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable'], 'IntlException::__toString' => ['string'], 'IntlException::__wakeup' => ['void'], 'IntlException::getCode' => ['int'], @@ -5947,19 +5947,19 @@ return [ 'IntlException::getPrevious' => ['?Throwable'], 'IntlException::getTrace' => ['list\',args?:array}>'], 'IntlException::getTraceAsString' => ['string'], -'intlgregcal_create_instance' => ['IntlGregorianCalendar', 'timezoneOrYear='=>'mixed', 'localeOrMonth='=>'string'], +'intlgregcal_create_instance' => ['?IntlGregorianCalendar', 'timezoneOrYear='=>'IntlTimeZone|DateTimeZone|string|null', 'localeOrMonth='=>'string|int|null', 'day='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'], 'intlgregcal_get_gregorian_change' => ['float', 'calendar'=>'IntlGregorianCalendar'], -'intlgregcal_is_leap_year' => ['bool', 'calendar'=>'int'], +'intlgregcal_is_leap_year' => ['bool', 'calendar'=>'IntlGregorianCalendar', 'year'=>'int'], 'intlgregcal_set_gregorian_change' => ['bool', 'calendar'=>'IntlGregorianCalendar', 'timestamp'=>'float'], 'IntlGregorianCalendar::__construct' => ['void'], -'IntlGregorianCalendar::add' => ['bool', 'field'=>'int', 'amount'=>'int'], +'IntlGregorianCalendar::add' => ['bool', 'field'=>'int', 'value'=>'int'], 'IntlGregorianCalendar::after' => ['bool', 'other'=>'IntlCalendar'], 'IntlGregorianCalendar::before' => ['bool', 'other'=>'IntlCalendar'], 'IntlGregorianCalendar::clear' => ['bool', 'field='=>'?int'], -'IntlGregorianCalendar::createInstance' => ['IntlGregorianCalendar', 'timeZone='=>'mixed', 'locale='=>'string'], +'IntlGregorianCalendar::createInstance' => ['?IntlGregorianCalendar', 'timezone='=>'IntlTimeZone|DateTimeZone|string|null', 'locale='=>'?string'], 'IntlGregorianCalendar::equals' => ['bool', 'other'=>'IntlCalendar'], -'IntlGregorianCalendar::fieldDifference' => ['int', 'when'=>'float', 'field'=>'int'], -'IntlGregorianCalendar::fromDateTime' => ['IntlCalendar', 'dateTime'=>'DateTime|string'], +'IntlGregorianCalendar::fieldDifference' => ['int|false', 'timestamp'=>'float', 'field'=>'int'], +'IntlGregorianCalendar::fromDateTime' => ['?IntlCalendar', 'datetime'=>'DateTime|string', 'locale='=>'?string'], 'IntlGregorianCalendar::get' => ['int', 'field'=>'int'], 'IntlGregorianCalendar::getActualMaximum' => ['int', 'field'=>'int'], 'IntlGregorianCalendar::getActualMinimum' => ['int', 'field'=>'int'], @@ -5970,9 +5970,9 @@ return [ 'IntlGregorianCalendar::getFirstDayOfWeek' => ['int'], 'IntlGregorianCalendar::getGreatestMinimum' => ['int', 'field'=>'int'], 'IntlGregorianCalendar::getGregorianChange' => ['float'], -'IntlGregorianCalendar::getKeywordValuesForLocale' => ['Iterator', 'key'=>'string', 'locale'=>'string', 'commonlyUsed'=>'bool'], +'IntlGregorianCalendar::getKeywordValuesForLocale' => ['IntlIterator|false', 'keyword'=>'string', 'locale'=>'string', 'onlyCommon'=>'bool'], 'IntlGregorianCalendar::getLeastMaximum' => ['int', 'field'=>'int'], -'IntlGregorianCalendar::getLocale' => ['string', 'localeType'=>'int'], +'IntlGregorianCalendar::getLocale' => ['string|false', 'type'=>'int'], 'IntlGregorianCalendar::getMaximum' => ['int', 'field'=>'int'], 'IntlGregorianCalendar::getMinimalDaysInFirstWeek' => ['int'], 'IntlGregorianCalendar::getMinimum' => ['int', 'field'=>'int'], @@ -5982,24 +5982,24 @@ return [ 'IntlGregorianCalendar::getTime' => ['float'], 'IntlGregorianCalendar::getTimeZone' => ['IntlTimeZone'], 'IntlGregorianCalendar::getType' => ['string'], -'IntlGregorianCalendar::getWeekendTransition' => ['int', 'dayOfWeek'=>'string'], +'IntlGregorianCalendar::getWeekendTransition' => ['int|false', 'dayOfWeek'=>'int'], 'IntlGregorianCalendar::inDaylightTime' => ['bool'], 'IntlGregorianCalendar::isEquivalentTo' => ['bool', 'other'=>'IntlCalendar'], 'IntlGregorianCalendar::isLeapYear' => ['bool', 'year'=>'int'], 'IntlGregorianCalendar::isLenient' => ['bool'], 'IntlGregorianCalendar::isSet' => ['bool', 'field'=>'int'], -'IntlGregorianCalendar::isWeekend' => ['bool', 'date='=>'float'], -'IntlGregorianCalendar::roll' => ['bool', 'field'=>'int', 'amountOrUpOrDown'=>'mixed'], +'IntlGregorianCalendar::isWeekend' => ['bool', 'timestamp='=>'?float'], +'IntlGregorianCalendar::roll' => ['bool', 'field'=>'int', 'value'=>'int|bool'], 'IntlGregorianCalendar::set' => ['bool', 'field'=>'int', 'value'=>'int'], 'IntlGregorianCalendar::set\'1' => ['bool', 'year'=>'int', 'month'=>'int', 'dayOfMonth='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'], 'IntlGregorianCalendar::setFirstDayOfWeek' => ['bool', 'dayOfWeek'=>'int'], -'IntlGregorianCalendar::setGregorianChange' => ['bool', 'date'=>'float'], -'IntlGregorianCalendar::setLenient' => ['bool', 'isLenient'=>'string'], -'IntlGregorianCalendar::setMinimalDaysInFirstWeek' => ['bool', 'minimalDays'=>'int'], -'IntlGregorianCalendar::setRepeatedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'], -'IntlGregorianCalendar::setSkippedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'], -'IntlGregorianCalendar::setTime' => ['bool', 'date'=>'float'], -'IntlGregorianCalendar::setTimeZone' => ['bool', 'timeZone'=>'mixed'], +'IntlGregorianCalendar::setGregorianChange' => ['bool', 'timestamp'=>'float'], +'IntlGregorianCalendar::setLenient' => ['true', 'lenient'=>'bool'], +'IntlGregorianCalendar::setMinimalDaysInFirstWeek' => ['bool', 'days'=>'int'], +'IntlGregorianCalendar::setRepeatedWallTimeOption' => ['true', 'option'=>'int'], +'IntlGregorianCalendar::setSkippedWallTimeOption' => ['true', 'option'=>'int'], +'IntlGregorianCalendar::setTime' => ['bool', 'timestamp'=>'float'], +'IntlGregorianCalendar::setTimeZone' => ['bool', 'timezone'=>'IntlTimeZone|DateTimeZone|string|null'], 'IntlGregorianCalendar::toDateTime' => ['DateTime'], 'IntlIterator::__construct' => ['void'], 'IntlIterator::current' => ['mixed'], @@ -6008,7 +6008,7 @@ return [ 'IntlIterator::rewind' => ['void'], 'IntlIterator::valid' => ['bool'], 'IntlPartsIterator::getBreakIterator' => ['IntlBreakIterator'], -'IntlRuleBasedBreakIterator::__construct' => ['void', 'rules'=>'string', 'areCompiled='=>'string'], +'IntlRuleBasedBreakIterator::__construct' => ['void', 'rules'=>'string', 'compiled='=>'bool'], 'IntlRuleBasedBreakIterator::createCharacterInstance' => ['?IntlRuleBasedBreakIterator', 'locale='=>'?string'], 'IntlRuleBasedBreakIterator::createCodePointInstance' => ['IntlCodePointBreakIterator'], 'IntlRuleBasedBreakIterator::createLineInstance' => ['?IntlRuleBasedBreakIterator', 'locale='=>'?string'], @@ -6021,8 +6021,8 @@ return [ 'IntlRuleBasedBreakIterator::getBinaryRules' => ['string'], 'IntlRuleBasedBreakIterator::getErrorCode' => ['int'], 'IntlRuleBasedBreakIterator::getErrorMessage' => ['string'], -'IntlRuleBasedBreakIterator::getLocale' => ['string', 'locale_type'=>'string'], -'IntlRuleBasedBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'key_type='=>'int'], +'IntlRuleBasedBreakIterator::getLocale' => ['string|false', 'type'=>'int'], +'IntlRuleBasedBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'type='=>'string'], 'IntlRuleBasedBreakIterator::getRules' => ['string'], 'IntlRuleBasedBreakIterator::getRuleStatus' => ['int'], 'IntlRuleBasedBreakIterator::getRuleStatusVec' => ['array'], @@ -6033,36 +6033,36 @@ return [ 'IntlRuleBasedBreakIterator::preceding' => ['int', 'offset'=>'int'], 'IntlRuleBasedBreakIterator::previous' => ['int'], 'IntlRuleBasedBreakIterator::setText' => ['?bool', 'text'=>'string'], -'IntlTimeZone::countEquivalentIDs' => ['int|false', 'zoneId'=>'string'], +'IntlTimeZone::countEquivalentIDs' => ['int|false', 'timezoneId'=>'string'], 'IntlTimeZone::createDefault' => ['IntlTimeZone'], -'IntlTimeZone::createEnumeration' => ['IntlIterator|false', 'countryOrRawOffset='=>'mixed'], -'IntlTimeZone::createTimeZone' => ['IntlTimeZone|false', 'zoneId'=>'string'], -'IntlTimeZone::createTimeZoneIDEnumeration' => ['IntlIterator|false', 'zoneType'=>'int', 'region='=>'string', 'rawOffset='=>'int'], -'IntlTimeZone::fromDateTimeZone' => ['?IntlTimeZone', 'zoneId'=>'DateTimeZone'], -'IntlTimeZone::getCanonicalID' => ['string|false', 'zoneId'=>'string', '&w_isSystemID='=>'bool'], -'IntlTimeZone::getDisplayName' => ['string|false', 'isDaylight='=>'bool', 'style='=>'int', 'locale='=>'string'], +'IntlTimeZone::createEnumeration' => ['IntlIterator|false', 'countryOrRawOffset='=>'IntlTimeZone|string|int|float|null'], +'IntlTimeZone::createTimeZone' => ['?IntlTimeZone', 'timezoneId'=>'string'], +'IntlTimeZone::createTimeZoneIDEnumeration' => ['IntlIterator|false', 'type'=>'int', 'region='=>'?string', 'rawOffset='=>'?int'], +'IntlTimeZone::fromDateTimeZone' => ['?IntlTimeZone', 'timezone'=>'DateTimeZone'], +'IntlTimeZone::getCanonicalID' => ['string|false', 'timezoneId'=>'string', '&w_isSystemId='=>'bool'], +'IntlTimeZone::getDisplayName' => ['string|false', 'dst='=>'bool', 'style='=>'int', 'locale='=>'?string'], 'IntlTimeZone::getDSTSavings' => ['int'], -'IntlTimeZone::getEquivalentID' => ['string|false', 'zoneId'=>'string', 'index'=>'int'], +'IntlTimeZone::getEquivalentID' => ['string|false', 'timezoneId'=>'string', 'offset'=>'int'], 'IntlTimeZone::getErrorCode' => ['int'], 'IntlTimeZone::getErrorMessage' => ['string'], 'IntlTimeZone::getGMT' => ['IntlTimeZone'], 'IntlTimeZone::getID' => ['string'], -'IntlTimeZone::getIDForWindowsID' => ['string', 'timezone'=>'string', 'region='=>'string'], -'IntlTimeZone::getOffset' => ['int', 'date'=>'float', 'local'=>'bool', '&w_rawOffset'=>'int', '&w_dstOffset'=>'int'], +'IntlTimeZone::getIDForWindowsID' => ['string|false', 'timezoneId'=>'string', 'region='=>'?string'], +'IntlTimeZone::getOffset' => ['bool', 'timestamp'=>'float', 'local'=>'bool', '&w_rawOffset'=>'int', '&w_dstOffset'=>'int'], 'IntlTimeZone::getRawOffset' => ['int'], -'IntlTimeZone::getRegion' => ['string|false', 'zoneId'=>'string'], +'IntlTimeZone::getRegion' => ['string|false', 'timezoneId'=>'string'], 'IntlTimeZone::getTZDataVersion' => ['string'], 'IntlTimeZone::getUnknown' => ['IntlTimeZone'], -'IntlTimeZone::getWindowsID' => ['string|false', 'timezone'=>'string'], -'IntlTimeZone::hasSameRules' => ['bool', 'otherTimeZone'=>'IntlTimeZone'], +'IntlTimeZone::getWindowsID' => ['string|false', 'timezoneId'=>'string'], +'IntlTimeZone::hasSameRules' => ['bool', 'other'=>'IntlTimeZone'], 'IntlTimeZone::toDateTimeZone' => ['DateTimeZone|false'], 'IntlTimeZone::useDaylightTime' => ['bool'], 'intltz_count_equivalent_ids' => ['int', 'timezoneId'=>'string'], -'intltz_create_enumeration' => ['IntlIterator', 'countryOrRawOffset'=>'mixed'], +'intltz_create_enumeration' => ['IntlIterator|false', 'countryOrRawOffset='=>'IntlTimeZone|string|int|float|null'], 'intltz_create_time_zone' => ['?IntlTimeZone', 'timezoneId'=>'string'], 'intltz_from_date_time_zone' => ['?IntlTimeZone', 'timezone'=>'DateTimeZone'], -'intltz_get_canonical_id' => ['string', 'timezoneId'=>'string', '&isSystemId'=>'bool'], -'intltz_get_display_name' => ['string', 'timezone'=>'IntlTimeZone', 'dst'=>'bool', 'style'=>'int', 'locale'=>'string'], +'intltz_get_canonical_id' => ['string|false', 'timezoneId'=>'string', '&isSystemId='=>'bool'], +'intltz_get_display_name' => ['string|false', 'timezone'=>'IntlTimeZone', 'dst='=>'bool', 'style='=>'int', 'locale='=>'?string'], 'intltz_get_dst_savings' => ['int', 'timezone'=>'IntlTimeZone'], 'intltz_get_equivalent_id' => ['string', 'timezoneId'=>'string', 'offset'=>'int'], 'intltz_get_error_code' => ['int', 'timezone'=>'IntlTimeZone'], @@ -6162,6 +6162,7 @@ return [ 'json_encode' => ['non-empty-string|false', 'value'=>'mixed', 'flags='=>'int', 'depth='=>'int'], 'json_last_error' => ['int'], 'json_last_error_msg' => ['string'], +'json_validate' => ['bool', 'json'=>'string', 'depth='=>'positive-int', 'flags='=>'int'], 'JsonException::__clone' => ['void'], 'JsonException::__construct' => ['void'], 'JsonException::__toString' => ['string'], @@ -7888,7 +7889,7 @@ return [ 'mysqli_fetch_field_direct' => ['object|false', 'result'=>'mysqli_result', 'index'=>'int'], 'mysqli_fetch_fields' => ['stdClass[]', 'result'=>'mysqli_result'], 'mysqli_fetch_lengths' => ['array|false', 'result'=>'mysqli_result'], -'mysqli_fetch_object' => ['object|false|null', 'result'=>'mysqli_result', 'class='=>'class-string', 'constructor_args='=>'array'], +'mysqli_fetch_object' => ['object|false|null', 'result'=>'mysqli_result', 'class='=>'string', 'constructor_args='=>'array'], 'mysqli_fetch_row' => ['list|false|null', 'result'=>'mysqli_result'], 'mysqli_field_count' => ['int', 'mysql'=>'mysqli'], 'mysqli_field_seek' => ['bool', 'result'=>'mysqli_result', 'index'=>'int'], @@ -7943,7 +7944,7 @@ return [ 'mysqli_result::fetch_field' => ['object|false'], 'mysqli_result::fetch_field_direct' => ['object|false', 'index'=>'int'], 'mysqli_result::fetch_fields' => ['stdClass[]'], -'mysqli_result::fetch_object' => ['object|false|null', 'class='=>'class-string', 'constructor_args='=>'array'], +'mysqli_result::fetch_object' => ['object|false|null', 'class='=>'string', 'constructor_args='=>'array'], 'mysqli_result::fetch_row' => ['list|false|null'], 'mysqli_result::field_seek' => ['bool', 'index'=>'int'], 'mysqli_result::free' => ['void'], @@ -9051,7 +9052,7 @@ return [ 'PDOStatement::fetch' => ['mixed', 'mode='=>'int', 'cursorOrientation='=>'int', 'cursorOffset='=>'int'], 'PDOStatement::fetchAll' => ['array', 'mode='=>'int', '...args='=>'mixed'], 'PDOStatement::fetchColumn' => ['mixed', 'column='=>'int'], -'PDOStatement::fetchObject' => ['object|false', 'class='=>'?string', 'constructorArgs='=>'array'], +'PDOStatement::fetchObject' => ['object|false', 'class='=>'?class-string', 'constructorArgs='=>'array'], 'PDOStatement::getAttribute' => ['mixed', 'name'=>'int'], 'PDOStatement::getColumnMeta' => ['array|false', 'column'=>'int'], 'PDOStatement::nextRowset' => ['bool'], @@ -9169,29 +9170,27 @@ return [ 'pg_untrace' => ['bool', 'connection='=>'?\PgSql\Connection'], 'pg_update' => ['string|bool', 'connection'=>'\PgSql\Connection', 'table_name'=>'string', 'values'=>'array', 'conditions'=>'array', 'flags='=>'int'], 'pg_version' => ['array', 'connection='=>'?\PgSql\Connection'], -'Phar::__construct' => ['void', 'fname'=>'string', 'flags='=>'int', 'alias='=>'string'], -'Phar::addEmptyDir' => ['void', 'dirname'=>'string'], -'Phar::addFile' => ['void', 'file'=>'string', 'localname='=>'string'], -'Phar::addFromString' => ['void', 'localname'=>'string', 'contents'=>'string'], +'Phar::__construct' => ['void', 'filename'=>'string', 'flags='=>'int', 'alias='=>'?string'], +'Phar::addEmptyDir' => ['void', 'directory'=>'string'], +'Phar::addFile' => ['void', 'filename'=>'string', 'localName='=>'?string'], +'Phar::addFromString' => ['void', 'localName'=>'string', 'contents'=>'string'], 'Phar::apiVersion' => ['string'], -'Phar::buildFromDirectory' => ['array', 'base_dir'=>'string', 'regex='=>'string'], -'Phar::buildFromIterator' => ['array', 'iter'=>'Iterator', 'base_directory='=>'string'], -'Phar::canCompress' => ['bool', 'method='=>'int'], +'Phar::buildFromDirectory' => ['array', 'directory'=>'string', 'pattern='=>'string'], +'Phar::buildFromIterator' => ['array', 'iterator'=>'Traversable', 'baseDirectory='=>'?string'], +'Phar::canCompress' => ['bool', 'compression='=>'int'], 'Phar::canWrite' => ['bool'], 'Phar::compress' => ['?Phar', 'compression'=>'int', 'extension='=>'?string'], -'Phar::compressAllFilesBZIP2' => ['bool'], -'Phar::compressAllFilesGZ' => ['bool'], 'Phar::compressFiles' => ['void', 'compression'=>'int'], 'Phar::convertToData' => ['?PharData', 'format='=>'?int', 'compression='=>'?int', 'extension='=>'?string'], 'Phar::convertToExecutable' => ['?Phar', 'format='=>'?int', 'compression='=>'?int', 'extension='=>'?string'], -'Phar::copy' => ['bool', 'oldfile'=>'string', 'newfile'=>'string'], -'Phar::count' => ['int'], -'Phar::createDefaultStub' => ['string', 'indexfile='=>'string', 'webindexfile='=>'string'], +'Phar::copy' => ['bool', 'from'=>'string', 'to'=>'string'], +'Phar::count' => ['int', 'mode='=>'int'], +'Phar::createDefaultStub' => ['string', 'index='=>'?string', 'webIndex='=>'?string'], 'Phar::decompress' => ['?Phar', 'extension='=>'?string'], 'Phar::decompressFiles' => ['bool'], -'Phar::delete' => ['bool', 'entry'=>'string'], +'Phar::delete' => ['bool', 'localName'=>'string'], 'Phar::delMetadata' => ['bool'], -'Phar::extractTo' => ['bool', 'pathto'=>'string', 'files='=>'string|array|null', 'overwrite='=>'bool'], +'Phar::extractTo' => ['bool', 'directory'=>'string', 'files='=>'string|array|null', 'overwrite='=>'bool'], 'Phar::getAlias' => ['?string'], 'Phar::getMetadata' => ['mixed', 'unserializeOptions='=>'array'], 'Phar::getModified' => ['bool'], @@ -9209,52 +9208,51 @@ return [ 'Phar::isValidPharFilename' => ['bool', 'filename'=>'string', 'executable='=>'bool'], 'Phar::isWritable' => ['bool'], 'Phar::loadPhar' => ['bool', 'filename'=>'string', 'alias='=>'?string'], -'Phar::mapPhar' => ['bool', 'alias='=>'string', 'dataoffset='=>'int'], -'Phar::mount' => ['void', 'pharpath'=>'string', 'externalpath'=>'string'], -'Phar::mungServer' => ['void', 'munglist'=>'array'], -'Phar::offsetExists' => ['bool', 'offset'=>'string'], -'Phar::offsetGet' => ['PharFileInfo', 'offset'=>'string'], -'Phar::offsetSet' => ['void', 'offset'=>'string', 'value'=>'string'], -'Phar::offsetUnset' => ['bool', 'offset'=>'string'], -'Phar::running' => ['string', 'retphar='=>'bool'], +'Phar::mapPhar' => ['bool', 'alias='=>'?string', 'offset='=>'int'], +'Phar::mount' => ['void', 'pharPath'=>'string', 'externalPath'=>'string'], +'Phar::mungServer' => ['void', 'variables'=>'list'], +'Phar::offsetExists' => ['bool', 'localName'=>'string'], +'Phar::offsetGet' => ['PharFileInfo', 'localName'=>'string'], +'Phar::offsetSet' => ['void', 'localName'=>'string', 'value'=>'resource|string'], +'Phar::offsetUnset' => ['void', 'localName'=>'string'], +'Phar::running' => ['string', 'returnPhar='=>'bool'], 'Phar::setAlias' => ['bool', 'alias'=>'string'], -'Phar::setDefaultStub' => ['bool', 'index='=>'string', 'webindex='=>'string'], +'Phar::setDefaultStub' => ['bool', 'index='=>'?string', 'webIndex='=>'?string'], 'Phar::setMetadata' => ['void', 'metadata'=>''], -'Phar::setSignatureAlgorithm' => ['void', 'sigtype'=>'int', 'privatekey='=>'string'], +'Phar::setSignatureAlgorithm' => ['void', 'algo'=>'int', 'privateKey='=>'?string'], 'Phar::setStub' => ['bool', 'stub'=>'string', 'length='=>'int'], 'Phar::startBuffering' => ['void'], 'Phar::stopBuffering' => ['void'], -'Phar::uncompressAllFiles' => ['bool'], -'Phar::unlinkArchive' => ['bool', 'archive'=>'string'], -'Phar::webPhar' => ['', 'alias='=>'string', 'index='=>'string', 'f404='=>'string', 'mimetypes='=>'array', 'rewrites='=>'array'], -'PharData::__construct' => ['void', 'fname'=>'string', 'flags='=>'?int', 'alias='=>'?string', 'format='=>'int'], -'PharData::addEmptyDir' => ['bool', 'dirname'=>'string'], -'PharData::addFile' => ['void', 'file'=>'string', 'localname='=>'string'], -'PharData::addFromString' => ['bool', 'localname'=>'string', 'contents'=>'string'], -'PharData::buildFromDirectory' => ['array', 'base_dir'=>'string', 'regex='=>'string'], -'PharData::buildFromIterator' => ['array', 'iter'=>'Iterator', 'base_directory='=>'string'], +'Phar::unlinkArchive' => ['bool', 'filename'=>'string'], +'Phar::webPhar' => ['void', 'alias='=>'?string', 'index='=>'?string', 'fileNotFoundScript='=>'?string', 'mimeTypes='=>'array', 'rewrite='=>'?callable'], +'PharData::__construct' => ['void', 'filename'=>'string', 'flags='=>'int', 'alias='=>'?string', 'format='=>'int'], +'PharData::addEmptyDir' => ['void', 'directory'=>'string'], +'PharData::addFile' => ['void', 'filename'=>'string', 'localName='=>'?string'], +'PharData::addFromString' => ['void', 'localName'=>'string', 'contents'=>'string'], +'PharData::buildFromDirectory' => ['array', 'directory'=>'string', 'pattern='=>'string'], +'PharData::buildFromIterator' => ['array', 'iterator'=>'Traversable', 'baseDirectory='=>'?string'], 'PharData::compress' => ['?PharData', 'compression'=>'int', 'extension='=>'?string'], 'PharData::compressFiles' => ['void', 'compression'=>'int'], 'PharData::convertToData' => ['?PharData', 'format='=>'?int', 'compression='=>'?int', 'extension='=>'?string'], 'PharData::convertToExecutable' => ['?Phar', 'format='=>'?int', 'compression='=>'?int', 'extension='=>'?string'], -'PharData::copy' => ['bool', 'oldfile'=>'string', 'newfile'=>'string'], +'PharData::copy' => ['bool', 'from'=>'string', 'to'=>'string'], 'PharData::decompress' => ['?PharData', 'extension='=>'?string'], 'PharData::decompressFiles' => ['bool'], -'PharData::delete' => ['bool', 'entry'=>'string'], +'PharData::delete' => ['bool', 'localName'=>'string'], 'PharData::delMetadata' => ['bool'], -'PharData::extractTo' => ['bool', 'pathto'=>'string', 'files='=>'string|array|null', 'overwrite='=>'bool'], +'PharData::extractTo' => ['bool', 'directory'=>'string', 'files='=>'string|array|null', 'overwrite='=>'bool'], 'PharData::isWritable' => ['bool'], -'PharData::offsetExists' => ['bool', 'offset'=>'string'], -'PharData::offsetGet' => ['PharFileInfo', 'offset'=>'string'], -'PharData::offsetSet' => ['void', 'offset'=>'string', 'value'=>'string'], -'PharData::offsetUnset' => ['bool', 'offset'=>'string'], +'PharData::offsetExists' => ['bool', 'localName'=>'string'], +'PharData::offsetGet' => ['PharFileInfo', 'localName'=>'string'], +'PharData::offsetSet' => ['void', 'localName'=>'string', 'value'=>'string'], +'PharData::offsetUnset' => ['void', 'localName'=>'string'], 'PharData::setAlias' => ['bool', 'alias'=>'string'], -'PharData::setDefaultStub' => ['bool', 'index='=>'string', 'webindex='=>'string'], -'phardata::setMetadata' => ['void', 'metadata'=>'mixed'], -'phardata::setSignatureAlgorithm' => ['void', 'sigtype'=>'int'], +'PharData::setDefaultStub' => ['bool', 'index='=>'?string', 'webIndex='=>'?string'], +'PharData::setMetadata' => ['void', 'metadata'=>'mixed'], +'PharData::setSignatureAlgorithm' => ['void', 'algo'=>'int', 'privateKey='=>'?string'], 'PharData::setStub' => ['bool', 'stub'=>'string', 'length='=>'int'], -'PharFileInfo::__construct' => ['void', 'entry'=>'string'], -'PharFileInfo::chmod' => ['void', 'permissions'=>'int'], +'PharFileInfo::__construct' => ['void', 'filename'=>'string'], +'PharFileInfo::chmod' => ['void', 'perms'=>'int'], 'PharFileInfo::compress' => ['bool', 'compression'=>'int'], 'PharFileInfo::decompress' => ['bool'], 'PharFileInfo::delMetadata' => ['bool'], @@ -9264,14 +9262,9 @@ return [ 'PharFileInfo::getMetadata' => ['mixed', 'unserializeOptions='=>'array'], 'PharFileInfo::getPharFlags' => ['int'], 'PharFileInfo::hasMetadata' => ['bool'], -'PharFileInfo::isCompressed' => ['bool', 'compression_type='=>'int'], -'PharFileInfo::isCompressedBZIP2' => ['bool'], -'PharFileInfo::isCompressedGZ' => ['bool'], +'PharFileInfo::isCompressed' => ['bool', 'compression='=>'?int'], 'PharFileInfo::isCRCChecked' => ['bool'], -'PharFileInfo::setCompressedBZIP2' => ['bool'], -'PharFileInfo::setCompressedGZ' => ['bool'], 'PharFileInfo::setMetadata' => ['void', 'metadata'=>'mixed'], -'PharFileInfo::setUncompressed' => ['bool'], 'phdfs::__construct' => ['void', 'ip'=>'string', 'port'=>'string'], 'phdfs::__destruct' => ['void'], 'phdfs::connect' => ['bool'], @@ -9824,7 +9817,7 @@ return [ 'rectObj::setextent' => ['void', 'minx'=>'float', 'miny'=>'float', 'maxx'=>'float', 'maxy'=>'float'], 'RecursiveArrayIterator::__construct' => ['void', 'array='=>'array|object', 'flags='=>'int'], 'RecursiveArrayIterator::append' => ['void', 'value'=>'mixed'], -'RecursiveArrayIterator::asort' => ['void'], +'RecursiveArrayIterator::asort' => ['true', 'flags='=>'int'], 'RecursiveArrayIterator::count' => ['int'], 'RecursiveArrayIterator::current' => ['mixed'], 'RecursiveArrayIterator::getArrayCopy' => ['array'], @@ -9832,23 +9825,23 @@ return [ 'RecursiveArrayIterator::getFlags' => ['int'], 'RecursiveArrayIterator::hasChildren' => ['bool'], 'RecursiveArrayIterator::key' => ['string|int|null'], -'RecursiveArrayIterator::ksort' => ['void'], +'RecursiveArrayIterator::ksort' => ['true', 'flags='=>'int'], 'RecursiveArrayIterator::natcasesort' => ['true'], 'RecursiveArrayIterator::natsort' => ['true'], 'RecursiveArrayIterator::next' => ['void'], -'RecursiveArrayIterator::offsetExists' => ['void', 'index'=>'string'], -'RecursiveArrayIterator::offsetGet' => ['mixed', 'index'=>'string'], -'RecursiveArrayIterator::offsetSet' => ['void', 'index'=>'string', 'newval'=>'string'], -'RecursiveArrayIterator::offsetUnset' => ['void', 'index'=>'string'], +'RecursiveArrayIterator::offsetExists' => ['bool', 'key'=>'string|int'], +'RecursiveArrayIterator::offsetGet' => ['mixed', 'key'=>'string|int'], +'RecursiveArrayIterator::offsetSet' => ['void', 'key'=>'string|int', 'value'=>'string'], +'RecursiveArrayIterator::offsetUnset' => ['void', 'key'=>'string|int'], 'RecursiveArrayIterator::rewind' => ['void'], -'RecursiveArrayIterator::seek' => ['void', 'position'=>'int'], +'RecursiveArrayIterator::seek' => ['void', 'offset'=>'int'], 'RecursiveArrayIterator::serialize' => ['string'], -'RecursiveArrayIterator::setFlags' => ['void', 'flags'=>'string'], -'RecursiveArrayIterator::uasort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], -'RecursiveArrayIterator::uksort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], -'RecursiveArrayIterator::unserialize' => ['string', 'serialized'=>'string'], +'RecursiveArrayIterator::setFlags' => ['void', 'flags'=>'int'], +'RecursiveArrayIterator::uasort' => ['true', 'callback'=>'callable(mixed,mixed):int'], +'RecursiveArrayIterator::uksort' => ['true', 'callback'=>'callable(mixed,mixed):int'], +'RecursiveArrayIterator::unserialize' => ['void', 'data'=>'string'], 'RecursiveArrayIterator::valid' => ['bool'], -'RecursiveCachingIterator::__construct' => ['void', 'it'=>'Iterator', 'flags='=>'int'], +'RecursiveCachingIterator::__construct' => ['void', 'iterator'=>'Iterator', 'flags='=>'int'], 'RecursiveCachingIterator::__toString' => ['string'], 'RecursiveCachingIterator::count' => ['int'], 'RecursiveCachingIterator::current' => ['void'], @@ -9860,14 +9853,14 @@ return [ 'RecursiveCachingIterator::hasNext' => ['bool'], 'RecursiveCachingIterator::key' => ['bool|float|int|string'], 'RecursiveCachingIterator::next' => ['void'], -'RecursiveCachingIterator::offsetExists' => ['bool', 'index'=>'string'], -'RecursiveCachingIterator::offsetGet' => ['string', 'index'=>'string'], -'RecursiveCachingIterator::offsetSet' => ['void', 'index'=>'string', 'newval'=>'string'], -'RecursiveCachingIterator::offsetUnset' => ['void', 'index'=>'string'], +'RecursiveCachingIterator::offsetExists' => ['bool', 'key'=>'string'], +'RecursiveCachingIterator::offsetGet' => ['string', 'key'=>'string'], +'RecursiveCachingIterator::offsetSet' => ['void', 'key'=>'string', 'value'=>'string'], +'RecursiveCachingIterator::offsetUnset' => ['void', 'key'=>'string'], 'RecursiveCachingIterator::rewind' => ['void'], 'RecursiveCachingIterator::setFlags' => ['void', 'flags'=>'int'], 'RecursiveCachingIterator::valid' => ['bool'], -'RecursiveCallbackFilterIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator', 'func'=>'callable'], +'RecursiveCallbackFilterIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator', 'callback'=>'callable(mixed,mixed=,mixed=):bool'], 'RecursiveCallbackFilterIterator::accept' => ['bool'], 'RecursiveCallbackFilterIterator::current' => ['mixed'], 'RecursiveCallbackFilterIterator::getChildren' => ['RecursiveCallbackFilterIterator'], @@ -9877,7 +9870,7 @@ return [ 'RecursiveCallbackFilterIterator::next' => ['void'], 'RecursiveCallbackFilterIterator::rewind' => ['void'], 'RecursiveCallbackFilterIterator::valid' => ['bool'], -'RecursiveDirectoryIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'], +'RecursiveDirectoryIterator::__construct' => ['void', 'directory'=>'string', 'flags='=>'int'], 'RecursiveDirectoryIterator::__toString' => ['string'], 'RecursiveDirectoryIterator::current' => ['string|SplFileInfo|FilesystemIterator'], 'RecursiveDirectoryIterator::getATime' => ['int'], @@ -9885,7 +9878,7 @@ return [ 'RecursiveDirectoryIterator::getChildren' => ['RecursiveDirectoryIterator'], 'RecursiveDirectoryIterator::getCTime' => ['int'], 'RecursiveDirectoryIterator::getExtension' => ['string'], -'RecursiveDirectoryIterator::getFileInfo' => ['SplFileInfo', 'class_name='=>'string'], +'RecursiveDirectoryIterator::getFileInfo' => ['SplFileInfo', 'class='=>'?class-string'], 'RecursiveDirectoryIterator::getFilename' => ['string'], 'RecursiveDirectoryIterator::getFlags' => ['int'], 'RecursiveDirectoryIterator::getGroup' => ['int'], @@ -9894,7 +9887,7 @@ return [ 'RecursiveDirectoryIterator::getMTime' => ['int'], 'RecursiveDirectoryIterator::getOwner' => ['int'], 'RecursiveDirectoryIterator::getPath' => ['string'], -'RecursiveDirectoryIterator::getPathInfo' => ['SplFileInfo', 'class_name='=>'string'], +'RecursiveDirectoryIterator::getPathInfo' => ['?SplFileInfo', 'class='=>'?class-string'], 'RecursiveDirectoryIterator::getPathname' => ['string'], 'RecursiveDirectoryIterator::getPerms' => ['int'], 'RecursiveDirectoryIterator::getRealPath' => ['string'], @@ -9902,7 +9895,7 @@ return [ 'RecursiveDirectoryIterator::getSubPath' => ['string'], 'RecursiveDirectoryIterator::getSubPathname' => ['string'], 'RecursiveDirectoryIterator::getType' => ['string'], -'RecursiveDirectoryIterator::hasChildren' => ['bool', 'allow_links='=>'bool'], +'RecursiveDirectoryIterator::hasChildren' => ['bool', 'allowLinks='=>'bool'], 'RecursiveDirectoryIterator::isDir' => ['bool'], 'RecursiveDirectoryIterator::isDot' => ['bool'], 'RecursiveDirectoryIterator::isExecutable' => ['bool'], @@ -9912,12 +9905,12 @@ return [ 'RecursiveDirectoryIterator::isWritable' => ['bool'], 'RecursiveDirectoryIterator::key' => ['string'], 'RecursiveDirectoryIterator::next' => ['void'], -'RecursiveDirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>'resource'], +'RecursiveDirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], 'RecursiveDirectoryIterator::rewind' => ['void'], -'RecursiveDirectoryIterator::seek' => ['void', 'position'=>'int'], -'RecursiveDirectoryIterator::setFileClass' => ['void', 'class_name='=>'string'], -'RecursiveDirectoryIterator::setFlags' => ['void', 'flags='=>'int'], -'RecursiveDirectoryIterator::setInfoClass' => ['void', 'class_name='=>'string'], +'RecursiveDirectoryIterator::seek' => ['void', 'offset'=>'int'], +'RecursiveDirectoryIterator::setFileClass' => ['void', 'class='=>'class-string'], +'RecursiveDirectoryIterator::setFlags' => ['void', 'flags'=>'int'], +'RecursiveDirectoryIterator::setInfoClass' => ['void', 'class='=>'class-string'], 'RecursiveDirectoryIterator::valid' => ['bool'], 'RecursiveFilterIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator'], 'RecursiveFilterIterator::accept' => ['bool'], @@ -9953,9 +9946,9 @@ return [ 'RecursiveIteratorIterator::next' => ['void'], 'RecursiveIteratorIterator::nextElement' => ['void'], 'RecursiveIteratorIterator::rewind' => ['void'], -'RecursiveIteratorIterator::setMaxDepth' => ['void', 'max_depth='=>'int'], +'RecursiveIteratorIterator::setMaxDepth' => ['void', 'maxDepth='=>'int'], 'RecursiveIteratorIterator::valid' => ['bool'], -'RecursiveRegexIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator', 'regex'=>'string', 'mode='=>'int', 'flags='=>'int', 'preg_flags='=>'int'], +'RecursiveRegexIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator', 'pattern'=>'string', 'mode='=>'int', 'flags='=>'int', 'pregFlags='=>'int'], 'RecursiveRegexIterator::accept' => ['bool'], 'RecursiveRegexIterator::current' => ['mixed'], 'RecursiveRegexIterator::getChildren' => ['RecursiveRegexIterator'], @@ -9968,11 +9961,11 @@ return [ 'RecursiveRegexIterator::key' => ['mixed'], 'RecursiveRegexIterator::next' => ['void'], 'RecursiveRegexIterator::rewind' => ['void'], -'RecursiveRegexIterator::setFlags' => ['void', 'new_flags'=>'int'], -'RecursiveRegexIterator::setMode' => ['void', 'new_mode'=>'int'], -'RecursiveRegexIterator::setPregFlags' => ['void', 'new_flags'=>'int'], +'RecursiveRegexIterator::setFlags' => ['void', 'flags'=>'int'], +'RecursiveRegexIterator::setMode' => ['void', 'mode'=>'int'], +'RecursiveRegexIterator::setPregFlags' => ['void', 'pregFlags'=>'int'], 'RecursiveRegexIterator::valid' => ['bool'], -'RecursiveTreeIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator|IteratorAggregate', 'flags='=>'int', 'cit_flags='=>'int', 'mode'=>'int'], +'RecursiveTreeIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator|IteratorAggregate', 'flags='=>'int', 'cachingIteratorFlags='=>'int', 'mode='=>'int'], 'RecursiveTreeIterator::beginChildren' => ['void'], 'RecursiveTreeIterator::beginIteration' => ['void'], 'RecursiveTreeIterator::callGetChildren' => ['?RecursiveIterator'], @@ -9991,9 +9984,9 @@ return [ 'RecursiveTreeIterator::next' => ['void'], 'RecursiveTreeIterator::nextElement' => ['void'], 'RecursiveTreeIterator::rewind' => ['void'], -'RecursiveTreeIterator::setMaxDepth' => ['void', 'max_depth='=>'int'], -'RecursiveTreeIterator::setPostfix' => ['void', 'prefix'=>'string'], -'RecursiveTreeIterator::setPrefixPart' => ['void', 'part'=>'int', 'prefix'=>'string'], +'RecursiveTreeIterator::setMaxDepth' => ['void', 'maxDepth='=>'int'], +'RecursiveTreeIterator::setPostfix' => ['void', 'postfix'=>'string'], +'RecursiveTreeIterator::setPrefixPart' => ['void', 'part'=>'int', 'value'=>'string'], 'RecursiveTreeIterator::valid' => ['bool'], 'Redis::__construct' => ['void'], 'Redis::__destruct' => ['void'], @@ -10762,7 +10755,7 @@ return [ 'ReflectionZendExtension::getVersion' => ['string'], 'Reflector::__toString' => ['string'], 'Reflector::export' => ['?string'], -'RegexIterator::__construct' => ['void', 'iterator'=>'Iterator', 'regex'=>'string', 'mode='=>'int', 'flags='=>'int', 'preg_flags='=>'int'], +'RegexIterator::__construct' => ['void', 'iterator'=>'Iterator', 'pattern'=>'string', 'mode='=>'int', 'flags='=>'int', 'pregFlags='=>'int'], 'RegexIterator::accept' => ['bool'], 'RegexIterator::current' => ['mixed'], 'RegexIterator::getFlags' => ['int'], @@ -10773,9 +10766,9 @@ return [ 'RegexIterator::key' => ['mixed'], 'RegexIterator::next' => ['void'], 'RegexIterator::rewind' => ['void'], -'RegexIterator::setFlags' => ['void', 'new_flags'=>'int'], -'RegexIterator::setMode' => ['void', 'new_mode'=>'int'], -'RegexIterator::setPregFlags' => ['void', 'new_flags'=>'int'], +'RegexIterator::setFlags' => ['void', 'flags'=>'int'], +'RegexIterator::setMode' => ['void', 'mode'=>'int'], +'RegexIterator::setPregFlags' => ['void', 'pregFlags'=>'int'], 'RegexIterator::valid' => ['bool'], 'register_event_handler' => ['bool', 'event_handler_func'=>'string', 'handler_register_name'=>'string', 'event_type_mask'=>'int'], 'register_shutdown_function' => ['void', 'callback'=>'callable', '...args='=>'mixed'], @@ -11334,7 +11327,7 @@ return [ 'SimpleXMLElement::xpath' => ['SimpleXMLElement[]|false', 'path'=>'string'], 'sin' => ['float', 'num'=>'float'], 'sinh' => ['float', 'num'=>'float'], -'sizeof' => ['int', 'value'=>'Countable|array', 'mode='=>'int'], +'sizeof' => ['int<0, max>', 'value'=>'Countable|array', 'mode='=>'int'], 'sleep' => ['int', 'seconds'=>'0|positive-int'], 'snmp2_get' => ['string|false', 'hostname'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'], 'snmp2_getnext' => ['string|false', 'hostname'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'], @@ -12280,7 +12273,7 @@ return [ 'spl_object_hash' => ['string', 'object'=>'object'], 'spl_object_id' => ['int', 'object'=>'object'], 'SplDoublyLinkedList::__construct' => ['void'], -'SplDoublyLinkedList::add' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], +'SplDoublyLinkedList::add' => ['void', 'index'=>'int', 'value'=>'mixed'], 'SplDoublyLinkedList::bottom' => ['mixed'], 'SplDoublyLinkedList::count' => ['int'], 'SplDoublyLinkedList::current' => ['mixed'], @@ -12290,17 +12283,17 @@ return [ 'SplDoublyLinkedList::next' => ['void'], 'SplDoublyLinkedList::offsetExists' => ['bool', 'index'=>'mixed'], 'SplDoublyLinkedList::offsetGet' => ['mixed', 'index'=>'mixed'], -'SplDoublyLinkedList::offsetSet' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], +'SplDoublyLinkedList::offsetSet' => ['void', 'index'=>'mixed', 'value'=>'mixed'], 'SplDoublyLinkedList::offsetUnset' => ['void', 'index'=>'mixed'], 'SplDoublyLinkedList::pop' => ['mixed'], 'SplDoublyLinkedList::prev' => ['void'], 'SplDoublyLinkedList::push' => ['void', 'value'=>'mixed'], 'SplDoublyLinkedList::rewind' => ['void'], 'SplDoublyLinkedList::serialize' => ['string'], -'SplDoublyLinkedList::setIteratorMode' => ['void', 'flags'=>'int'], +'SplDoublyLinkedList::setIteratorMode' => ['int', 'mode'=>'int'], 'SplDoublyLinkedList::shift' => ['mixed'], 'SplDoublyLinkedList::top' => ['mixed'], -'SplDoublyLinkedList::unserialize' => ['void', 'serialized'=>'string'], +'SplDoublyLinkedList::unserialize' => ['void', 'data'=>'string'], 'SplDoublyLinkedList::unshift' => ['void', 'value'=>'mixed'], 'SplDoublyLinkedList::valid' => ['bool'], 'SplEnum::__construct' => ['void', 'initial_value='=>'mixed', 'strict='=>'bool'], @@ -12312,7 +12305,7 @@ return [ 'SplFileInfo::getBasename' => ['string', 'suffix='=>'string'], 'SplFileInfo::getCTime' => ['int|false'], 'SplFileInfo::getExtension' => ['string'], -'SplFileInfo::getFileInfo' => ['SplFileInfo', 'class='=>'?string'], +'SplFileInfo::getFileInfo' => ['SplFileInfo', 'class='=>'?class-string'], 'SplFileInfo::getFilename' => ['string'], 'SplFileInfo::getGroup' => ['int|false'], 'SplFileInfo::getInode' => ['int|false'], @@ -12320,7 +12313,7 @@ return [ 'SplFileInfo::getMTime' => ['int|false'], 'SplFileInfo::getOwner' => ['int|false'], 'SplFileInfo::getPath' => ['string'], -'SplFileInfo::getPathInfo' => ['SplFileInfo|null', 'class='=>'?string'], +'SplFileInfo::getPathInfo' => ['SplFileInfo|null', 'class='=>'?class-string'], 'SplFileInfo::getPathname' => ['string'], 'SplFileInfo::getPerms' => ['int|false'], 'SplFileInfo::getRealPath' => ['string|false'], @@ -12333,8 +12326,8 @@ return [ 'SplFileInfo::isReadable' => ['bool'], 'SplFileInfo::isWritable' => ['bool'], 'SplFileInfo::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], -'SplFileInfo::setFileClass' => ['void', 'class='=>'string'], -'SplFileInfo::setInfoClass' => ['void', 'class='=>'string'], +'SplFileInfo::setFileClass' => ['void', 'class='=>'class-string'], +'SplFileInfo::setInfoClass' => ['void', 'class='=>'class-string'], 'SplFileObject::__construct' => ['void', 'filename'=>'string', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], 'SplFileObject::__toString' => ['string'], 'SplFileObject::current' => ['string|array|false'], @@ -12360,7 +12353,7 @@ return [ 'SplFileObject::getCTime' => ['int|false'], 'SplFileObject::getCurrentLine' => ['string'], 'SplFileObject::getExtension' => ['string'], -'SplFileObject::getFileInfo' => ['SplFileInfo', 'class='=>'?string'], +'SplFileObject::getFileInfo' => ['SplFileInfo', 'class='=>'?class-string'], 'SplFileObject::getFilename' => ['string'], 'SplFileObject::getFlags' => ['int'], 'SplFileObject::getGroup' => ['int|false'], @@ -12370,7 +12363,7 @@ return [ 'SplFileObject::getMTime' => ['int|false'], 'SplFileObject::getOwner' => ['int|false'], 'SplFileObject::getPath' => ['string'], -'SplFileObject::getPathInfo' => ['SplFileInfo|null', 'class='=>'?string'], +'SplFileObject::getPathInfo' => ['SplFileInfo|null', 'class='=>'?class-string'], 'SplFileObject::getPathname' => ['string'], 'SplFileObject::getPerms' => ['int|false'], 'SplFileObject::getRealPath' => ['false|string'], @@ -12389,22 +12382,22 @@ return [ 'SplFileObject::rewind' => ['void'], 'SplFileObject::seek' => ['void', 'line'=>'int'], 'SplFileObject::setCsvControl' => ['void', 'separator='=>'string', 'enclosure='=>'string', 'escape='=>'string'], -'SplFileObject::setFileClass' => ['void', 'class='=>'string'], +'SplFileObject::setFileClass' => ['void', 'class='=>'class-string'], 'SplFileObject::setFlags' => ['void', 'flags'=>'int'], -'SplFileObject::setInfoClass' => ['void', 'class='=>'string'], +'SplFileObject::setInfoClass' => ['void', 'class='=>'class-string'], 'SplFileObject::setMaxLineLen' => ['void', 'maxLength'=>'int'], 'SplFileObject::valid' => ['bool'], 'SplFixedArray::__construct' => ['void', 'size='=>'int'], 'SplFixedArray::__wakeup' => ['void'], 'SplFixedArray::count' => ['int'], 'SplFixedArray::current' => ['mixed'], -'SplFixedArray::fromArray' => ['SplFixedArray', 'data'=>'array', 'save_indexes='=>'bool'], +'SplFixedArray::fromArray' => ['SplFixedArray', 'array'=>'array', 'preserveKeys='=>'bool'], 'SplFixedArray::getSize' => ['int'], 'SplFixedArray::key' => ['int'], 'SplFixedArray::next' => ['void'], 'SplFixedArray::offsetExists' => ['bool', 'index'=>'int'], 'SplFixedArray::offsetGet' => ['mixed', 'index'=>'int'], -'SplFixedArray::offsetSet' => ['void', 'index'=>'int', 'newval'=>'mixed'], +'SplFixedArray::offsetSet' => ['void', 'index'=>'int', 'value'=>'mixed'], 'SplFixedArray::offsetUnset' => ['void', 'index'=>'int'], 'SplFixedArray::rewind' => ['void'], 'SplFixedArray::setSize' => ['bool', 'size'=>'int'], @@ -12425,8 +12418,8 @@ return [ 'SplHeap::top' => ['mixed'], 'SplHeap::valid' => ['bool'], 'SplMaxHeap::__construct' => ['void'], -'SplMaxHeap::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'], -'SplMinHeap::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'], +'SplMaxHeap::compare' => ['int', 'value1'=>'mixed', 'value2'=>'mixed'], +'SplMinHeap::compare' => ['int', 'value1'=>'mixed', 'value2'=>'mixed'], 'SplMinHeap::count' => ['int'], 'SplMinHeap::current' => ['mixed'], 'SplMinHeap::extract' => ['mixed'], @@ -12440,10 +12433,10 @@ return [ 'SplMinHeap::top' => ['mixed'], 'SplMinHeap::valid' => ['bool'], 'SplObjectStorage::__construct' => ['void'], -'SplObjectStorage::addAll' => ['void', 'os'=>'splobjectstorage'], -'SplObjectStorage::attach' => ['void', 'object'=>'object', 'inf='=>'mixed'], +'SplObjectStorage::addAll' => ['int', 'storage'=>'SplObjectStorage'], +'SplObjectStorage::attach' => ['void', 'object'=>'object', 'info='=>'mixed'], 'SplObjectStorage::contains' => ['bool', 'object'=>'object'], -'SplObjectStorage::count' => ['int'], +'SplObjectStorage::count' => ['int', 'mode='=>'int'], 'SplObjectStorage::current' => ['object'], 'SplObjectStorage::detach' => ['void', 'object'=>'object'], 'SplObjectStorage::getHash' => ['string', 'object'=>'object'], @@ -12452,18 +12445,18 @@ return [ 'SplObjectStorage::next' => ['void'], 'SplObjectStorage::offsetExists' => ['bool', 'object'=>'object'], 'SplObjectStorage::offsetGet' => ['mixed', 'object'=>'object'], -'SplObjectStorage::offsetSet' => ['object', 'object'=>'object', 'data='=>'mixed'], +'SplObjectStorage::offsetSet' => ['void', 'object'=>'object', 'info='=>'mixed'], 'SplObjectStorage::offsetUnset' => ['void', 'object'=>'object'], -'SplObjectStorage::removeAll' => ['void', 'os'=>'splobjectstorage'], -'SplObjectStorage::removeAllExcept' => ['void', 'os'=>'splobjectstorage'], +'SplObjectStorage::removeAll' => ['int', 'storage'=>'SplObjectStorage'], +'SplObjectStorage::removeAllExcept' => ['int', 'storage'=>'SplObjectStorage'], 'SplObjectStorage::rewind' => ['void'], 'SplObjectStorage::serialize' => ['string'], -'SplObjectStorage::setInfo' => ['void', 'inf'=>'mixed'], -'SplObjectStorage::unserialize' => ['void', 'serialized'=>'string'], +'SplObjectStorage::setInfo' => ['void', 'info'=>'mixed'], +'SplObjectStorage::unserialize' => ['void', 'data'=>'string'], 'SplObjectStorage::valid' => ['bool'], 'SplObserver::update' => ['void', 'subject'=>'SplSubject'], 'SplPriorityQueue::__construct' => ['void'], -'SplPriorityQueue::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'], +'SplPriorityQueue::compare' => ['int', 'priority1'=>'mixed', 'priority2'=>'mixed'], 'SplPriorityQueue::count' => ['int'], 'SplPriorityQueue::current' => ['mixed'], 'SplPriorityQueue::extract' => ['mixed'], @@ -12486,7 +12479,7 @@ return [ 'SplQueue::next' => ['void'], 'SplQueue::offsetExists' => ['bool', 'index'=>'mixed'], 'SplQueue::offsetGet' => ['mixed', 'index'=>'mixed'], -'SplQueue::offsetSet' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], +'SplQueue::offsetSet' => ['void', 'index'=>'?int', 'value'=>'mixed'], 'SplQueue::offsetUnset' => ['void', 'index'=>'mixed'], 'SplQueue::pop' => ['mixed'], 'SplQueue::prev' => ['void'], @@ -12496,11 +12489,11 @@ return [ 'SplQueue::setIteratorMode' => ['int', 'mode'=>'int'], 'SplQueue::shift' => ['mixed'], 'SplQueue::top' => ['mixed'], -'SplQueue::unserialize' => ['void', 'serialized'=>'string'], +'SplQueue::unserialize' => ['void', 'data'=>'string'], 'SplQueue::unshift' => ['void', 'value'=>'mixed'], 'SplQueue::valid' => ['bool'], 'SplStack::__construct' => ['void'], -'SplStack::add' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], +'SplStack::add' => ['void', 'index'=>'int', 'value'=>'mixed'], 'SplStack::bottom' => ['mixed'], 'SplStack::count' => ['int'], 'SplStack::current' => ['mixed'], @@ -12510,7 +12503,7 @@ return [ 'SplStack::next' => ['void'], 'SplStack::offsetExists' => ['bool', 'index'=>'mixed'], 'SplStack::offsetGet' => ['mixed', 'index'=>'mixed'], -'SplStack::offsetSet' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], +'SplStack::offsetSet' => ['void', 'index'=>'?int', 'value'=>'mixed'], 'SplStack::offsetUnset' => ['void', 'index'=>'mixed'], 'SplStack::pop' => ['mixed'], 'SplStack::prev' => ['void'], @@ -12520,7 +12513,7 @@ return [ 'SplStack::setIteratorMode' => ['int', 'mode'=>'int'], 'SplStack::shift' => ['mixed'], 'SplStack::top' => ['mixed'], -'SplStack::unserialize' => ['void', 'serialized'=>'string'], +'SplStack::unserialize' => ['void', 'data'=>'string'], 'SplStack::unshift' => ['void', 'value'=>'mixed'], 'SplStack::valid' => ['bool'], 'SplSubject::attach' => ['void', 'observer'=>'SplObserver'], @@ -12551,7 +12544,7 @@ return [ 'SplTempFileObject::getCTime' => ['int|false'], 'SplTempFileObject::getCurrentLine' => ['string'], 'SplTempFileObject::getExtension' => ['string'], -'SplTempFileObject::getFileInfo' => ['SplFileInfo', 'class='=>'?string'], +'SplTempFileObject::getFileInfo' => ['SplFileInfo', 'class='=>'?class-string'], 'SplTempFileObject::getFilename' => ['string'], 'SplTempFileObject::getFlags' => ['int'], 'SplTempFileObject::getGroup' => ['int|false'], @@ -12561,7 +12554,7 @@ return [ 'SplTempFileObject::getMTime' => ['int|false'], 'SplTempFileObject::getOwner' => ['int|false'], 'SplTempFileObject::getPath' => ['string'], -'SplTempFileObject::getPathInfo' => ['SplFileInfo|null', 'class='=>'?string'], +'SplTempFileObject::getPathInfo' => ['SplFileInfo|null', 'class='=>'?class-string'], 'SplTempFileObject::getPathname' => ['string'], 'SplTempFileObject::getPerms' => ['int|false'], 'SplTempFileObject::getRealPath' => ['false|string'], @@ -12580,9 +12573,9 @@ return [ 'SplTempFileObject::rewind' => ['void'], 'SplTempFileObject::seek' => ['void', 'line'=>'int'], 'SplTempFileObject::setCsvControl' => ['void', 'separator='=>'string', 'enclosure='=>'string', 'escape='=>'string'], -'SplTempFileObject::setFileClass' => ['void', 'class='=>'string'], +'SplTempFileObject::setFileClass' => ['void', 'class='=>'class-string'], 'SplTempFileObject::setFlags' => ['void', 'flags'=>'int'], -'SplTempFileObject::setInfoClass' => ['void', 'class='=>'string'], +'SplTempFileObject::setInfoClass' => ['void', 'class='=>'class-string'], 'SplTempFileObject::setMaxLineLen' => ['void', 'maxLength'=>'int'], 'SplTempFileObject::valid' => ['bool'], 'SplType::__construct' => ['void', 'initial_value='=>'mixed', 'strict='=>'bool'], @@ -14271,7 +14264,7 @@ return [ 'uopz_get_hook\'1' => ['?Closure', 'function'=>'string'], 'uopz_get_mock' => ['string|object|null', 'class'=>'string'], 'uopz_get_property' => ['mixed', 'class'=>'object|string', 'property'=>'string'], -'uopz_get_return' => ['mixed', 'class='=>'string', 'function='=>'string'], +'uopz_get_return' => ['mixed', 'class='=>'class-string', 'function='=>'string'], 'uopz_get_static' => ['?array', 'class'=>'string', 'function'=>'string'], 'uopz_implement' => ['bool', 'class'=>'string', 'interface'=>'string'], 'uopz_overload' => ['void', 'opcode'=>'int', 'callable'=>'Callable'], @@ -14293,7 +14286,7 @@ return [ 'uopz_unset_hook' => ['bool', 'class'=>'string', 'function'=>'string'], 'uopz_unset_hook\'1' => ['bool', 'function'=>'string'], 'uopz_unset_mock' => ['void', 'class'=>'string'], -'uopz_unset_return' => ['bool', 'class='=>'string', 'function='=>'string'], +'uopz_unset_return' => ['bool', 'class='=>'class-string', 'function='=>'string'], 'uopz_unset_return\'1' => ['bool', 'function'=>'string'], 'urldecode' => ['string', 'string'=>'string'], 'urlencode' => ['string', 'string'=>'string'], diff --git a/vendor/vimeo/psalm/dictionaries/CallMap_80_delta.php b/vendor/vimeo/psalm/dictionaries/CallMap_80_delta.php index b2cc5c42..89b4bdfc 100644 --- a/vendor/vimeo/psalm/dictionaries/CallMap_80_delta.php +++ b/vendor/vimeo/psalm/dictionaries/CallMap_80_delta.php @@ -41,9 +41,9 @@ return [ 'old' => ['int|false'], 'new' => ['int'], ], - 'DateTime::diff' => [ - 'old' => ['DateInterval|false', 'datetime2'=>'DateTimeInterface', 'absolute='=>'bool'], - 'new' => ['DateInterval', 'datetime2'=>'DateTimeInterface', 'absolute='=>'bool'], + 'CURLFile::__construct' => [ + 'old' => ['void', 'filename'=>'string', 'mime_type='=>'string', 'posted_filename='=>'string'], + 'new' => ['void', 'filename'=>'string', 'mime_type='=>'?string', 'posted_filename='=>'?string'], ], 'DateTime::format' => [ 'old' => ['string|false', 'format'=>'string'], @@ -53,10 +53,6 @@ return [ 'old' => ['int|false'], 'new' => ['int'], ], - 'DateTime::setTime' => [ - 'old' => ['static|false', 'hour'=>'int', 'minute'=>'int', 'second='=>'int', 'microseconds='=>'int'], - 'new' => ['static', 'hour'=>'int', 'minute'=>'int', 'second='=>'int', 'microseconds='=>'int'], - ], 'DateTimeInterface::getTimestamp' => [ 'old' => ['int|false'], 'new' => ['int'], @@ -81,14 +77,58 @@ return [ 'old' => ['void', 'dir_handle='=>'resource'], 'new' => ['void'], ], + 'DirectoryIterator::getFileInfo' => [ + 'old' => ['SplFileInfo', 'class='=>'class-string'], + 'new' => ['SplFileInfo', 'class='=>'?class-string'], + ], + 'DirectoryIterator::getPathInfo' => [ + 'old' => ['?SplFileInfo', 'class='=>'class-string'], + 'new' => ['?SplFileInfo', 'class='=>'?class-string'], + ], + 'DirectoryIterator::openFile' => [ + 'old' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], + 'new' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], + ], + 'DOMDocument::getElementsByTagNameNS' => [ + 'old' => ['DOMNodeList', 'namespace'=>'string', 'localName'=>'string'], + 'new' => ['DOMNodeList', 'namespace'=>'?string', 'localName'=>'string'], + ], + 'DOMImplementation::createDocument' => [ + 'old' => ['DOMDocument|false', 'namespace='=>'string', 'qualifiedName='=>'string', 'doctype='=>'DOMDocumentType'], + 'new' => ['DOMDocument|false', 'namespace='=>'?string', 'qualifiedName='=>'string', 'doctype='=>'?DOMDocumentType'], + ], 'ErrorException::__construct' => [ 'old' => ['void', 'message='=>'string', 'code='=>'int', 'severity='=>'int', 'filename='=>'string', 'line='=>'int', 'previous='=>'?Throwable'], 'new' => ['void', 'message='=>'string', 'code='=>'int', 'severity='=>'int', 'filename='=>'?string', 'line='=>'?int', 'previous='=>'?Throwable'], ], + 'FilesystemIterator::getFileInfo' => [ + 'old' => ['SplFileInfo', 'class='=>'class-string'], + 'new' => ['SplFileInfo', 'class='=>'?class-string'], + ], + 'FilesystemIterator::getPathInfo' => [ + 'old' => ['?SplFileInfo', 'class='=>'class-string'], + 'new' => ['?SplFileInfo', 'class='=>'?class-string'], + ], + 'FilesystemIterator::openFile' => [ + 'old' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], + 'new' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], + ], 'finfo::__construct' => [ 'old' => ['void', 'flags='=>'int', 'magic_database='=>'string'], 'new' => ['void', 'flags='=>'int', 'magic_database='=>'?string'], ], + 'GlobIterator::getFileInfo' => [ + 'old' => ['SplFileInfo', 'class='=>'class-string'], + 'new' => ['SplFileInfo', 'class='=>'?class-string'], + ], + 'GlobIterator::getPathInfo' => [ + 'old' => ['?SplFileInfo', 'class='=>'class-string'], + 'new' => ['?SplFileInfo', 'class='=>'?class-string'], + ], + 'GlobIterator::openFile' => [ + 'old' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], + 'new' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], + ], 'IntlDateFormatter::__construct' => [ 'old' => ['void', 'locale'=>'?string', 'datetype'=>'null|int', 'timetype'=>'null|int', 'timezone='=>'IntlTimeZone|DateTimeZone|string|null', 'calendar='=>'IntlCalendar|int|null', 'pattern='=>'?string'], 'new' => ['void', 'locale'=>'?string', 'dateType'=>'int', 'timeType'=>'int', 'timezone='=>'IntlTimeZone|DateTimeZone|string|null', 'calendar='=>'IntlCalendar|int|null', 'pattern='=>'?string'], @@ -153,6 +193,10 @@ return [ 'old' => ['null|false', 'zone'=>'IntlTimeZone|DateTimeZone|string|null'], 'new' => ['null|false', 'timezone'=>'IntlTimeZone|DateTimeZone|string|null'], ], + 'IntlTimeZone::getIDForWindowsID' => [ + 'old' => ['string|false', 'timezoneId'=>'string', 'region='=>'string'], + 'new' => ['string|false', 'timezoneId'=>'string', 'region='=>'?string'], + ], 'Locale::getDisplayLanguage' => [ 'old' => ['string', 'locale'=>'string', 'displayLocale='=>'string'], 'new' => ['string', 'locale'=>'string', 'displayLocale='=>'?string'], @@ -209,21 +253,17 @@ return [ 'old' => ['bool', 'mode'=>'int'], 'new' => ['bool', 'mode'=>'int', '...args='=>'mixed'], ], - 'PharData::compress' => [ - 'old' => ['?PharData', 'compression'=>'int', 'extension='=>'string'], - 'new' => ['?PharData', 'compression'=>'int', 'extension='=>'?string'], + 'Phar::addFile' => [ + 'old' => ['void', 'filename'=>'string', 'localName='=>'string'], + 'new' => ['void', 'filename'=>'string', 'localName='=>'?string'], ], - 'PharData::convertToData' => [ - 'old' => ['?PharData', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'], - 'new' => ['?PharData', 'format='=>'?int', 'compression='=>'?int', 'extension='=>'?string'], + 'Phar::buildFromIterator' => [ + 'old' => ['array|false', 'iterator'=>'Traversable', 'baseDirectory='=>'string'], + 'new' => ['array|false', 'iterator'=>'Traversable', 'baseDirectory='=>'?string'], ], - 'PharData::convertToExecutable' => [ - 'old' => ['?Phar', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'], - 'new' => ['?Phar', 'format='=>'?int', 'compression='=>'?int', 'extension='=>'?string'], - ], - 'PharData::decompress' => [ - 'old' => ['?PharData', 'extension='=>'string'], - 'new' => ['?PharData', 'extension='=>'?string'], + 'Phar::createDefaultStub' => [ + 'old' => ['string', 'index='=>'string', 'webIndex='=>'string'], + 'new' => ['string', 'index='=>'?string', 'webIndex='=>'?string'], ], 'Phar::compress' => [ 'old' => ['?Phar', 'compression'=>'int', 'extension='=>'string'], @@ -245,10 +285,70 @@ return [ 'old' => ['mixed'], 'new' => ['mixed', 'unserializeOptions='=>'array'], ], + 'Phar::setDefaultStub' => [ + 'old' => ['bool', 'index='=>'?string', 'webIndex='=>'string'], + 'new' => ['bool', 'index='=>'?string', 'webIndex='=>'?string'], + ], + 'Phar::setSignatureAlgorithm' => [ + 'old' => ['void', 'algo'=>'int', 'privateKey='=>'string'], + 'new' => ['void', 'algo'=>'int', 'privateKey='=>'?string'], + ], + 'Phar::webPhar' => [ + 'old' => ['void', 'alias='=>'?string', 'index='=>'?string', 'fileNotFoundScript='=>'string', 'mimeTypes='=>'array', 'rewrite='=>'callable'], + 'new' => ['void', 'alias='=>'?string', 'index='=>'?string', 'fileNotFoundScript='=>'?string', 'mimeTypes='=>'array', 'rewrite='=>'?callable'], + ], + 'PharData::addFile' => [ + 'old' => ['void', 'filename'=>'string', 'localName='=>'string'], + 'new' => ['void', 'filename'=>'string', 'localName='=>'?string'], + ], + 'PharData::buildFromIterator' => [ + 'old' => ['array|false', 'iterator'=>'Traversable', 'baseDirectory='=>'string'], + 'new' => ['array|false', 'iterator'=>'Traversable', 'baseDirectory='=>'?string'], + ], + 'PharData::compress' => [ + 'old' => ['?PharData', 'compression'=>'int', 'extension='=>'string'], + 'new' => ['?PharData', 'compression'=>'int', 'extension='=>'?string'], + ], + 'PharData::convertToData' => [ + 'old' => ['?PharData', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'], + 'new' => ['?PharData', 'format='=>'?int', 'compression='=>'?int', 'extension='=>'?string'], + ], + 'PharData::convertToExecutable' => [ + 'old' => ['?Phar', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'], + 'new' => ['?Phar', 'format='=>'?int', 'compression='=>'?int', 'extension='=>'?string'], + ], + 'PharData::decompress' => [ + 'old' => ['?PharData', 'extension='=>'string'], + 'new' => ['?PharData', 'extension='=>'?string'], + ], + 'PharData::setDefaultStub' => [ + 'old' => ['bool', 'index='=>'?string', 'webIndex='=>'string'], + 'new' => ['bool', 'index='=>'?string', 'webIndex='=>'?string'], + ], + 'PharData::setSignatureAlgorithm' => [ + 'old' => ['void', 'algo'=>'int', 'privateKey='=>'string'], + 'new' => ['void', 'algo'=>'int', 'privateKey='=>'?string'], + ], 'PharFileInfo::getMetadata' => [ 'old' => ['mixed'], 'new' => ['mixed', 'unserializeOptions='=>'array'], ], + 'PharFileInfo::isCompressed' => [ + 'old' => ['bool', 'compression='=>'int'], + 'new' => ['bool', 'compression='=>'?int'], + ], + 'RecursiveDirectoryIterator::getFileInfo' => [ + 'old' => ['SplFileInfo', 'class='=>'class-string'], + 'new' => ['SplFileInfo', 'class='=>'?class-string'], + ], + 'RecursiveDirectoryIterator::getPathInfo' => [ + 'old' => ['?SplFileInfo', 'class='=>'class-string'], + 'new' => ['?SplFileInfo', 'class='=>'?class-string'], + ], + 'RecursiveDirectoryIterator::openFile' => [ + 'old' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], + 'new' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], + ], 'RecursiveIteratorIterator::getSubIterator' => [ 'old' => ['?RecursiveIterator', 'level='=>'int'], 'new' => ['?RecursiveIterator', 'level='=>'?int'], @@ -282,36 +382,36 @@ return [ 'new' => ['mixed', 'object='=>'null|object'], ], 'SplFileInfo::getFileInfo' => [ - 'old' => ['SplFileInfo', 'class='=>'string'], - 'new' => ['SplFileInfo', 'class='=>'?string'], + 'old' => ['SplFileInfo', 'class='=>'class-string'], + 'new' => ['SplFileInfo', 'class='=>'?class-string'], ], 'SplFileInfo::getPathInfo' => [ - 'old' => ['SplFileInfo|null', 'class='=>'string'], - 'new' => ['SplFileInfo|null', 'class='=>'?string'], + 'old' => ['SplFileInfo|null', 'class='=>'class-string'], + 'new' => ['SplFileInfo|null', 'class='=>'?class-string'], ], 'SplFileInfo::openFile' => [ 'old' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], 'new' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], ], 'SplFileObject::getFileInfo' => [ - 'old' => ['SplFileInfo', 'class='=>'string'], - 'new' => ['SplFileInfo', 'class='=>'?string'], + 'old' => ['SplFileInfo', 'class='=>'class-string'], + 'new' => ['SplFileInfo', 'class='=>'?class-string'], ], 'SplFileObject::getPathInfo' => [ - 'old' => ['SplFileInfo|null', 'class='=>'string'], - 'new' => ['SplFileInfo|null', 'class='=>'?string'], + 'old' => ['SplFileInfo|null', 'class='=>'class-string'], + 'new' => ['SplFileInfo|null', 'class='=>'?class-string'], ], 'SplFileObject::openFile' => [ 'old' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], 'new' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], ], 'SplTempFileObject::getFileInfo' => [ - 'old' => ['SplFileInfo', 'class='=>'string'], - 'new' => ['SplFileInfo', 'class='=>'?string'], + 'old' => ['SplFileInfo', 'class='=>'class-string'], + 'new' => ['SplFileInfo', 'class='=>'?class-string'], ], 'SplTempFileObject::getPathInfo' => [ - 'old' => ['SplFileInfo|null', 'class='=>'string'], - 'new' => ['SplFileInfo|null', 'class='=>'?string'], + 'old' => ['SplFileInfo|null', 'class='=>'class-string'], + 'new' => ['SplFileInfo|null', 'class='=>'?class-string'], ], 'SplTempFileObject::openFile' => [ 'old' => ['SplTempFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], @@ -390,40 +490,40 @@ return [ 'new' => ['array', 'array'=>'array', 'column_key'=>'int|string|null', 'index_key='=>'int|string|null'], ], 'array_combine' => [ - 'old' => ['associative-array|false', 'keys'=>'string[]|int[]', 'values'=>'array'], - 'new' => ['associative-array', 'keys'=>'string[]|int[]', 'values'=>'array'], + 'old' => ['array|false', 'keys'=>'string[]|int[]', 'values'=>'array'], + 'new' => ['array', 'keys'=>'string[]|int[]', 'values'=>'array'], ], 'array_diff' => [ - 'old' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'new' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], + 'old' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'new' => ['array', 'array'=>'array', '...arrays='=>'array'], ], 'array_diff_assoc' => [ - 'old' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'new' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], + 'old' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'new' => ['array', 'array'=>'array', '...arrays='=>'array'], ], 'array_diff_key' => [ - 'old' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'new' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], + 'old' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'new' => ['array', 'array'=>'array', '...arrays='=>'array'], ], 'array_filter' => [ - 'old' => ['associative-array', 'array'=>'array', 'callback='=>'callable(mixed,mixed=):scalar', 'mode='=>'int'], - 'new' => ['associative-array', 'array'=>'array', 'callback='=>'callable(mixed,mixed=):scalar|null', 'mode='=>'int'], + 'old' => ['array', 'array'=>'array', 'callback='=>'callable(mixed,mixed=):scalar', 'mode='=>'int'], + 'new' => ['array', 'array'=>'array', 'callback='=>'callable(mixed,mixed=):scalar|null', 'mode='=>'int'], ], 'array_key_exists' => [ 'old' => ['bool', 'key'=>'string|int', 'array'=>'array|object'], 'new' => ['bool', 'key'=>'string|int', 'array'=>'array'], ], 'array_intersect' => [ - 'old' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'new' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], + 'old' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'new' => ['array', 'array'=>'array', '...arrays='=>'array'], ], 'array_intersect_assoc' => [ - 'old' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'new' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], + 'old' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'new' => ['array', 'array'=>'array', '...arrays='=>'array'], ], 'array_intersect_key' => [ - 'old' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'new' => ['associative-array', 'array'=>'array', '...arrays='=>'array'], + 'old' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'new' => ['array', 'array'=>'array', '...arrays='=>'array'], ], 'array_splice' => [ 'old' => ['array', '&rw_array'=>'array', 'offset'=>'int', 'length='=>'int', 'replacement='=>'array|string'], @@ -497,6 +597,10 @@ return [ 'old' => ['int<0, max>', 'value'=>'Countable|array|SimpleXMLElement', 'mode='=>'int'], 'new' => ['int<0, max>', 'value'=>'Countable|array', 'mode='=>'int'], ], + 'sizeof' => [ + 'old' => ['int<0, max>', 'value'=>'Countable|array|SimpleXMLElement', 'mode='=>'int'], + 'new' => ['int<0, max>', 'value'=>'Countable|array', 'mode='=>'int'], + ], 'count_chars' => [ 'old' => ['array|false', 'input'=>'string', 'mode='=>'0|1|2'], 'new' => ['array', 'input'=>'string', 'mode='=>'0|1|2'], diff --git a/vendor/vimeo/psalm/dictionaries/CallMap_81_delta.php b/vendor/vimeo/psalm/dictionaries/CallMap_81_delta.php index 6d76650b..ded1f5e4 100644 --- a/vendor/vimeo/psalm/dictionaries/CallMap_81_delta.php +++ b/vendor/vimeo/psalm/dictionaries/CallMap_81_delta.php @@ -66,6 +66,26 @@ return [ 'old' => ['DOMDocumentFragment|false'], 'new' => ['DOMDocumentFragment'], ], + 'DOMDocument::createTextNode' => [ + 'old' => ['DOMText|false', 'data'=>'string'], + 'new' => ['DOMText', 'data'=>'string'], + ], + 'Phar::buildFromDirectory' => [ + 'old' => ['array|false', 'directory'=>'string', 'pattern='=>'string'], + 'new' => ['array', 'directory'=>'string', 'pattern='=>'string'], + ], + 'Phar::buildFromIterator' => [ + 'old' => ['array|false', 'iterator'=>'Traversable', 'baseDirectory='=>'?string'], + 'new' => ['array', 'iterator'=>'Traversable', 'baseDirectory='=>'?string'], + ], + 'PharData::buildFromDirectory' => [ + 'old' => ['array|false', 'directory'=>'string', 'pattern='=>'string'], + 'new' => ['array', 'directory'=>'string', 'pattern='=>'string'], + ], + 'PharData::buildFromIterator' => [ + 'old' => ['array|false', 'iterator'=>'Traversable', 'baseDirectory='=>'?string'], + 'new' => ['array', 'iterator'=>'Traversable', 'baseDirectory='=>'?string'], + ], 'SplFileObject::fputcsv' => [ 'old' => ['int|false', 'fields'=>'array', 'separator='=>'string', 'enclosure='=>'string', 'escape='=>'string'], 'new' => ['int|false', 'fields'=>'array', 'separator='=>'string', 'enclosure='=>'string', 'escape='=>'string', 'eol='=>'string'], diff --git a/vendor/vimeo/psalm/dictionaries/CallMap_83_delta.php b/vendor/vimeo/psalm/dictionaries/CallMap_83_delta.php new file mode 100644 index 00000000..2d27020d --- /dev/null +++ b/vendor/vimeo/psalm/dictionaries/CallMap_83_delta.php @@ -0,0 +1,32 @@ + [ + 'json_validate' => ['bool', 'json'=>'string', 'depth='=>'positive-int', 'flags='=>'int'], + ], + + 'changed' => [ + 'gc_status' => [ + 'old' => ['array{runs:int,collected:int,threshold:int,roots:int}'], + 'new' => ['array{runs:int,collected:int,threshold:int,roots:int,running:bool,protected:bool,full:bool,buffer_size:int}'], + ], + ], + + 'removed' => [ + ], +]; diff --git a/vendor/vimeo/psalm/dictionaries/CallMap_historical.php b/vendor/vimeo/psalm/dictionaries/CallMap_historical.php index b5727394..2b14a8a5 100644 --- a/vendor/vimeo/psalm/dictionaries/CallMap_historical.php +++ b/vendor/vimeo/psalm/dictionaries/CallMap_historical.php @@ -215,50 +215,50 @@ return [ 'ArrayAccess::offsetUnset' => ['void', 'offset'=>'mixed'], 'ArrayIterator::__construct' => ['void', 'array='=>'array|object', 'flags='=>'int'], 'ArrayIterator::append' => ['void', 'value'=>'mixed'], - 'ArrayIterator::asort' => ['void'], + 'ArrayIterator::asort' => ['true', 'flags='=>'int'], 'ArrayIterator::count' => ['int'], 'ArrayIterator::current' => ['mixed'], 'ArrayIterator::getArrayCopy' => ['array'], 'ArrayIterator::getFlags' => ['int'], 'ArrayIterator::key' => ['int|string|null'], - 'ArrayIterator::ksort' => ['void'], + 'ArrayIterator::ksort' => ['true', 'flags='=>'int'], 'ArrayIterator::natcasesort' => ['true'], 'ArrayIterator::natsort' => ['true'], 'ArrayIterator::next' => ['void'], - 'ArrayIterator::offsetExists' => ['bool', 'index'=>'string|int'], - 'ArrayIterator::offsetGet' => ['mixed', 'index'=>'string|int'], - 'ArrayIterator::offsetSet' => ['void', 'index'=>'string|int', 'newval'=>'mixed'], - 'ArrayIterator::offsetUnset' => ['void', 'index'=>'string|int'], + 'ArrayIterator::offsetExists' => ['bool', 'key'=>'string|int'], + 'ArrayIterator::offsetGet' => ['mixed', 'key'=>'string|int'], + 'ArrayIterator::offsetSet' => ['void', 'key'=>'string|int', 'value'=>'mixed'], + 'ArrayIterator::offsetUnset' => ['void', 'key'=>'string|int'], 'ArrayIterator::rewind' => ['void'], - 'ArrayIterator::seek' => ['void', 'position'=>'int'], + 'ArrayIterator::seek' => ['void', 'offset'=>'int'], 'ArrayIterator::serialize' => ['string'], - 'ArrayIterator::setFlags' => ['void', 'flags'=>'string'], - 'ArrayIterator::uasort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], - 'ArrayIterator::uksort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], - 'ArrayIterator::unserialize' => ['void', 'serialized'=>'string'], + 'ArrayIterator::setFlags' => ['void', 'flags'=>'int'], + 'ArrayIterator::uasort' => ['true', 'callback'=>'callable(mixed,mixed):int'], + 'ArrayIterator::uksort' => ['true', 'callback'=>'callable(mixed,mixed):int'], + 'ArrayIterator::unserialize' => ['void', 'data'=>'string'], 'ArrayIterator::valid' => ['bool'], - 'ArrayObject::__construct' => ['void', 'input='=>'array|object', 'flags='=>'int', 'iterator_class='=>'string'], + 'ArrayObject::__construct' => ['void', 'array='=>'array|object', 'flags='=>'int', 'iteratorClass='=>'class-string'], 'ArrayObject::append' => ['void', 'value'=>'mixed'], - 'ArrayObject::asort' => ['void'], + 'ArrayObject::asort' => ['true', 'flags='=>'int'], 'ArrayObject::count' => ['int'], - 'ArrayObject::exchangeArray' => ['array', 'ar'=>'mixed'], + 'ArrayObject::exchangeArray' => ['array', 'array'=>'array|object'], 'ArrayObject::getArrayCopy' => ['array'], 'ArrayObject::getFlags' => ['int'], 'ArrayObject::getIterator' => ['ArrayIterator'], 'ArrayObject::getIteratorClass' => ['string'], - 'ArrayObject::ksort' => ['void'], + 'ArrayObject::ksort' => ['true', 'flags='=>'int'], 'ArrayObject::natcasesort' => ['true'], 'ArrayObject::natsort' => ['true'], - 'ArrayObject::offsetExists' => ['bool', 'index'=>'int|string'], - 'ArrayObject::offsetGet' => ['mixed|null', 'index'=>'int|string'], - 'ArrayObject::offsetSet' => ['void', 'index'=>'int|string', 'newval'=>'mixed'], - 'ArrayObject::offsetUnset' => ['void', 'index'=>'int|string'], + 'ArrayObject::offsetExists' => ['bool', 'key'=>'int|string'], + 'ArrayObject::offsetGet' => ['mixed|null', 'key'=>'int|string'], + 'ArrayObject::offsetSet' => ['void', 'key'=>'int|string', 'value'=>'mixed'], + 'ArrayObject::offsetUnset' => ['void', 'key'=>'int|string'], 'ArrayObject::serialize' => ['string'], 'ArrayObject::setFlags' => ['void', 'flags'=>'int'], - 'ArrayObject::setIteratorClass' => ['void', 'iterator_class'=>'string'], - 'ArrayObject::uasort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], - 'ArrayObject::uksort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], - 'ArrayObject::unserialize' => ['void', 'serialized'=>'string'], + 'ArrayObject::setIteratorClass' => ['void', 'iteratorClass'=>'class-string'], + 'ArrayObject::uasort' => ['true', 'callback'=>'callable(mixed,mixed):int'], + 'ArrayObject::uksort' => ['true', 'callback'=>'callable(mixed,mixed):int'], + 'ArrayObject::unserialize' => ['void', 'data'=>'string'], 'BadFunctionCallException::__clone' => ['void'], 'BadFunctionCallException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable'], 'BadFunctionCallException::__toString' => ['string'], @@ -292,13 +292,13 @@ return [ 'COMPersistHelper::SaveToFile' => ['bool', 'filename'=>'string', 'remember'=>'bool'], 'COMPersistHelper::SaveToStream' => ['int', 'stream'=>''], 'COMPersistHelper::__construct' => ['void', 'variant'=>'object'], - 'CURLFile::__construct' => ['void', 'filename'=>'string', 'mimetype='=>'string', 'postfilename='=>'string'], + 'CURLFile::__construct' => ['void', 'filename'=>'string', 'mime_type='=>'string', 'posted_filename='=>'string'], 'CURLFile::__wakeup' => ['void'], 'CURLFile::getFilename' => ['string'], 'CURLFile::getMimeType' => ['string'], 'CURLFile::getPostFilename' => ['string'], - 'CURLFile::setMimeType' => ['void', 'mime'=>'string'], - 'CURLFile::setPostFilename' => ['void', 'name'=>'string'], + 'CURLFile::setMimeType' => ['void', 'mime_type'=>'string'], + 'CURLFile::setPostFilename' => ['void', 'posted_filename'=>'string'], 'CachingIterator::__construct' => ['void', 'iterator'=>'Iterator', 'flags='=>''], 'CachingIterator::__toString' => ['string'], 'CachingIterator::count' => ['int'], @@ -309,14 +309,14 @@ return [ 'CachingIterator::hasNext' => ['bool'], 'CachingIterator::key' => ['int|string|float|bool'], 'CachingIterator::next' => ['void'], - 'CachingIterator::offsetExists' => ['bool', 'index'=>'string'], - 'CachingIterator::offsetGet' => ['mixed', 'index'=>'string'], - 'CachingIterator::offsetSet' => ['void', 'index'=>'string', 'newval'=>'mixed'], - 'CachingIterator::offsetUnset' => ['void', 'index'=>'string'], + 'CachingIterator::offsetExists' => ['bool', 'key'=>'string'], + 'CachingIterator::offsetGet' => ['mixed', 'key'=>'string'], + 'CachingIterator::offsetSet' => ['void', 'key'=>'string', 'value'=>'mixed'], + 'CachingIterator::offsetUnset' => ['void', 'key'=>'string'], 'CachingIterator::rewind' => ['void'], 'CachingIterator::setFlags' => ['void', 'flags'=>'int'], 'CachingIterator::valid' => ['bool'], - 'CallbackFilterIterator::__construct' => ['void', 'iterator'=>'Iterator', 'func'=>'callable(mixed):bool|callable(mixed,mixed):bool|callable(mixed,mixed,mixed):bool'], + 'CallbackFilterIterator::__construct' => ['void', 'iterator'=>'Iterator', 'callback'=>'callable(mixed,mixed=,mixed=):bool'], 'CallbackFilterIterator::accept' => ['bool'], 'CallbackFilterIterator::current' => ['mixed'], 'CallbackFilterIterator::getInnerIterator' => ['Iterator'], @@ -339,19 +339,19 @@ return [ 'Closure::bindTo' => ['?Closure', 'newThis'=>'?object', 'newScope='=>'object|string|null'], 'Closure::call' => ['mixed', 'newThis'=>'object', '...args='=>'mixed'], 'Collator::__construct' => ['void', 'locale'=>'string'], - 'Collator::asort' => ['bool', '&rw_arr'=>'array', 'sort_flag='=>'int'], + 'Collator::asort' => ['bool', '&rw_array'=>'array', 'flags='=>'int'], 'Collator::compare' => ['int|false', 'string1'=>'string', 'string2'=>'string'], 'Collator::create' => ['?Collator', 'locale'=>'string'], - 'Collator::getAttribute' => ['int|false', 'attr'=>'int'], + 'Collator::getAttribute' => ['int|false', 'attribute'=>'int'], 'Collator::getErrorCode' => ['int'], 'Collator::getErrorMessage' => ['string'], 'Collator::getLocale' => ['string', 'type'=>'int'], 'Collator::getSortKey' => ['string|false', 'string'=>'string'], 'Collator::getStrength' => ['int|false'], - 'Collator::setAttribute' => ['bool', 'attr'=>'int', 'value'=>'int'], + 'Collator::setAttribute' => ['bool', 'attribute'=>'int', 'value'=>'int'], 'Collator::setStrength' => ['bool', 'strength'=>'int'], - 'Collator::sort' => ['bool', '&rw_arr'=>'array', 'sort_flags='=>'int'], - 'Collator::sortWithSortKeys' => ['bool', '&rw_arr'=>'array'], + 'Collator::sort' => ['bool', '&rw_array'=>'array', 'flags='=>'int'], + 'Collator::sortWithSortKeys' => ['bool', '&rw_array'=>'array'], 'Collectable::isGarbage' => ['bool'], 'Collectable::setGarbage' => ['void'], 'Cond::broadcast' => ['bool', 'condition'=>'long'], @@ -701,44 +701,44 @@ return [ 'DOMAttr::getNodePath' => ['?string'], 'DOMAttr::hasAttributes' => ['bool'], 'DOMAttr::hasChildNodes' => ['bool'], - 'DOMAttr::insertBefore' => ['DOMNode', 'newnode'=>'DOMNode', 'refnode='=>'DOMNode'], - 'DOMAttr::isDefaultNamespace' => ['bool', 'namespaceuri'=>'string'], + 'DOMAttr::insertBefore' => ['DOMNode|false', 'node'=>'DOMNode', 'child='=>'?DOMNode'], + 'DOMAttr::isDefaultNamespace' => ['bool', 'namespace'=>'string'], 'DOMAttr::isId' => ['bool'], - 'DOMAttr::isSameNode' => ['bool', 'node'=>'DOMNode'], + 'DOMAttr::isSameNode' => ['bool', 'otherNode'=>'DOMNode'], 'DOMAttr::isSupported' => ['bool', 'feature'=>'string', 'version'=>'string'], 'DOMAttr::lookupNamespaceUri' => ['string|null', 'prefix'=>'string|null'], - 'DOMAttr::lookupPrefix' => ['string|null', 'namespaceuri'=>'string'], + 'DOMAttr::lookupPrefix' => ['string|null', 'namespace'=>'string'], 'DOMAttr::normalize' => ['void'], - 'DOMAttr::removeChild' => ['DOMNode', 'oldnode'=>'DOMNode'], - 'DOMAttr::replaceChild' => ['DOMNode', 'newnode'=>'DOMNode', 'oldnode'=>'DOMNode'], - 'DOMCdataSection::__construct' => ['void', 'value'=>'string'], + 'DOMAttr::removeChild' => ['DOMNode|false', 'child'=>'DOMNode'], + 'DOMAttr::replaceChild' => ['DOMNode|false', 'node'=>'DOMNode', 'child'=>'DOMNode'], + 'DOMCdataSection::__construct' => ['void', 'data'=>'string'], 'DOMCharacterData::appendData' => ['true', 'data'=>'string'], 'DOMCharacterData::deleteData' => ['bool', 'offset'=>'int', 'count'=>'int'], 'DOMCharacterData::insertData' => ['bool', 'offset'=>'int', 'data'=>'string'], 'DOMCharacterData::replaceData' => ['bool', 'offset'=>'int', 'count'=>'int', 'data'=>'string'], 'DOMCharacterData::substringData' => ['string', 'offset'=>'int', 'count'=>'int'], - 'DOMComment::__construct' => ['void', 'value='=>'string'], + 'DOMComment::__construct' => ['void', 'data='=>'string'], 'DOMDocument::__construct' => ['void', 'version='=>'string', 'encoding='=>'string'], - 'DOMDocument::createAttribute' => ['DOMAttr|false', 'name'=>'string'], - 'DOMDocument::createAttributeNS' => ['DOMAttr|false', 'namespaceuri'=>'string|null', 'qualifiedname'=>'string'], + 'DOMDocument::createAttribute' => ['DOMAttr|false', 'localName'=>'string'], + 'DOMDocument::createAttributeNS' => ['DOMAttr|false', 'namespace'=>'string|null', 'qualifiedName'=>'string'], 'DOMDocument::createCDATASection' => ['DOMCDATASection|false', 'data'=>'string'], 'DOMDocument::createComment' => ['DOMComment|false', 'data'=>'string'], 'DOMDocument::createDocumentFragment' => ['DOMDocumentFragment|false'], - 'DOMDocument::createElement' => ['DOMElement|false', 'name'=>'string', 'value='=>'string'], - 'DOMDocument::createElementNS' => ['DOMElement|false', 'namespaceuri'=>'string|null', 'qualifiedname'=>'string', 'value='=>'string'], + 'DOMDocument::createElement' => ['DOMElement|false', 'localName'=>'string', 'value='=>'string'], + 'DOMDocument::createElementNS' => ['DOMElement|false', 'namespace'=>'string|null', 'qualifiedName'=>'string', 'value='=>'string'], 'DOMDocument::createEntityReference' => ['DOMEntityReference|false', 'name'=>'string'], 'DOMDocument::createProcessingInstruction' => ['DOMProcessingInstruction|false', 'target'=>'string', 'data='=>'string'], - 'DOMDocument::createTextNode' => ['DOMText|false', 'content'=>'string'], - 'DOMDocument::getElementById' => ['?DOMElement', 'elementid'=>'string'], - 'DOMDocument::getElementsByTagName' => ['DOMNodeList', 'name'=>'string'], - 'DOMDocument::getElementsByTagNameNS' => ['DOMNodeList', 'namespaceuri'=>'string|null', 'localname'=>'string'], - 'DOMDocument::importNode' => ['DOMNode|false', 'importednode'=>'DOMNode', 'deep='=>'bool'], + 'DOMDocument::createTextNode' => ['DOMText|false', 'data'=>'string'], + 'DOMDocument::getElementById' => ['?DOMElement', 'elementId'=>'string'], + 'DOMDocument::getElementsByTagName' => ['DOMNodeList', 'qualifiedName'=>'string'], + 'DOMDocument::getElementsByTagNameNS' => ['DOMNodeList', 'namespace'=>'string', 'localName'=>'string'], + 'DOMDocument::importNode' => ['DOMNode|false', 'node'=>'DOMNode', 'deep='=>'bool'], 'DOMDocument::load' => ['DOMDocument|bool', 'filename'=>'string', 'options='=>'int'], 'DOMDocument::loadHTML' => ['bool', 'source'=>'non-empty-string', 'options='=>'int'], 'DOMDocument::loadHTMLFile' => ['bool', 'filename'=>'string', 'options='=>'int'], 'DOMDocument::loadXML' => ['DOMDocument|bool', 'source'=>'non-empty-string', 'options='=>'int'], 'DOMDocument::normalizeDocument' => ['void'], - 'DOMDocument::registerNodeClass' => ['bool', 'baseclass'=>'string', 'extendedclass'=>'string'], + 'DOMDocument::registerNodeClass' => ['bool', 'baseClass'=>'string', 'extendedClass'=>'?string'], 'DOMDocument::relaxNGValidate' => ['bool', 'filename'=>'string'], 'DOMDocument::relaxNGValidateSource' => ['bool', 'source'=>'string'], 'DOMDocument::save' => ['int|false', 'filename'=>'string', 'options='=>'int'], @@ -751,70 +751,70 @@ return [ 'DOMDocument::xinclude' => ['int', 'options='=>'int'], 'DOMDocumentFragment::__construct' => ['void'], 'DOMDocumentFragment::appendXML' => ['bool', 'data'=>'string'], - 'DOMElement::__construct' => ['void', 'name'=>'string', 'value='=>'string', 'uri='=>'string'], - 'DOMElement::getAttribute' => ['string', 'name'=>'string'], - 'DOMElement::getAttributeNS' => ['string', 'namespaceuri'=>'string|null', 'localname'=>'string'], - 'DOMElement::getAttributeNode' => ['DOMAttr', 'name'=>'string'], - 'DOMElement::getAttributeNodeNS' => ['DOMAttr', 'namespaceuri'=>'string|null', 'localname'=>'string'], - 'DOMElement::getElementsByTagName' => ['DOMNodeList', 'name'=>'string'], - 'DOMElement::getElementsByTagNameNS' => ['DOMNodeList', 'namespaceuri'=>'string|null', 'localname'=>'string'], - 'DOMElement::hasAttribute' => ['bool', 'name'=>'string'], - 'DOMElement::hasAttributeNS' => ['bool', 'namespaceuri'=>'string|null', 'localname'=>'string'], - 'DOMElement::removeAttribute' => ['bool', 'name'=>'string'], - 'DOMElement::removeAttributeNS' => ['bool', 'namespaceuri'=>'string|null', 'localname'=>'string'], - 'DOMElement::removeAttributeNode' => ['bool', 'oldnode'=>'DOMAttr'], - 'DOMElement::setAttribute' => ['DOMAttr|false', 'name'=>'string', 'value'=>'string'], - 'DOMElement::setAttributeNS' => ['void', 'namespaceuri'=>'string|null', 'qualifiedname'=>'string', 'value'=>'string'], + 'DOMElement::__construct' => ['void', 'qualifiedName'=>'string', 'value='=>'?string', 'namespace='=>'string'], + 'DOMElement::getAttribute' => ['string', 'qualifiedName'=>'string'], + 'DOMElement::getAttributeNS' => ['string', 'namespace'=>'string|null', 'localName'=>'string'], + 'DOMElement::getAttributeNode' => ['DOMAttr', 'qualifiedName'=>'string'], + 'DOMElement::getAttributeNodeNS' => ['DOMAttr', 'namespace'=>'string|null', 'localName'=>'string'], + 'DOMElement::getElementsByTagName' => ['DOMNodeList', 'qualifiedName'=>'string'], + 'DOMElement::getElementsByTagNameNS' => ['DOMNodeList', 'namespace'=>'string|null', 'localName'=>'string'], + 'DOMElement::hasAttribute' => ['bool', 'qualifiedName'=>'string'], + 'DOMElement::hasAttributeNS' => ['bool', 'namespace'=>'string|null', 'localName'=>'string'], + 'DOMElement::removeAttribute' => ['bool', 'qualifiedName'=>'string'], + 'DOMElement::removeAttributeNS' => ['void', 'namespace'=>'string|null', 'localName'=>'string'], + 'DOMElement::removeAttributeNode' => ['DOMAttr|false', 'attr'=>'DOMAttr'], + 'DOMElement::setAttribute' => ['DOMAttr|false', 'qualifiedName'=>'string', 'value'=>'string'], + 'DOMElement::setAttributeNS' => ['void', 'namespace'=>'string|null', 'qualifiedName'=>'string', 'value'=>'string'], 'DOMElement::setAttributeNode' => ['?DOMAttr', 'attr'=>'DOMAttr'], 'DOMElement::setAttributeNodeNS' => ['DOMAttr', 'attr'=>'DOMAttr'], - 'DOMElement::setIdAttribute' => ['void', 'name'=>'string', 'isid'=>'bool'], - 'DOMElement::setIdAttributeNS' => ['void', 'namespaceuri'=>'string', 'localname'=>'string', 'isid'=>'bool'], - 'DOMElement::setIdAttributeNode' => ['void', 'attr'=>'DOMAttr', 'isid'=>'bool'], + 'DOMElement::setIdAttribute' => ['void', 'qualifiedName'=>'string', 'isId'=>'bool'], + 'DOMElement::setIdAttributeNS' => ['void', 'namespace'=>'string', 'qualifiedName'=>'string', 'isId'=>'bool'], + 'DOMElement::setIdAttributeNode' => ['void', 'attr'=>'DOMAttr', 'isId'=>'bool'], 'DOMEntityReference::__construct' => ['void', 'name'=>'string'], 'DOMImplementation::__construct' => ['void'], - 'DOMImplementation::createDocument' => ['DOMDocument', 'namespaceuri='=>'string', 'qualifiedname='=>'string', 'doctype='=>'DOMDocumentType'], - 'DOMImplementation::createDocumentType' => ['DOMDocumentType', 'qualifiedname='=>'string', 'publicid='=>'string', 'systemid='=>'string'], + 'DOMImplementation::createDocument' => ['DOMDocument|false', 'namespace='=>'string', 'qualifiedName='=>'string', 'doctype='=>'DOMDocumentType'], + 'DOMImplementation::createDocumentType' => ['DOMDocumentType|false', 'qualifiedName'=>'string', 'publicId='=>'string', 'systemId='=>'string'], 'DOMImplementation::hasFeature' => ['bool', 'feature'=>'string', 'version'=>'string'], 'DOMNamedNodeMap::count' => ['int'], - 'DOMNamedNodeMap::getNamedItem' => ['?DOMNode', 'name'=>'string'], - 'DOMNamedNodeMap::getNamedItemNS' => ['?DOMNode', 'namespaceuri'=>'string', 'localname'=>'string'], + 'DOMNamedNodeMap::getNamedItem' => ['?DOMNode', 'qualifiedName'=>'string'], + 'DOMNamedNodeMap::getNamedItemNS' => ['?DOMNode', 'namespace'=>'?string', 'localName'=>'string'], 'DOMNamedNodeMap::item' => ['?DOMNode', 'index'=>'int'], - 'DOMNode::C14N' => ['string', 'exclusive='=>'bool', 'with_comments='=>'bool', 'xpath='=>'array', 'ns_prefixes='=>'array'], - 'DOMNode::C14NFile' => ['int|false', 'uri='=>'string', 'exclusive='=>'bool', 'with_comments='=>'bool', 'xpath='=>'array', 'ns_prefixes='=>'array'], - 'DOMNode::appendChild' => ['DOMNode', 'newnode'=>'DOMNode'], + 'DOMNode::C14N' => ['string|false', 'exclusive='=>'bool', 'withComments='=>'bool', 'xpath='=>'?array', 'nsPrefixes='=>'?array'], + 'DOMNode::C14NFile' => ['int|false', 'uri'=>'string', 'exclusive='=>'bool', 'withComments='=>'bool', 'xpath='=>'?array', 'nsPrefixes='=>'?array'], + 'DOMNode::appendChild' => ['DOMNode|false', 'node'=>'DOMNode'], 'DOMNode::cloneNode' => ['DOMNode', 'deep='=>'bool'], 'DOMNode::getLineNo' => ['int'], 'DOMNode::getNodePath' => ['?string'], 'DOMNode::hasAttributes' => ['bool'], 'DOMNode::hasChildNodes' => ['bool'], - 'DOMNode::insertBefore' => ['DOMNode', 'newnode'=>'DOMNode', 'refnode='=>'DOMNode|null'], - 'DOMNode::isDefaultNamespace' => ['bool', 'namespaceuri'=>'string'], - 'DOMNode::isSameNode' => ['bool', 'node'=>'DOMNode'], + 'DOMNode::insertBefore' => ['DOMNode|false', 'node'=>'DOMNode', 'child='=>'?DOMNode'], + 'DOMNode::isDefaultNamespace' => ['bool', 'namespace'=>'string'], + 'DOMNode::isSameNode' => ['bool', 'otherNode'=>'DOMNode'], 'DOMNode::isSupported' => ['bool', 'feature'=>'string', 'version'=>'string'], 'DOMNode::lookupNamespaceURI' => ['string|null', 'prefix'=>'string|null'], - 'DOMNode::lookupPrefix' => ['string|null', 'namespaceuri'=>'string'], + 'DOMNode::lookupPrefix' => ['string|null', 'namespace'=>'string'], 'DOMNode::normalize' => ['void'], - 'DOMNode::removeChild' => ['DOMNode', 'oldnode'=>'DOMNode'], - 'DOMNode::replaceChild' => ['DOMNode|false', 'newnode'=>'DOMNode', 'oldnode'=>'DOMNode'], + 'DOMNode::removeChild' => ['DOMNode|false', 'child'=>'DOMNode'], + 'DOMNode::replaceChild' => ['DOMNode|false', 'node'=>'DOMNode', 'child'=>'DOMNode'], 'DOMNodeList::item' => ['?DOMNode', 'index'=>'int'], - 'DOMProcessingInstruction::__construct' => ['void', 'name'=>'string', 'value'=>'string'], - 'DOMText::__construct' => ['void', 'value='=>'string'], + 'DOMProcessingInstruction::__construct' => ['void', 'name'=>'string', 'value='=>'string'], + 'DOMText::__construct' => ['void', 'data='=>'string'], 'DOMText::isElementContentWhitespace' => ['bool'], 'DOMText::isWhitespaceInElementContent' => ['bool'], 'DOMText::splitText' => ['DOMText', 'offset'=>'int'], - 'DOMXPath::__construct' => ['void', 'doc'=>'DOMDocument'], - 'DOMXPath::evaluate' => ['mixed', 'expression'=>'string', 'contextnode='=>'?DOMNode', 'registernodens='=>'bool'], - 'DOMXPath::query' => ['DOMNodeList|false', 'expression'=>'string', 'contextnode='=>'DOMNode|null', 'registernodens='=>'bool'], - 'DOMXPath::registerNamespace' => ['bool', 'prefix'=>'string', 'namespaceuri'=>'string'], - 'DOMXPath::registerPhpFunctions' => ['void', 'restrict='=>'mixed'], + 'DOMXPath::__construct' => ['void', 'document'=>'DOMDocument', 'registerNodeNS='=>'bool'], + 'DOMXPath::evaluate' => ['mixed', 'expression'=>'string', 'contextNode='=>'?DOMNode', 'registerNodeNS='=>'bool'], + 'DOMXPath::query' => ['DOMNodeList|false', 'expression'=>'string', 'contextNode='=>'?DOMNode', 'registerNodeNS='=>'bool'], + 'DOMXPath::registerNamespace' => ['bool', 'prefix'=>'string', 'namespace'=>'string'], + 'DOMXPath::registerPhpFunctions' => ['void', 'restrict='=>'array|string|null'], 'DOTNET::__call' => ['mixed', 'name'=>'string', 'args'=>''], 'DOTNET::__construct' => ['void', 'assembly_name'=>'string', 'datatype_name'=>'string', 'codepage='=>'int'], 'DOTNET::__get' => ['mixed', 'name'=>'string'], 'DOTNET::__set' => ['void', 'name'=>'string', 'value'=>''], - 'DateInterval::__construct' => ['void', 'spec'=>'string'], + 'DateInterval::__construct' => ['void', 'duration'=>'string'], 'DateInterval::__set_state' => ['DateInterval', 'array'=>'array'], 'DateInterval::__wakeup' => ['void'], - 'DateInterval::createFromDateString' => ['DateInterval|false', 'time'=>'string'], + 'DateInterval::createFromDateString' => ['DateInterval|false', 'datetime'=>'string'], 'DateInterval::format' => ['string', 'format'=>'string'], 'DatePeriod::__construct' => ['void', 'start'=>'DateTimeInterface', 'interval'=>'DateInterval', 'recur'=>'int', 'options='=>'int'], 'DatePeriod::__construct\'1' => ['void', 'start'=>'DateTimeInterface', 'interval'=>'DateInterval', 'end'=>'DateTimeInterface', 'options='=>'int'], @@ -827,18 +827,18 @@ return [ 'DateTime::__construct\'1' => ['void', 'time'=>'?string', 'timezone'=>'?DateTimeZone'], 'DateTime::__wakeup' => ['void'], 'DateTime::add' => ['static', 'interval'=>'DateInterval'], - 'DateTime::createFromFormat' => ['static|false', 'format'=>'string', 'time'=>'string', 'timezone='=>'?DateTimeZone'], - 'DateTime::diff' => ['DateInterval|false', 'datetime2'=>'DateTimeInterface', 'absolute='=>'bool'], + 'DateTime::createFromFormat' => ['static|false', 'format'=>'string', 'datetime'=>'string', 'timezone='=>'?DateTimeZone'], + 'DateTime::diff' => ['DateInterval', 'targetObject'=>'DateTimeInterface', 'absolute='=>'bool'], 'DateTime::format' => ['string|false', 'format'=>'string'], 'DateTime::getLastErrors' => ['array{warning_count:int,warnings:array,error_count:int,errors:array}|false'], 'DateTime::getOffset' => ['int'], 'DateTime::getTimestamp' => ['int|false'], 'DateTime::getTimezone' => ['DateTimeZone|false'], - 'DateTime::modify' => ['static|false', 'modify'=>'string'], + 'DateTime::modify' => ['static|false', 'modifier'=>'string'], 'DateTime::setDate' => ['static', 'year'=>'int', 'month'=>'int', 'day'=>'int'], - 'DateTime::setISODate' => ['static', 'year'=>'int', 'week'=>'int', 'day='=>'int'], - 'DateTime::setTime' => ['static|false', 'hour'=>'int', 'minute'=>'int', 'second='=>'int', 'microseconds='=>'int'], - 'DateTime::setTimestamp' => ['static', 'unixtimestamp'=>'int'], + 'DateTime::setISODate' => ['static', 'year'=>'int', 'week'=>'int', 'dayOfWeek='=>'int'], + 'DateTime::setTime' => ['static', 'hour'=>'int', 'minute'=>'int', 'second='=>'int', 'microsecond='=>'int'], + 'DateTime::setTimestamp' => ['static', 'timestamp'=>'int'], 'DateTime::setTimezone' => ['static', 'timezone'=>'DateTimeZone'], 'DateTime::sub' => ['static', 'interval'=>'DateInterval'], 'DateTimeImmutable::__wakeup' => ['void'], @@ -854,20 +854,20 @@ return [ 'DateTimeZone::getLocation' => ['array|false'], 'DateTimeZone::getName' => ['string'], 'DateTimeZone::getOffset' => ['int|false', 'datetime'=>'DateTimeInterface'], - 'DateTimeZone::getTransitions' => ['list|false', 'timestamp_begin='=>'int', 'timestamp_end='=>'int'], + 'DateTimeZone::getTransitions' => ['list|false', 'timestampBegin='=>'int', 'timestampEnd='=>'int'], 'DateTimeZone::listAbbreviations' => ['array>'], 'DateTimeZone::listIdentifiers' => ['list|false', 'timezoneGroup='=>'int', 'countryCode='=>'string'], 'Directory::close' => ['void', 'dir_handle='=>'resource'], 'Directory::read' => ['string|false', 'dir_handle='=>'resource'], 'Directory::rewind' => ['void', 'dir_handle='=>'resource'], - 'DirectoryIterator::__construct' => ['void', 'path'=>'string'], + 'DirectoryIterator::__construct' => ['void', 'directory'=>'string'], 'DirectoryIterator::__toString' => ['string'], 'DirectoryIterator::current' => ['DirectoryIterator'], 'DirectoryIterator::getATime' => ['int'], 'DirectoryIterator::getBasename' => ['string', 'suffix='=>'string'], 'DirectoryIterator::getCTime' => ['int'], 'DirectoryIterator::getExtension' => ['string'], - 'DirectoryIterator::getFileInfo' => ['SplFileInfo', 'class_name='=>'string'], + 'DirectoryIterator::getFileInfo' => ['SplFileInfo', 'class='=>'class-string'], 'DirectoryIterator::getFilename' => ['string'], 'DirectoryIterator::getGroup' => ['int'], 'DirectoryIterator::getInode' => ['int'], @@ -875,7 +875,7 @@ return [ 'DirectoryIterator::getMTime' => ['int'], 'DirectoryIterator::getOwner' => ['int'], 'DirectoryIterator::getPath' => ['string'], - 'DirectoryIterator::getPathInfo' => ['SplFileInfo', 'class_name='=>'string'], + 'DirectoryIterator::getPathInfo' => ['?SplFileInfo', 'class='=>'class-string'], 'DirectoryIterator::getPathname' => ['string'], 'DirectoryIterator::getPerms' => ['int'], 'DirectoryIterator::getRealPath' => ['string'], @@ -890,11 +890,11 @@ return [ 'DirectoryIterator::isWritable' => ['bool'], 'DirectoryIterator::key' => ['string'], 'DirectoryIterator::next' => ['void'], - 'DirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>'resource'], + 'DirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], 'DirectoryIterator::rewind' => ['void'], - 'DirectoryIterator::seek' => ['void', 'position'=>'int'], - 'DirectoryIterator::setFileClass' => ['void', 'class_name='=>'string'], - 'DirectoryIterator::setInfoClass' => ['void', 'class_name='=>'string'], + 'DirectoryIterator::seek' => ['void', 'offset'=>'int'], + 'DirectoryIterator::setFileClass' => ['void', 'class='=>'class-string'], + 'DirectoryIterator::setInfoClass' => ['void', 'class='=>'class-string'], 'DirectoryIterator::valid' => ['bool'], 'DomAttribute::name' => ['string'], 'DomAttribute::set_value' => ['bool', 'content'=>'string'], @@ -1489,14 +1489,14 @@ return [ 'FANNConnection::getToNeuron' => ['int'], 'FANNConnection::getWeight' => ['void'], 'FANNConnection::setWeight' => ['bool', 'weight'=>'float'], - 'FilesystemIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'], + 'FilesystemIterator::__construct' => ['void', 'directory'=>'string', 'flags='=>'int'], 'FilesystemIterator::__toString' => ['string'], 'FilesystemIterator::current' => ['SplFileInfo|FilesystemIterator|string'], 'FilesystemIterator::getATime' => ['int'], 'FilesystemIterator::getBasename' => ['string', 'suffix='=>'string'], 'FilesystemIterator::getCTime' => ['int'], 'FilesystemIterator::getExtension' => ['string'], - 'FilesystemIterator::getFileInfo' => ['SplFileInfo', 'class_name='=>'string'], + 'FilesystemIterator::getFileInfo' => ['SplFileInfo', 'class='=>'class-string'], 'FilesystemIterator::getFilename' => ['string'], 'FilesystemIterator::getFlags' => ['int'], 'FilesystemIterator::getGroup' => ['int'], @@ -1505,7 +1505,7 @@ return [ 'FilesystemIterator::getMTime' => ['int'], 'FilesystemIterator::getOwner' => ['int'], 'FilesystemIterator::getPath' => ['string'], - 'FilesystemIterator::getPathInfo' => ['SplFileInfo', 'class_name='=>'string'], + 'FilesystemIterator::getPathInfo' => ['?SplFileInfo', 'class='=>'class-string'], 'FilesystemIterator::getPathname' => ['string'], 'FilesystemIterator::getPerms' => ['int'], 'FilesystemIterator::getRealPath' => ['string'], @@ -1520,12 +1520,12 @@ return [ 'FilesystemIterator::isWritable' => ['bool'], 'FilesystemIterator::key' => ['string'], 'FilesystemIterator::next' => ['void'], - 'FilesystemIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>'resource'], + 'FilesystemIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], 'FilesystemIterator::rewind' => ['void'], - 'FilesystemIterator::seek' => ['void', 'position'=>'int'], - 'FilesystemIterator::setFileClass' => ['void', 'class_name='=>'string'], - 'FilesystemIterator::setFlags' => ['void', 'flags='=>'int'], - 'FilesystemIterator::setInfoClass' => ['void', 'class_name='=>'string'], + 'FilesystemIterator::seek' => ['void', 'offset'=>'int'], + 'FilesystemIterator::setFileClass' => ['void', 'class='=>'class-string'], + 'FilesystemIterator::setFlags' => ['void', 'flags'=>'int'], + 'FilesystemIterator::setInfoClass' => ['void', 'class='=>'class-string'], 'FilesystemIterator::valid' => ['bool'], 'FilterIterator::__construct' => ['void', 'iterator'=>'Iterator'], 'FilterIterator::accept' => ['bool'], @@ -1747,14 +1747,14 @@ return [ 'Generator::send' => ['mixed', 'value'=>'mixed'], 'Generator::throw' => ['mixed', 'exception'=>'Throwable'], 'Generator::valid' => ['bool'], - 'GlobIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'], + 'GlobIterator::__construct' => ['void', 'pattern'=>'string', 'flags='=>'int'], 'GlobIterator::count' => ['int'], 'GlobIterator::current' => ['FilesystemIterator|SplFileInfo|string'], 'GlobIterator::getATime' => ['int'], 'GlobIterator::getBasename' => ['string', 'suffix='=>'string'], 'GlobIterator::getCTime' => ['int'], 'GlobIterator::getExtension' => ['string'], - 'GlobIterator::getFileInfo' => ['SplFileInfo'], + 'GlobIterator::getFileInfo' => ['SplFileInfo', 'class='=>'class-string'], 'GlobIterator::getFilename' => ['string'], 'GlobIterator::getFlags' => ['int'], 'GlobIterator::getGroup' => ['int'], @@ -1763,7 +1763,7 @@ return [ 'GlobIterator::getMTime' => ['int'], 'GlobIterator::getOwner' => ['int'], 'GlobIterator::getPath' => ['string'], - 'GlobIterator::getPathInfo' => ['?SplFileInfo'], + 'GlobIterator::getPathInfo' => ['?SplFileInfo', 'class='=>'class-string'], 'GlobIterator::getPathname' => ['string'], 'GlobIterator::getPerms' => ['int'], 'GlobIterator::getRealPath' => ['string|false'], @@ -1778,12 +1778,12 @@ return [ 'GlobIterator::isWritable' => ['bool'], 'GlobIterator::key' => ['string'], 'GlobIterator::next' => ['void'], - 'GlobIterator::openFile' => ['SplFileObject'], + 'GlobIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], 'GlobIterator::rewind' => ['void'], - 'GlobIterator::seek' => ['void', 'position'=>'int'], - 'GlobIterator::setFileClass' => ['void'], - 'GlobIterator::setFlags' => ['void', 'flags='=>'int'], - 'GlobIterator::setInfoClass' => ['void'], + 'GlobIterator::seek' => ['void', 'offset'=>'int'], + 'GlobIterator::setFileClass' => ['void', 'class='=>'class-string'], + 'GlobIterator::setFlags' => ['void', 'flags'=>'int'], + 'GlobIterator::setInfoClass' => ['void', 'class='=>'class-string'], 'GlobIterator::valid' => ['bool'], 'Gmagick::__construct' => ['void', 'filename='=>'string'], 'Gmagick::addimage' => ['Gmagick', 'gmagick'=>'gmagick'], @@ -2974,8 +2974,8 @@ return [ 'IntlBreakIterator::following' => ['int', 'offset'=>'int'], 'IntlBreakIterator::getErrorCode' => ['int'], 'IntlBreakIterator::getErrorMessage' => ['string'], - 'IntlBreakIterator::getLocale' => ['string', 'locale_type'=>'string'], - 'IntlBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'key_type='=>'int'], + 'IntlBreakIterator::getLocale' => ['string|false', 'type'=>'int'], + 'IntlBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'type='=>'string'], 'IntlBreakIterator::getText' => ['?string'], 'IntlBreakIterator::isBoundary' => ['bool', 'offset'=>'int'], 'IntlBreakIterator::last' => ['int'], @@ -2984,14 +2984,14 @@ return [ 'IntlBreakIterator::previous' => ['int'], 'IntlBreakIterator::setText' => ['?bool', 'text'=>'string'], 'IntlCalendar::__construct' => ['void'], - 'IntlCalendar::add' => ['bool', 'field'=>'int', 'amount'=>'int'], + 'IntlCalendar::add' => ['bool', 'field'=>'int', 'value'=>'int'], 'IntlCalendar::after' => ['bool', 'other'=>'IntlCalendar'], 'IntlCalendar::before' => ['bool', 'other'=>'IntlCalendar'], 'IntlCalendar::clear' => ['bool', 'field='=>'?int'], - 'IntlCalendar::createInstance' => ['IntlCalendar', 'timeZone='=>'mixed', 'locale='=>'string'], + 'IntlCalendar::createInstance' => ['?IntlCalendar', 'timezone='=>'IntlTimeZone|DateTimeZone|string|null', 'locale='=>'?string'], 'IntlCalendar::equals' => ['bool', 'other'=>'IntlCalendar'], - 'IntlCalendar::fieldDifference' => ['int', 'when'=>'float', 'field'=>'int'], - 'IntlCalendar::fromDateTime' => ['IntlCalendar', 'dateTime'=>'DateTime|string'], + 'IntlCalendar::fieldDifference' => ['int|false', 'timestamp'=>'float', 'field'=>'int'], + 'IntlCalendar::fromDateTime' => ['?IntlCalendar', 'datetime'=>'DateTime|string', 'locale='=>'?string'], 'IntlCalendar::get' => ['int', 'field'=>'int'], 'IntlCalendar::getActualMaximum' => ['int', 'field'=>'int'], 'IntlCalendar::getActualMinimum' => ['int', 'field'=>'int'], @@ -3001,9 +3001,9 @@ return [ 'IntlCalendar::getErrorMessage' => ['string'], 'IntlCalendar::getFirstDayOfWeek' => ['int'], 'IntlCalendar::getGreatestMinimum' => ['int', 'field'=>'int'], - 'IntlCalendar::getKeywordValuesForLocale' => ['Iterator|false', 'key'=>'string', 'locale'=>'string', 'commonlyUsed'=>'bool'], + 'IntlCalendar::getKeywordValuesForLocale' => ['IntlIterator|false', 'keyword'=>'string', 'locale'=>'string', 'onlyCommon'=>'bool'], 'IntlCalendar::getLeastMaximum' => ['int', 'field'=>'int'], - 'IntlCalendar::getLocale' => ['string', 'localeType'=>'int'], + 'IntlCalendar::getLocale' => ['string|false', 'type'=>'int'], 'IntlCalendar::getMaximum' => ['int|false', 'field'=>'int'], 'IntlCalendar::getMinimalDaysInFirstWeek' => ['int'], 'IntlCalendar::getMinimum' => ['int', 'field'=>'int'], @@ -3013,82 +3013,82 @@ return [ 'IntlCalendar::getTime' => ['float'], 'IntlCalendar::getTimeZone' => ['IntlTimeZone'], 'IntlCalendar::getType' => ['string'], - 'IntlCalendar::getWeekendTransition' => ['int', 'dayOfWeek'=>'string'], + 'IntlCalendar::getWeekendTransition' => ['int|false', 'dayOfWeek'=>'int'], 'IntlCalendar::inDaylightTime' => ['bool'], 'IntlCalendar::isEquivalentTo' => ['bool', 'other'=>'IntlCalendar'], 'IntlCalendar::isLenient' => ['bool'], 'IntlCalendar::isSet' => ['bool', 'field'=>'int'], - 'IntlCalendar::isWeekend' => ['bool', 'date='=>'?float'], - 'IntlCalendar::roll' => ['bool', 'field'=>'int', 'amountOrUpOrDown'=>'mixed'], + 'IntlCalendar::isWeekend' => ['bool', 'timestamp='=>'?float'], + 'IntlCalendar::roll' => ['bool', 'field'=>'int', 'value'=>'int|bool'], 'IntlCalendar::set' => ['bool', 'field'=>'int', 'value'=>'int'], 'IntlCalendar::set\'1' => ['bool', 'year'=>'int', 'month'=>'int', 'dayOfMonth='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'], 'IntlCalendar::setFirstDayOfWeek' => ['bool', 'dayOfWeek'=>'int'], - 'IntlCalendar::setLenient' => ['bool', 'isLenient'=>'string'], - 'IntlCalendar::setMinimalDaysInFirstWeek' => ['bool', 'minimalDays'=>'int'], - 'IntlCalendar::setRepeatedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'], - 'IntlCalendar::setSkippedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'], - 'IntlCalendar::setTime' => ['bool', 'date'=>'float'], - 'IntlCalendar::setTimeZone' => ['bool', 'timeZone'=>'mixed'], + 'IntlCalendar::setLenient' => ['true', 'lenient'=>'bool'], + 'IntlCalendar::setMinimalDaysInFirstWeek' => ['bool', 'days'=>'int'], + 'IntlCalendar::setRepeatedWallTimeOption' => ['true', 'option'=>'int'], + 'IntlCalendar::setSkippedWallTimeOption' => ['true', 'option'=>'int'], + 'IntlCalendar::setTime' => ['bool', 'timestamp'=>'float'], + 'IntlCalendar::setTimeZone' => ['bool', 'timezone'=>'IntlTimeZone|DateTimeZone|string|null'], 'IntlCalendar::toDateTime' => ['DateTime|false'], - 'IntlChar::charAge' => ['array', 'char'=>'int|string'], - 'IntlChar::charDigitValue' => ['int', 'codepoint'=>'mixed'], - 'IntlChar::charDirection' => ['int', 'codepoint'=>'mixed'], - 'IntlChar::charFromName' => ['?int', 'name'=>'string', 'namechoice='=>'int'], - 'IntlChar::charMirror' => ['mixed', 'codepoint'=>'mixed'], - 'IntlChar::charName' => ['string', 'char'=>'int|string', 'namechoice='=>'int'], - 'IntlChar::charType' => ['int', 'codepoint'=>'mixed'], - 'IntlChar::chr' => ['string', 'codepoint'=>'mixed'], - 'IntlChar::digit' => ['int|false', 'char'=>'int|string', 'radix='=>'int'], - 'IntlChar::enumCharNames' => ['void', 'start'=>'mixed', 'limit'=>'mixed', 'callback'=>'callable', 'nameChoice='=>'int'], - 'IntlChar::enumCharTypes' => ['void', 'cb='=>'callable'], - 'IntlChar::foldCase' => ['int|string', 'char'=>'int|string', 'options='=>'int'], - 'IntlChar::forDigit' => ['int', 'digit'=>'int', 'radix'=>'int'], - 'IntlChar::getBidiPairedBracket' => ['mixed', 'codepoint'=>'mixed'], - 'IntlChar::getBlockCode' => ['int', 'char'=>'int|string'], - 'IntlChar::getCombiningClass' => ['int', 'codepoint'=>'mixed'], - 'IntlChar::getFC_NFKC_Closure' => ['string', 'char'=>'int|string'], + 'IntlChar::charAge' => ['?array', 'codepoint'=>'int|string'], + 'IntlChar::charDigitValue' => ['?int', 'codepoint'=>'int|string'], + 'IntlChar::charDirection' => ['?int', 'codepoint'=>'int|string'], + 'IntlChar::charFromName' => ['?int', 'name'=>'string', 'type='=>'int'], + 'IntlChar::charMirror' => ['int|string|null', 'codepoint'=>'int|string'], + 'IntlChar::charName' => ['?string', 'codepoint'=>'int|string', 'type='=>'int'], + 'IntlChar::charType' => ['?int', 'codepoint'=>'int|string'], + 'IntlChar::chr' => ['?string', 'codepoint'=>'int|string'], + 'IntlChar::digit' => ['int|false|null', 'codepoint'=>'int|string', 'base='=>'int'], + 'IntlChar::enumCharNames' => ['?bool', 'start'=>'string|int', 'end'=>'string|int', 'callback'=>'callable(int,int,int):void', 'type='=>'int'], + 'IntlChar::enumCharTypes' => ['void', 'callback'=>'callable(int,int,int):void'], + 'IntlChar::foldCase' => ['int|string|null', 'codepoint'=>'int|string', 'options='=>'int'], + 'IntlChar::forDigit' => ['int', 'digit'=>'int', 'base='=>'int'], + 'IntlChar::getBidiPairedBracket' => ['int|string|null', 'codepoint'=>'int|string'], + 'IntlChar::getBlockCode' => ['?int', 'codepoint'=>'int|string'], + 'IntlChar::getCombiningClass' => ['?int', 'codepoint'=>'int|string'], + 'IntlChar::getFC_NFKC_Closure' => ['?string', 'codepoint'=>'int|string'], 'IntlChar::getIntPropertyMaxValue' => ['int', 'property'=>'int'], 'IntlChar::getIntPropertyMinValue' => ['int', 'property'=>'int'], - 'IntlChar::getIntPropertyValue' => ['int', 'char'=>'int|string', 'property'=>'int'], - 'IntlChar::getNumericValue' => ['float', 'char'=>'int|string'], + 'IntlChar::getIntPropertyValue' => ['?int', 'codepoint'=>'int|string', 'property'=>'int'], + 'IntlChar::getNumericValue' => ['?float', 'codepoint'=>'int|string'], 'IntlChar::getPropertyEnum' => ['int', 'alias'=>'string'], - 'IntlChar::getPropertyName' => ['string|false', 'property'=>'int', 'namechoice='=>'int'], + 'IntlChar::getPropertyName' => ['string|false', 'property'=>'int', 'type='=>'int'], 'IntlChar::getPropertyValueEnum' => ['int', 'property'=>'int', 'name'=>'string'], - 'IntlChar::getPropertyValueName' => ['string|false', 'prop'=>'int', 'value'=>'int', 'namechoice='=>'int'], + 'IntlChar::getPropertyValueName' => ['string|false', 'property'=>'int', 'value'=>'int', 'type='=>'int'], 'IntlChar::getUnicodeVersion' => ['array'], - 'IntlChar::hasBinaryProperty' => ['bool', 'char'=>'int|string', 'property'=>'int'], - 'IntlChar::isIDIgnorable' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isIDPart' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isIDStart' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isISOControl' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isJavaIDPart' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isJavaIDStart' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isJavaSpaceChar' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isMirrored' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isUAlphabetic' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isULowercase' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isUUppercase' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isUWhiteSpace' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isWhitespace' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isalnum' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isalpha' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isbase' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isblank' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::iscntrl' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isdefined' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isdigit' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isgraph' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::islower' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isprint' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::ispunct' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isspace' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::istitle' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isupper' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::isxdigit' => ['bool', 'codepoint'=>'mixed'], - 'IntlChar::ord' => ['int', 'character'=>'mixed'], - 'IntlChar::tolower' => ['mixed', 'codepoint'=>'mixed'], - 'IntlChar::totitle' => ['mixed', 'codepoint'=>'mixed'], - 'IntlChar::toupper' => ['mixed', 'codepoint'=>'mixed'], + 'IntlChar::hasBinaryProperty' => ['?bool', 'codepoint'=>'int|string', 'property'=>'int'], + 'IntlChar::isIDIgnorable' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isIDPart' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isIDStart' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isISOControl' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isJavaIDPart' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isJavaIDStart' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isJavaSpaceChar' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isMirrored' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isUAlphabetic' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isULowercase' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isUUppercase' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isUWhiteSpace' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isWhitespace' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isalnum' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isalpha' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isbase' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isblank' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::iscntrl' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isdefined' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isdigit' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isgraph' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::islower' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isprint' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::ispunct' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isspace' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::istitle' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isupper' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::isxdigit' => ['?bool', 'codepoint'=>'int|string'], + 'IntlChar::ord' => ['?int', 'character'=>'int|string'], + 'IntlChar::tolower' => ['int|string|null', 'codepoint'=>'int|string'], + 'IntlChar::totitle' => ['int|string|null', 'codepoint'=>'int|string'], + 'IntlChar::toupper' => ['int|string|null', 'codepoint'=>'int|string'], 'IntlCodePointBreakIterator::__construct' => ['void'], 'IntlCodePointBreakIterator::createCharacterInstance' => ['?IntlRuleBasedBreakIterator', 'locale='=>'?string'], 'IntlCodePointBreakIterator::createCodePointInstance' => ['IntlCodePointBreakIterator'], @@ -3098,17 +3098,17 @@ return [ 'IntlCodePointBreakIterator::createWordInstance' => ['?IntlRuleBasedBreakIterator', 'locale='=>'?string'], 'IntlCodePointBreakIterator::current' => ['int'], 'IntlCodePointBreakIterator::first' => ['int'], - 'IntlCodePointBreakIterator::following' => ['int', 'offset'=>'string'], + 'IntlCodePointBreakIterator::following' => ['int', 'offset'=>'int'], 'IntlCodePointBreakIterator::getErrorCode' => ['int'], 'IntlCodePointBreakIterator::getErrorMessage' => ['string'], 'IntlCodePointBreakIterator::getLastCodePoint' => ['int'], - 'IntlCodePointBreakIterator::getLocale' => ['string', 'locale_type'=>'string'], - 'IntlCodePointBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'key_type='=>'string'], + 'IntlCodePointBreakIterator::getLocale' => ['string|false', 'type'=>'int'], + 'IntlCodePointBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'type='=>'string'], 'IntlCodePointBreakIterator::getText' => ['?string'], - 'IntlCodePointBreakIterator::isBoundary' => ['bool', 'offset'=>'string'], + 'IntlCodePointBreakIterator::isBoundary' => ['bool', 'offset'=>'int'], 'IntlCodePointBreakIterator::last' => ['int'], - 'IntlCodePointBreakIterator::next' => ['int', 'offset='=>'string'], - 'IntlCodePointBreakIterator::preceding' => ['int', 'offset'=>'string'], + 'IntlCodePointBreakIterator::next' => ['int', 'offset='=>'?int'], + 'IntlCodePointBreakIterator::preceding' => ['int', 'offset'=>'int'], 'IntlCodePointBreakIterator::previous' => ['int'], 'IntlCodePointBreakIterator::setText' => ['?bool', 'text'=>'string'], 'IntlDateFormatter::__construct' => ['void', 'locale'=>'?string', 'datetype'=>'null|int', 'timetype'=>'null|int', 'timezone='=>'IntlTimeZone|DateTimeZone|string|null', 'calendar='=>'IntlCalendar|int|null', 'pattern='=>'?string'], @@ -3133,7 +3133,7 @@ return [ 'IntlDateFormatter::setPattern' => ['bool', 'pattern'=>'string'], 'IntlDateFormatter::setTimeZone' => ['null|false', 'zone'=>'IntlTimeZone|DateTimeZone|string|null'], 'IntlException::__clone' => ['void'], - 'IntlException::__construct' => ['void'], + 'IntlException::__construct' => ['void', 'message='=>'string', 'code='=>'int', 'previous='=>'?Throwable'], 'IntlException::__toString' => ['string'], 'IntlException::__wakeup' => ['void'], 'IntlException::getCode' => ['int'], @@ -3144,14 +3144,14 @@ return [ 'IntlException::getTrace' => ['list\',args?:array}>'], 'IntlException::getTraceAsString' => ['string'], 'IntlGregorianCalendar::__construct' => ['void'], - 'IntlGregorianCalendar::add' => ['bool', 'field'=>'int', 'amount'=>'int'], + 'IntlGregorianCalendar::add' => ['bool', 'field'=>'int', 'value'=>'int'], 'IntlGregorianCalendar::after' => ['bool', 'other'=>'IntlCalendar'], 'IntlGregorianCalendar::before' => ['bool', 'other'=>'IntlCalendar'], 'IntlGregorianCalendar::clear' => ['bool', 'field='=>'?int'], - 'IntlGregorianCalendar::createInstance' => ['IntlGregorianCalendar', 'timeZone='=>'mixed', 'locale='=>'string'], + 'IntlGregorianCalendar::createInstance' => ['?IntlGregorianCalendar', 'timezone='=>'IntlTimeZone|DateTimeZone|string|null', 'locale='=>'?string'], 'IntlGregorianCalendar::equals' => ['bool', 'other'=>'IntlCalendar'], - 'IntlGregorianCalendar::fieldDifference' => ['int', 'when'=>'float', 'field'=>'int'], - 'IntlGregorianCalendar::fromDateTime' => ['IntlCalendar', 'dateTime'=>'DateTime|string'], + 'IntlGregorianCalendar::fieldDifference' => ['int|false', 'timestamp'=>'float', 'field'=>'int'], + 'IntlGregorianCalendar::fromDateTime' => ['?IntlCalendar', 'datetime'=>'DateTime|string', 'locale='=>'?string'], 'IntlGregorianCalendar::get' => ['int', 'field'=>'int'], 'IntlGregorianCalendar::getActualMaximum' => ['int', 'field'=>'int'], 'IntlGregorianCalendar::getActualMinimum' => ['int', 'field'=>'int'], @@ -3162,9 +3162,9 @@ return [ 'IntlGregorianCalendar::getFirstDayOfWeek' => ['int'], 'IntlGregorianCalendar::getGreatestMinimum' => ['int', 'field'=>'int'], 'IntlGregorianCalendar::getGregorianChange' => ['float'], - 'IntlGregorianCalendar::getKeywordValuesForLocale' => ['Iterator', 'key'=>'string', 'locale'=>'string', 'commonlyUsed'=>'bool'], + 'IntlGregorianCalendar::getKeywordValuesForLocale' => ['IntlIterator|false', 'keyword'=>'string', 'locale'=>'string', 'onlyCommon'=>'bool'], 'IntlGregorianCalendar::getLeastMaximum' => ['int', 'field'=>'int'], - 'IntlGregorianCalendar::getLocale' => ['string', 'localeType'=>'int'], + 'IntlGregorianCalendar::getLocale' => ['string|false', 'type'=>'int'], 'IntlGregorianCalendar::getMaximum' => ['int', 'field'=>'int'], 'IntlGregorianCalendar::getMinimalDaysInFirstWeek' => ['int'], 'IntlGregorianCalendar::getMinimum' => ['int', 'field'=>'int'], @@ -3174,24 +3174,24 @@ return [ 'IntlGregorianCalendar::getTime' => ['float'], 'IntlGregorianCalendar::getTimeZone' => ['IntlTimeZone'], 'IntlGregorianCalendar::getType' => ['string'], - 'IntlGregorianCalendar::getWeekendTransition' => ['int', 'dayOfWeek'=>'string'], + 'IntlGregorianCalendar::getWeekendTransition' => ['int|false', 'dayOfWeek'=>'int'], 'IntlGregorianCalendar::inDaylightTime' => ['bool'], 'IntlGregorianCalendar::isEquivalentTo' => ['bool', 'other'=>'IntlCalendar'], 'IntlGregorianCalendar::isLeapYear' => ['bool', 'year'=>'int'], 'IntlGregorianCalendar::isLenient' => ['bool'], 'IntlGregorianCalendar::isSet' => ['bool', 'field'=>'int'], - 'IntlGregorianCalendar::isWeekend' => ['bool', 'date='=>'float'], - 'IntlGregorianCalendar::roll' => ['bool', 'field'=>'int', 'amountOrUpOrDown'=>'mixed'], + 'IntlGregorianCalendar::isWeekend' => ['bool', 'timestamp='=>'?float'], + 'IntlGregorianCalendar::roll' => ['bool', 'field'=>'int', 'value'=>'int|bool'], 'IntlGregorianCalendar::set' => ['bool', 'field'=>'int', 'value'=>'int'], 'IntlGregorianCalendar::set\'1' => ['bool', 'year'=>'int', 'month'=>'int', 'dayOfMonth='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'], 'IntlGregorianCalendar::setFirstDayOfWeek' => ['bool', 'dayOfWeek'=>'int'], - 'IntlGregorianCalendar::setGregorianChange' => ['bool', 'date'=>'float'], - 'IntlGregorianCalendar::setLenient' => ['bool', 'isLenient'=>'string'], - 'IntlGregorianCalendar::setMinimalDaysInFirstWeek' => ['bool', 'minimalDays'=>'int'], - 'IntlGregorianCalendar::setRepeatedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'], - 'IntlGregorianCalendar::setSkippedWallTimeOption' => ['bool', 'wallTimeOption'=>'int'], - 'IntlGregorianCalendar::setTime' => ['bool', 'date'=>'float'], - 'IntlGregorianCalendar::setTimeZone' => ['bool', 'timeZone'=>'mixed'], + 'IntlGregorianCalendar::setGregorianChange' => ['bool', 'timestamp'=>'float'], + 'IntlGregorianCalendar::setLenient' => ['true', 'lenient'=>'bool'], + 'IntlGregorianCalendar::setMinimalDaysInFirstWeek' => ['bool', 'days'=>'int'], + 'IntlGregorianCalendar::setRepeatedWallTimeOption' => ['true', 'option'=>'int'], + 'IntlGregorianCalendar::setSkippedWallTimeOption' => ['true', 'option'=>'int'], + 'IntlGregorianCalendar::setTime' => ['bool', 'timestamp'=>'float'], + 'IntlGregorianCalendar::setTimeZone' => ['bool', 'timezone'=>'IntlTimeZone|DateTimeZone|string|null'], 'IntlGregorianCalendar::toDateTime' => ['DateTime'], 'IntlIterator::__construct' => ['void'], 'IntlIterator::current' => ['mixed'], @@ -3200,7 +3200,7 @@ return [ 'IntlIterator::rewind' => ['void'], 'IntlIterator::valid' => ['bool'], 'IntlPartsIterator::getBreakIterator' => ['IntlBreakIterator'], - 'IntlRuleBasedBreakIterator::__construct' => ['void', 'rules'=>'string', 'areCompiled='=>'string'], + 'IntlRuleBasedBreakIterator::__construct' => ['void', 'rules'=>'string', 'compiled='=>'bool'], 'IntlRuleBasedBreakIterator::createCharacterInstance' => ['?IntlRuleBasedBreakIterator', 'locale='=>'?string'], 'IntlRuleBasedBreakIterator::createCodePointInstance' => ['IntlCodePointBreakIterator'], 'IntlRuleBasedBreakIterator::createLineInstance' => ['?IntlRuleBasedBreakIterator', 'locale='=>'?string'], @@ -3213,8 +3213,8 @@ return [ 'IntlRuleBasedBreakIterator::getBinaryRules' => ['string'], 'IntlRuleBasedBreakIterator::getErrorCode' => ['int'], 'IntlRuleBasedBreakIterator::getErrorMessage' => ['string'], - 'IntlRuleBasedBreakIterator::getLocale' => ['string', 'locale_type'=>'string'], - 'IntlRuleBasedBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'key_type='=>'int'], + 'IntlRuleBasedBreakIterator::getLocale' => ['string|false', 'type'=>'int'], + 'IntlRuleBasedBreakIterator::getPartsIterator' => ['IntlPartsIterator', 'type='=>'string'], 'IntlRuleBasedBreakIterator::getRuleStatus' => ['int'], 'IntlRuleBasedBreakIterator::getRuleStatusVec' => ['array'], 'IntlRuleBasedBreakIterator::getRules' => ['string'], @@ -3225,28 +3225,28 @@ return [ 'IntlRuleBasedBreakIterator::preceding' => ['int', 'offset'=>'int'], 'IntlRuleBasedBreakIterator::previous' => ['int'], 'IntlRuleBasedBreakIterator::setText' => ['?bool', 'text'=>'string'], - 'IntlTimeZone::countEquivalentIDs' => ['int|false', 'zoneId'=>'string'], + 'IntlTimeZone::countEquivalentIDs' => ['int|false', 'timezoneId'=>'string'], 'IntlTimeZone::createDefault' => ['IntlTimeZone'], - 'IntlTimeZone::createEnumeration' => ['IntlIterator|false', 'countryOrRawOffset='=>'mixed'], - 'IntlTimeZone::createTimeZone' => ['IntlTimeZone|false', 'zoneId'=>'string'], - 'IntlTimeZone::createTimeZoneIDEnumeration' => ['IntlIterator|false', 'zoneType'=>'int', 'region='=>'string', 'rawOffset='=>'int'], - 'IntlTimeZone::fromDateTimeZone' => ['?IntlTimeZone', 'zoneId'=>'DateTimeZone'], - 'IntlTimeZone::getCanonicalID' => ['string|false', 'zoneId'=>'string', '&w_isSystemID='=>'bool'], + 'IntlTimeZone::createEnumeration' => ['IntlIterator|false', 'countryOrRawOffset='=>'IntlTimeZone|string|int|float|null'], + 'IntlTimeZone::createTimeZone' => ['?IntlTimeZone', 'timezoneId'=>'string'], + 'IntlTimeZone::createTimeZoneIDEnumeration' => ['IntlIterator|false', 'type'=>'int', 'region='=>'?string', 'rawOffset='=>'?int'], + 'IntlTimeZone::fromDateTimeZone' => ['?IntlTimeZone', 'timezone'=>'DateTimeZone'], + 'IntlTimeZone::getCanonicalID' => ['string|false', 'timezoneId'=>'string', '&w_isSystemId='=>'bool'], 'IntlTimeZone::getDSTSavings' => ['int'], - 'IntlTimeZone::getDisplayName' => ['string|false', 'isDaylight='=>'bool', 'style='=>'int', 'locale='=>'string'], - 'IntlTimeZone::getEquivalentID' => ['string|false', 'zoneId'=>'string', 'index'=>'int'], + 'IntlTimeZone::getDisplayName' => ['string|false', 'dst='=>'bool', 'style='=>'int', 'locale='=>'?string'], + 'IntlTimeZone::getEquivalentID' => ['string|false', 'timezoneId'=>'string', 'offset'=>'int'], 'IntlTimeZone::getErrorCode' => ['int'], 'IntlTimeZone::getErrorMessage' => ['string'], 'IntlTimeZone::getGMT' => ['IntlTimeZone'], 'IntlTimeZone::getID' => ['string'], - 'IntlTimeZone::getIDForWindowsID' => ['string', 'timezone'=>'string', 'region='=>'string'], - 'IntlTimeZone::getOffset' => ['int', 'date'=>'float', 'local'=>'bool', '&w_rawOffset'=>'int', '&w_dstOffset'=>'int'], + 'IntlTimeZone::getIDForWindowsID' => ['string|false', 'timezoneId'=>'string', 'region='=>'string'], + 'IntlTimeZone::getOffset' => ['bool', 'timestamp'=>'float', 'local'=>'bool', '&w_rawOffset'=>'int', '&w_dstOffset'=>'int'], 'IntlTimeZone::getRawOffset' => ['int'], - 'IntlTimeZone::getRegion' => ['string|false', 'zoneId'=>'string'], + 'IntlTimeZone::getRegion' => ['string|false', 'timezoneId'=>'string'], 'IntlTimeZone::getTZDataVersion' => ['string'], 'IntlTimeZone::getUnknown' => ['IntlTimeZone'], - 'IntlTimeZone::getWindowsID' => ['string|false', 'timezone'=>'string'], - 'IntlTimeZone::hasSameRules' => ['bool', 'otherTimeZone'=>'IntlTimeZone'], + 'IntlTimeZone::getWindowsID' => ['string|false', 'timezoneId'=>'string'], + 'IntlTimeZone::hasSameRules' => ['bool', 'other'=>'IntlTimeZone'], 'IntlTimeZone::toDateTimeZone' => ['DateTimeZone|false'], 'IntlTimeZone::useDaylightTime' => ['bool'], 'InvalidArgumentException::__clone' => ['void'], @@ -4763,7 +4763,7 @@ return [ 'PDOStatement::fetch' => ['mixed', 'how='=>'int', 'orientation='=>'int', 'offset='=>'int'], 'PDOStatement::fetchAll' => ['array|false', 'how='=>'int', 'fetch_argument='=>'int|string|callable', 'ctor_args='=>'?array'], 'PDOStatement::fetchColumn' => ['string|int|float|bool|null', 'column_number='=>'int'], - 'PDOStatement::fetchObject' => ['object|false', 'class='=>'?string', 'constructorArgs='=>'array'], + 'PDOStatement::fetchObject' => ['object|false', 'class='=>'?class-string', 'constructorArgs='=>'array'], 'PDOStatement::getAttribute' => ['mixed', 'name'=>'int'], 'PDOStatement::getColumnMeta' => ['array|false', 'column'=>'int'], 'PDOStatement::nextRowset' => ['bool'], @@ -4842,29 +4842,27 @@ return [ 'ParseError::getPrevious' => ['?Throwable'], 'ParseError::getTrace' => ['list\',args?:array}>'], 'ParseError::getTraceAsString' => ['string'], - 'Phar::__construct' => ['void', 'fname'=>'string', 'flags='=>'int', 'alias='=>'string'], - 'Phar::addEmptyDir' => ['void', 'dirname'=>'string'], - 'Phar::addFile' => ['void', 'file'=>'string', 'localname='=>'string'], - 'Phar::addFromString' => ['void', 'localname'=>'string', 'contents'=>'string'], + 'Phar::__construct' => ['void', 'filename'=>'string', 'flags='=>'int', 'alias='=>'?string'], + 'Phar::addEmptyDir' => ['void', 'directory'=>'string'], + 'Phar::addFile' => ['void', 'filename'=>'string', 'localName='=>'string'], + 'Phar::addFromString' => ['void', 'localName'=>'string', 'contents'=>'string'], 'Phar::apiVersion' => ['string'], - 'Phar::buildFromDirectory' => ['array', 'base_dir'=>'string', 'regex='=>'string'], - 'Phar::buildFromIterator' => ['array', 'iter'=>'Iterator', 'base_directory='=>'string'], - 'Phar::canCompress' => ['bool', 'method='=>'int'], + 'Phar::buildFromDirectory' => ['array|false', 'directory'=>'string', 'pattern='=>'string'], + 'Phar::buildFromIterator' => ['array|false', 'iterator'=>'Traversable', 'baseDirectory='=>'string'], + 'Phar::canCompress' => ['bool', 'compression='=>'int'], 'Phar::canWrite' => ['bool'], 'Phar::compress' => ['?Phar', 'compression'=>'int', 'extension='=>'string'], - 'Phar::compressAllFilesBZIP2' => ['bool'], - 'Phar::compressAllFilesGZ' => ['bool'], 'Phar::compressFiles' => ['void', 'compression'=>'int'], 'Phar::convertToData' => ['?PharData', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'], 'Phar::convertToExecutable' => ['?Phar', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'], - 'Phar::copy' => ['bool', 'oldfile'=>'string', 'newfile'=>'string'], - 'Phar::count' => ['int'], - 'Phar::createDefaultStub' => ['string', 'indexfile='=>'string', 'webindexfile='=>'string'], + 'Phar::copy' => ['bool', 'from'=>'string', 'to'=>'string'], + 'Phar::count' => ['int', 'mode='=>'int'], + 'Phar::createDefaultStub' => ['string', 'index='=>'string', 'webIndex='=>'string'], 'Phar::decompress' => ['?Phar', 'extension='=>'string'], 'Phar::decompressFiles' => ['bool'], 'Phar::delMetadata' => ['bool'], - 'Phar::delete' => ['bool', 'entry'=>'string'], - 'Phar::extractTo' => ['bool', 'pathto'=>'string', 'files='=>'string|array|null', 'overwrite='=>'bool'], + 'Phar::delete' => ['bool', 'localName'=>'string'], + 'Phar::extractTo' => ['bool', 'directory'=>'string', 'files='=>'string|array|null', 'overwrite='=>'bool'], 'Phar::getAlias' => ['?string'], 'Phar::getMetadata' => ['mixed'], 'Phar::getModified' => ['bool'], @@ -4882,50 +4880,51 @@ return [ 'Phar::isValidPharFilename' => ['bool', 'filename'=>'string', 'executable='=>'bool'], 'Phar::isWritable' => ['bool'], 'Phar::loadPhar' => ['bool', 'filename'=>'string', 'alias='=>'?string'], - 'Phar::mapPhar' => ['bool', 'alias='=>'string', 'dataoffset='=>'int'], - 'Phar::mount' => ['void', 'pharpath'=>'string', 'externalpath'=>'string'], - 'Phar::mungServer' => ['void', 'munglist'=>'array'], - 'Phar::offsetExists' => ['bool', 'offset'=>'string'], - 'Phar::offsetGet' => ['PharFileInfo', 'offset'=>'string'], - 'Phar::offsetSet' => ['void', 'offset'=>'string', 'value'=>'string'], - 'Phar::offsetUnset' => ['bool', 'offset'=>'string'], - 'Phar::running' => ['string', 'retphar='=>'bool'], + 'Phar::mapPhar' => ['bool', 'alias='=>'?string', 'offset='=>'int'], + 'Phar::mount' => ['void', 'pharPath'=>'string', 'externalPath'=>'string'], + 'Phar::mungServer' => ['void', 'variables'=>'list'], + 'Phar::offsetExists' => ['bool', 'localName'=>'string'], + 'Phar::offsetGet' => ['PharFileInfo', 'localName'=>'string'], + 'Phar::offsetSet' => ['void', 'localName'=>'string', 'value'=>'resource|string'], + 'Phar::offsetUnset' => ['void', 'localName'=>'string'], + 'Phar::running' => ['string', 'returnPhar='=>'bool'], 'Phar::setAlias' => ['bool', 'alias'=>'string'], - 'Phar::setDefaultStub' => ['bool', 'index='=>'string', 'webindex='=>'string'], + 'Phar::setDefaultStub' => ['bool', 'index='=>'?string', 'webIndex='=>'string'], 'Phar::setMetadata' => ['void', 'metadata'=>''], - 'Phar::setSignatureAlgorithm' => ['void', 'sigtype'=>'int', 'privatekey='=>'string'], + 'Phar::setSignatureAlgorithm' => ['void', 'algo'=>'int', 'privateKey='=>'string'], 'Phar::setStub' => ['bool', 'stub'=>'string', 'length='=>'int'], 'Phar::startBuffering' => ['void'], 'Phar::stopBuffering' => ['void'], - 'Phar::uncompressAllFiles' => ['bool'], - 'Phar::unlinkArchive' => ['bool', 'archive'=>'string'], - 'Phar::webPhar' => ['', 'alias='=>'string', 'index='=>'string', 'f404='=>'string', 'mimetypes='=>'array', 'rewrites='=>'array'], - 'PharData::__construct' => ['void', 'fname'=>'string', 'flags='=>'?int', 'alias='=>'?string', 'format='=>'int'], - 'PharData::addEmptyDir' => ['bool', 'dirname'=>'string'], - 'PharData::addFile' => ['void', 'file'=>'string', 'localname='=>'string'], - 'PharData::addFromString' => ['bool', 'localname'=>'string', 'contents'=>'string'], - 'PharData::buildFromDirectory' => ['array', 'base_dir'=>'string', 'regex='=>'string'], - 'PharData::buildFromIterator' => ['array', 'iter'=>'Iterator', 'base_directory='=>'string'], + 'Phar::unlinkArchive' => ['bool', 'filename'=>'string'], + 'Phar::webPhar' => ['void', 'alias='=>'?string', 'index='=>'?string', 'fileNotFoundScript='=>'string', 'mimeTypes='=>'array', 'rewrite='=>'callable'], + 'PharData::__construct' => ['void', 'filename'=>'string', 'flags='=>'int', 'alias='=>'?string', 'format='=>'int'], + 'PharData::addEmptyDir' => ['void', 'directory'=>'string'], + 'PharData::addFile' => ['void', 'filename'=>'string', 'localName='=>'string'], + 'PharData::addFromString' => ['void', 'localName'=>'string', 'contents'=>'string'], + 'PharData::buildFromDirectory' => ['array|false', 'directory'=>'string', 'pattern='=>'string'], + 'PharData::buildFromIterator' => ['array|false', 'iterator'=>'Traversable', 'baseDirectory='=>'string'], 'PharData::compress' => ['?PharData', 'compression'=>'int', 'extension='=>'string'], 'PharData::compressFiles' => ['void', 'compression'=>'int'], 'PharData::convertToData' => ['?PharData', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'], 'PharData::convertToExecutable' => ['?Phar', 'format='=>'int', 'compression='=>'int', 'extension='=>'string'], - 'PharData::copy' => ['bool', 'oldfile'=>'string', 'newfile'=>'string'], + 'PharData::copy' => ['bool', 'from'=>'string', 'to'=>'string'], 'PharData::decompress' => ['?PharData', 'extension='=>'string'], 'PharData::decompressFiles' => ['bool'], 'PharData::delMetadata' => ['bool'], - 'PharData::delete' => ['bool', 'entry'=>'string'], - 'PharData::extractTo' => ['bool', 'pathto'=>'string', 'files='=>'string|array|null', 'overwrite='=>'bool'], + 'PharData::delete' => ['bool', 'localName'=>'string'], + 'PharData::extractTo' => ['bool', 'directory'=>'string', 'files='=>'string|array|null', 'overwrite='=>'bool'], 'PharData::isWritable' => ['bool'], - 'PharData::offsetExists' => ['bool', 'offset'=>'string'], - 'PharData::offsetGet' => ['PharFileInfo', 'offset'=>'string'], - 'PharData::offsetSet' => ['void', 'offset'=>'string', 'value'=>'string'], - 'PharData::offsetUnset' => ['bool', 'offset'=>'string'], + 'PharData::offsetExists' => ['bool', 'localName'=>'string'], + 'PharData::offsetGet' => ['PharFileInfo', 'localName'=>'string'], + 'PharData::offsetSet' => ['void', 'localName'=>'string', 'value'=>'string'], + 'PharData::offsetUnset' => ['void', 'localName'=>'string'], 'PharData::setAlias' => ['bool', 'alias'=>'string'], - 'PharData::setDefaultStub' => ['bool', 'index='=>'string', 'webindex='=>'string'], + 'PharData::setDefaultStub' => ['bool', 'index='=>'?string', 'webIndex='=>'string'], + 'PharData::setMetadata' => ['void', 'metadata'=>'mixed'], + 'PharData::setSignatureAlgorithm' => ['void', 'algo'=>'int', 'privateKey='=>'string'], 'PharData::setStub' => ['bool', 'stub'=>'string', 'length='=>'int'], - 'PharFileInfo::__construct' => ['void', 'entry'=>'string'], - 'PharFileInfo::chmod' => ['void', 'permissions'=>'int'], + 'PharFileInfo::__construct' => ['void', 'filename'=>'string'], + 'PharFileInfo::chmod' => ['void', 'perms'=>'int'], 'PharFileInfo::compress' => ['bool', 'compression'=>'int'], 'PharFileInfo::decompress' => ['bool'], 'PharFileInfo::delMetadata' => ['bool'], @@ -4936,13 +4935,8 @@ return [ 'PharFileInfo::getPharFlags' => ['int'], 'PharFileInfo::hasMetadata' => ['bool'], 'PharFileInfo::isCRCChecked' => ['bool'], - 'PharFileInfo::isCompressed' => ['bool', 'compression_type='=>'int'], - 'PharFileInfo::isCompressedBZIP2' => ['bool'], - 'PharFileInfo::isCompressedGZ' => ['bool'], - 'PharFileInfo::setCompressedBZIP2' => ['bool'], - 'PharFileInfo::setCompressedGZ' => ['bool'], + 'PharFileInfo::isCompressed' => ['bool', 'compression='=>'int'], 'PharFileInfo::setMetadata' => ['void', 'metadata'=>'mixed'], - 'PharFileInfo::setUncompressed' => ['bool'], 'Pool::__construct' => ['void', 'size'=>'int', 'class'=>'string', 'ctor='=>'array'], 'Pool::collect' => ['int', 'collector='=>'Callable'], 'Pool::resize' => ['void', 'size'=>'int'], @@ -5137,7 +5131,7 @@ return [ 'RdKafka\TopicPartition::setTopic' => ['void', 'topic_name'=>'string'], 'RecursiveArrayIterator::__construct' => ['void', 'array='=>'array|object', 'flags='=>'int'], 'RecursiveArrayIterator::append' => ['void', 'value'=>'mixed'], - 'RecursiveArrayIterator::asort' => ['void'], + 'RecursiveArrayIterator::asort' => ['true', 'flags='=>'int'], 'RecursiveArrayIterator::count' => ['int'], 'RecursiveArrayIterator::current' => ['mixed'], 'RecursiveArrayIterator::getArrayCopy' => ['array'], @@ -5145,23 +5139,23 @@ return [ 'RecursiveArrayIterator::getFlags' => ['int'], 'RecursiveArrayIterator::hasChildren' => ['bool'], 'RecursiveArrayIterator::key' => ['string|int|null'], - 'RecursiveArrayIterator::ksort' => ['void'], + 'RecursiveArrayIterator::ksort' => ['true', 'flags='=>'int'], 'RecursiveArrayIterator::natcasesort' => ['true'], 'RecursiveArrayIterator::natsort' => ['true'], 'RecursiveArrayIterator::next' => ['void'], - 'RecursiveArrayIterator::offsetExists' => ['void', 'index'=>'string'], - 'RecursiveArrayIterator::offsetGet' => ['mixed', 'index'=>'string'], - 'RecursiveArrayIterator::offsetSet' => ['void', 'index'=>'string', 'newval'=>'string'], - 'RecursiveArrayIterator::offsetUnset' => ['void', 'index'=>'string'], + 'RecursiveArrayIterator::offsetExists' => ['bool', 'key'=>'string|int'], + 'RecursiveArrayIterator::offsetGet' => ['mixed', 'key'=>'string|int'], + 'RecursiveArrayIterator::offsetSet' => ['void', 'key'=>'string|int', 'value'=>'string'], + 'RecursiveArrayIterator::offsetUnset' => ['void', 'key'=>'string|int'], 'RecursiveArrayIterator::rewind' => ['void'], - 'RecursiveArrayIterator::seek' => ['void', 'position'=>'int'], + 'RecursiveArrayIterator::seek' => ['void', 'offset'=>'int'], 'RecursiveArrayIterator::serialize' => ['string'], - 'RecursiveArrayIterator::setFlags' => ['void', 'flags'=>'string'], - 'RecursiveArrayIterator::uasort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], - 'RecursiveArrayIterator::uksort' => ['void', 'cmp_function'=>'callable(mixed,mixed):int'], - 'RecursiveArrayIterator::unserialize' => ['string', 'serialized'=>'string'], + 'RecursiveArrayIterator::setFlags' => ['void', 'flags'=>'int'], + 'RecursiveArrayIterator::uasort' => ['true', 'callback'=>'callable(mixed,mixed):int'], + 'RecursiveArrayIterator::uksort' => ['true', 'callback'=>'callable(mixed,mixed):int'], + 'RecursiveArrayIterator::unserialize' => ['void', 'data'=>'string'], 'RecursiveArrayIterator::valid' => ['bool'], - 'RecursiveCachingIterator::__construct' => ['void', 'it'=>'Iterator', 'flags='=>'int'], + 'RecursiveCachingIterator::__construct' => ['void', 'iterator'=>'Iterator', 'flags='=>'int'], 'RecursiveCachingIterator::__toString' => ['string'], 'RecursiveCachingIterator::count' => ['int'], 'RecursiveCachingIterator::current' => ['void'], @@ -5173,14 +5167,14 @@ return [ 'RecursiveCachingIterator::hasNext' => ['bool'], 'RecursiveCachingIterator::key' => ['bool|float|int|string'], 'RecursiveCachingIterator::next' => ['void'], - 'RecursiveCachingIterator::offsetExists' => ['bool', 'index'=>'string'], - 'RecursiveCachingIterator::offsetGet' => ['string', 'index'=>'string'], - 'RecursiveCachingIterator::offsetSet' => ['void', 'index'=>'string', 'newval'=>'string'], - 'RecursiveCachingIterator::offsetUnset' => ['void', 'index'=>'string'], + 'RecursiveCachingIterator::offsetExists' => ['bool', 'key'=>'string'], + 'RecursiveCachingIterator::offsetGet' => ['string', 'key'=>'string'], + 'RecursiveCachingIterator::offsetSet' => ['void', 'key'=>'string', 'value'=>'string'], + 'RecursiveCachingIterator::offsetUnset' => ['void', 'key'=>'string'], 'RecursiveCachingIterator::rewind' => ['void'], 'RecursiveCachingIterator::setFlags' => ['void', 'flags'=>'int'], 'RecursiveCachingIterator::valid' => ['bool'], - 'RecursiveCallbackFilterIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator', 'func'=>'callable'], + 'RecursiveCallbackFilterIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator', 'callback'=>'callable(mixed,mixed=,mixed=):bool'], 'RecursiveCallbackFilterIterator::accept' => ['bool'], 'RecursiveCallbackFilterIterator::current' => ['mixed'], 'RecursiveCallbackFilterIterator::getChildren' => ['RecursiveCallbackFilterIterator'], @@ -5190,7 +5184,7 @@ return [ 'RecursiveCallbackFilterIterator::next' => ['void'], 'RecursiveCallbackFilterIterator::rewind' => ['void'], 'RecursiveCallbackFilterIterator::valid' => ['bool'], - 'RecursiveDirectoryIterator::__construct' => ['void', 'path'=>'string', 'flags='=>'int'], + 'RecursiveDirectoryIterator::__construct' => ['void', 'directory'=>'string', 'flags='=>'int'], 'RecursiveDirectoryIterator::__toString' => ['string'], 'RecursiveDirectoryIterator::current' => ['string|SplFileInfo|FilesystemIterator'], 'RecursiveDirectoryIterator::getATime' => ['int'], @@ -5198,7 +5192,7 @@ return [ 'RecursiveDirectoryIterator::getCTime' => ['int'], 'RecursiveDirectoryIterator::getChildren' => ['RecursiveDirectoryIterator'], 'RecursiveDirectoryIterator::getExtension' => ['string'], - 'RecursiveDirectoryIterator::getFileInfo' => ['SplFileInfo', 'class_name='=>'string'], + 'RecursiveDirectoryIterator::getFileInfo' => ['SplFileInfo', 'class='=>'class-string'], 'RecursiveDirectoryIterator::getFilename' => ['string'], 'RecursiveDirectoryIterator::getFlags' => ['int'], 'RecursiveDirectoryIterator::getGroup' => ['int'], @@ -5207,7 +5201,7 @@ return [ 'RecursiveDirectoryIterator::getMTime' => ['int'], 'RecursiveDirectoryIterator::getOwner' => ['int'], 'RecursiveDirectoryIterator::getPath' => ['string'], - 'RecursiveDirectoryIterator::getPathInfo' => ['SplFileInfo', 'class_name='=>'string'], + 'RecursiveDirectoryIterator::getPathInfo' => ['?SplFileInfo', 'class='=>'class-string'], 'RecursiveDirectoryIterator::getPathname' => ['string'], 'RecursiveDirectoryIterator::getPerms' => ['int'], 'RecursiveDirectoryIterator::getRealPath' => ['string'], @@ -5215,7 +5209,7 @@ return [ 'RecursiveDirectoryIterator::getSubPath' => ['string'], 'RecursiveDirectoryIterator::getSubPathname' => ['string'], 'RecursiveDirectoryIterator::getType' => ['string'], - 'RecursiveDirectoryIterator::hasChildren' => ['bool', 'allow_links='=>'bool'], + 'RecursiveDirectoryIterator::hasChildren' => ['bool', 'allowLinks='=>'bool'], 'RecursiveDirectoryIterator::isDir' => ['bool'], 'RecursiveDirectoryIterator::isDot' => ['bool'], 'RecursiveDirectoryIterator::isExecutable' => ['bool'], @@ -5225,12 +5219,12 @@ return [ 'RecursiveDirectoryIterator::isWritable' => ['bool'], 'RecursiveDirectoryIterator::key' => ['string'], 'RecursiveDirectoryIterator::next' => ['void'], - 'RecursiveDirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'use_include_path='=>'bool', 'context='=>'resource'], + 'RecursiveDirectoryIterator::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], 'RecursiveDirectoryIterator::rewind' => ['void'], - 'RecursiveDirectoryIterator::seek' => ['void', 'position'=>'int'], - 'RecursiveDirectoryIterator::setFileClass' => ['void', 'class_name='=>'string'], - 'RecursiveDirectoryIterator::setFlags' => ['void', 'flags='=>'int'], - 'RecursiveDirectoryIterator::setInfoClass' => ['void', 'class_name='=>'string'], + 'RecursiveDirectoryIterator::seek' => ['void', 'offset'=>'int'], + 'RecursiveDirectoryIterator::setFileClass' => ['void', 'class='=>'class-string'], + 'RecursiveDirectoryIterator::setFlags' => ['void', 'flags'=>'int'], + 'RecursiveDirectoryIterator::setInfoClass' => ['void', 'class='=>'class-string'], 'RecursiveDirectoryIterator::valid' => ['bool'], 'RecursiveFilterIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator'], 'RecursiveFilterIterator::accept' => ['bool'], @@ -5266,9 +5260,9 @@ return [ 'RecursiveIteratorIterator::next' => ['void'], 'RecursiveIteratorIterator::nextElement' => ['void'], 'RecursiveIteratorIterator::rewind' => ['void'], - 'RecursiveIteratorIterator::setMaxDepth' => ['void', 'max_depth='=>'int'], + 'RecursiveIteratorIterator::setMaxDepth' => ['void', 'maxDepth='=>'int'], 'RecursiveIteratorIterator::valid' => ['bool'], - 'RecursiveRegexIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator', 'regex'=>'string', 'mode='=>'int', 'flags='=>'int', 'preg_flags='=>'int'], + 'RecursiveRegexIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator', 'pattern'=>'string', 'mode='=>'int', 'flags='=>'int', 'pregFlags='=>'int'], 'RecursiveRegexIterator::accept' => ['bool'], 'RecursiveRegexIterator::current' => ['mixed'], 'RecursiveRegexIterator::getChildren' => ['RecursiveRegexIterator'], @@ -5281,11 +5275,11 @@ return [ 'RecursiveRegexIterator::key' => ['mixed'], 'RecursiveRegexIterator::next' => ['void'], 'RecursiveRegexIterator::rewind' => ['void'], - 'RecursiveRegexIterator::setFlags' => ['void', 'new_flags'=>'int'], - 'RecursiveRegexIterator::setMode' => ['void', 'new_mode'=>'int'], - 'RecursiveRegexIterator::setPregFlags' => ['void', 'new_flags'=>'int'], + 'RecursiveRegexIterator::setFlags' => ['void', 'flags'=>'int'], + 'RecursiveRegexIterator::setMode' => ['void', 'mode'=>'int'], + 'RecursiveRegexIterator::setPregFlags' => ['void', 'pregFlags'=>'int'], 'RecursiveRegexIterator::valid' => ['bool'], - 'RecursiveTreeIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator|IteratorAggregate', 'flags='=>'int', 'cit_flags='=>'int', 'mode'=>'int'], + 'RecursiveTreeIterator::__construct' => ['void', 'iterator'=>'RecursiveIterator|IteratorAggregate', 'flags='=>'int', 'cachingIteratorFlags='=>'int', 'mode='=>'int'], 'RecursiveTreeIterator::beginChildren' => ['void'], 'RecursiveTreeIterator::beginIteration' => ['void'], 'RecursiveTreeIterator::callGetChildren' => ['?RecursiveIterator'], @@ -5304,9 +5298,9 @@ return [ 'RecursiveTreeIterator::next' => ['void'], 'RecursiveTreeIterator::nextElement' => ['void'], 'RecursiveTreeIterator::rewind' => ['void'], - 'RecursiveTreeIterator::setMaxDepth' => ['void', 'max_depth='=>'int'], - 'RecursiveTreeIterator::setPostfix' => ['void', 'prefix'=>'string'], - 'RecursiveTreeIterator::setPrefixPart' => ['void', 'part'=>'int', 'prefix'=>'string'], + 'RecursiveTreeIterator::setMaxDepth' => ['void', 'maxDepth='=>'int'], + 'RecursiveTreeIterator::setPostfix' => ['void', 'postfix'=>'string'], + 'RecursiveTreeIterator::setPrefixPart' => ['void', 'part'=>'int', 'value'=>'string'], 'RecursiveTreeIterator::valid' => ['bool'], 'Redis::__construct' => ['void'], 'Redis::__destruct' => ['void'], @@ -6067,7 +6061,7 @@ return [ 'ReflectionZendExtension::getVersion' => ['string'], 'Reflector::__toString' => ['string'], 'Reflector::export' => ['?string'], - 'RegexIterator::__construct' => ['void', 'iterator'=>'Iterator', 'regex'=>'string', 'mode='=>'int', 'flags='=>'int', 'preg_flags='=>'int'], + 'RegexIterator::__construct' => ['void', 'iterator'=>'Iterator', 'pattern'=>'string', 'mode='=>'int', 'flags='=>'int', 'pregFlags='=>'int'], 'RegexIterator::accept' => ['bool'], 'RegexIterator::current' => ['mixed'], 'RegexIterator::getFlags' => ['int'], @@ -6078,9 +6072,9 @@ return [ 'RegexIterator::key' => ['mixed'], 'RegexIterator::next' => ['void'], 'RegexIterator::rewind' => ['void'], - 'RegexIterator::setFlags' => ['void', 'new_flags'=>'int'], - 'RegexIterator::setMode' => ['void', 'new_mode'=>'int'], - 'RegexIterator::setPregFlags' => ['void', 'new_flags'=>'int'], + 'RegexIterator::setFlags' => ['void', 'flags'=>'int'], + 'RegexIterator::setMode' => ['void', 'mode'=>'int'], + 'RegexIterator::setPregFlags' => ['void', 'pregFlags'=>'int'], 'RegexIterator::valid' => ['bool'], 'ResourceBundle::__construct' => ['void', 'locale'=>'string', 'bundlename'=>'string', 'fallback='=>'bool'], 'ResourceBundle::count' => ['int'], @@ -7494,7 +7488,7 @@ return [ 'SphinxClient::status' => ['array'], 'SphinxClient::updateAttributes' => ['int', 'index'=>'string', 'attributes'=>'array', 'values'=>'array', 'mva='=>'bool'], 'SplDoublyLinkedList::__construct' => ['void'], - 'SplDoublyLinkedList::add' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], + 'SplDoublyLinkedList::add' => ['void', 'index'=>'int', 'value'=>'mixed'], 'SplDoublyLinkedList::bottom' => ['mixed'], 'SplDoublyLinkedList::count' => ['int'], 'SplDoublyLinkedList::current' => ['mixed'], @@ -7504,17 +7498,17 @@ return [ 'SplDoublyLinkedList::next' => ['void'], 'SplDoublyLinkedList::offsetExists' => ['bool', 'index'=>'mixed'], 'SplDoublyLinkedList::offsetGet' => ['mixed', 'index'=>'mixed'], - 'SplDoublyLinkedList::offsetSet' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], + 'SplDoublyLinkedList::offsetSet' => ['void', 'index'=>'mixed', 'value'=>'mixed'], 'SplDoublyLinkedList::offsetUnset' => ['void', 'index'=>'mixed'], 'SplDoublyLinkedList::pop' => ['mixed'], 'SplDoublyLinkedList::prev' => ['void'], 'SplDoublyLinkedList::push' => ['void', 'value'=>'mixed'], 'SplDoublyLinkedList::rewind' => ['void'], 'SplDoublyLinkedList::serialize' => ['string'], - 'SplDoublyLinkedList::setIteratorMode' => ['void', 'flags'=>'int'], + 'SplDoublyLinkedList::setIteratorMode' => ['int', 'mode'=>'int'], 'SplDoublyLinkedList::shift' => ['mixed'], 'SplDoublyLinkedList::top' => ['mixed'], - 'SplDoublyLinkedList::unserialize' => ['void', 'serialized'=>'string'], + 'SplDoublyLinkedList::unserialize' => ['void', 'data'=>'string'], 'SplDoublyLinkedList::unshift' => ['void', 'value'=>'mixed'], 'SplDoublyLinkedList::valid' => ['bool'], 'SplEnum::__construct' => ['void', 'initial_value='=>'mixed', 'strict='=>'bool'], @@ -7526,7 +7520,7 @@ return [ 'SplFileInfo::getBasename' => ['string', 'suffix='=>'string'], 'SplFileInfo::getCTime' => ['int|false'], 'SplFileInfo::getExtension' => ['string'], - 'SplFileInfo::getFileInfo' => ['SplFileInfo', 'class='=>'string'], + 'SplFileInfo::getFileInfo' => ['SplFileInfo', 'class='=>'class-string'], 'SplFileInfo::getFilename' => ['string'], 'SplFileInfo::getGroup' => ['int|false'], 'SplFileInfo::getInode' => ['int|false'], @@ -7534,7 +7528,7 @@ return [ 'SplFileInfo::getMTime' => ['int|false'], 'SplFileInfo::getOwner' => ['int|false'], 'SplFileInfo::getPath' => ['string'], - 'SplFileInfo::getPathInfo' => ['SplFileInfo|null', 'class='=>'string'], + 'SplFileInfo::getPathInfo' => ['SplFileInfo|null', 'class='=>'class-string'], 'SplFileInfo::getPathname' => ['string'], 'SplFileInfo::getPerms' => ['int|false'], 'SplFileInfo::getRealPath' => ['string|false'], @@ -7547,8 +7541,8 @@ return [ 'SplFileInfo::isReadable' => ['bool'], 'SplFileInfo::isWritable' => ['bool'], 'SplFileInfo::openFile' => ['SplFileObject', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'resource'], - 'SplFileInfo::setFileClass' => ['void', 'class='=>'string'], - 'SplFileInfo::setInfoClass' => ['void', 'class='=>'string'], + 'SplFileInfo::setFileClass' => ['void', 'class='=>'class-string'], + 'SplFileInfo::setInfoClass' => ['void', 'class='=>'class-string'], 'SplFileObject::__construct' => ['void', 'filename'=>'string', 'mode='=>'string', 'useIncludePath='=>'bool', 'context='=>'?resource'], 'SplFileObject::__toString' => ['string'], 'SplFileObject::current' => ['string|array|false'], @@ -7575,7 +7569,7 @@ return [ 'SplFileObject::getCsvControl' => ['array'], 'SplFileObject::getCurrentLine' => ['string|false'], 'SplFileObject::getExtension' => ['string'], - 'SplFileObject::getFileInfo' => ['SplFileInfo', 'class='=>'string'], + 'SplFileObject::getFileInfo' => ['SplFileInfo', 'class='=>'class-string'], 'SplFileObject::getFilename' => ['string'], 'SplFileObject::getFlags' => ['int'], 'SplFileObject::getGroup' => ['int|false'], @@ -7585,7 +7579,7 @@ return [ 'SplFileObject::getMTime' => ['int|false'], 'SplFileObject::getOwner' => ['int|false'], 'SplFileObject::getPath' => ['string'], - 'SplFileObject::getPathInfo' => ['SplFileInfo|null', 'class='=>'string'], + 'SplFileObject::getPathInfo' => ['SplFileInfo|null', 'class='=>'class-string'], 'SplFileObject::getPathname' => ['string'], 'SplFileObject::getPerms' => ['int|false'], 'SplFileObject::getRealPath' => ['false|string'], @@ -7604,22 +7598,22 @@ return [ 'SplFileObject::rewind' => ['void'], 'SplFileObject::seek' => ['void', 'line'=>'int'], 'SplFileObject::setCsvControl' => ['void', 'separator='=>'string', 'enclosure='=>'string', 'escape='=>'string'], - 'SplFileObject::setFileClass' => ['void', 'class='=>'string'], + 'SplFileObject::setFileClass' => ['void', 'class='=>'class-string'], 'SplFileObject::setFlags' => ['void', 'flags'=>'int'], - 'SplFileObject::setInfoClass' => ['void', 'class='=>'string'], + 'SplFileObject::setInfoClass' => ['void', 'class='=>'class-string'], 'SplFileObject::setMaxLineLen' => ['void', 'maxLength'=>'int'], 'SplFileObject::valid' => ['bool'], 'SplFixedArray::__construct' => ['void', 'size='=>'int'], 'SplFixedArray::__wakeup' => ['void'], 'SplFixedArray::count' => ['int'], 'SplFixedArray::current' => ['mixed'], - 'SplFixedArray::fromArray' => ['SplFixedArray', 'data'=>'array', 'save_indexes='=>'bool'], + 'SplFixedArray::fromArray' => ['SplFixedArray', 'array'=>'array', 'preserveKeys='=>'bool'], 'SplFixedArray::getSize' => ['int'], 'SplFixedArray::key' => ['int'], 'SplFixedArray::next' => ['void'], 'SplFixedArray::offsetExists' => ['bool', 'index'=>'int'], 'SplFixedArray::offsetGet' => ['mixed', 'index'=>'int'], - 'SplFixedArray::offsetSet' => ['void', 'index'=>'int', 'newval'=>'mixed'], + 'SplFixedArray::offsetSet' => ['void', 'index'=>'int', 'value'=>'mixed'], 'SplFixedArray::offsetUnset' => ['void', 'index'=>'int'], 'SplFixedArray::rewind' => ['void'], 'SplFixedArray::setSize' => ['bool', 'size'=>'int'], @@ -7640,8 +7634,8 @@ return [ 'SplHeap::top' => ['mixed'], 'SplHeap::valid' => ['bool'], 'SplMaxHeap::__construct' => ['void'], - 'SplMaxHeap::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'], - 'SplMinHeap::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'], + 'SplMaxHeap::compare' => ['int', 'value1'=>'mixed', 'value2'=>'mixed'], + 'SplMinHeap::compare' => ['int', 'value1'=>'mixed', 'value2'=>'mixed'], 'SplMinHeap::count' => ['int'], 'SplMinHeap::current' => ['mixed'], 'SplMinHeap::extract' => ['mixed'], @@ -7655,10 +7649,10 @@ return [ 'SplMinHeap::top' => ['mixed'], 'SplMinHeap::valid' => ['bool'], 'SplObjectStorage::__construct' => ['void'], - 'SplObjectStorage::addAll' => ['void', 'os'=>'splobjectstorage'], - 'SplObjectStorage::attach' => ['void', 'object'=>'object', 'inf='=>'mixed'], + 'SplObjectStorage::addAll' => ['int', 'storage'=>'SplObjectStorage'], + 'SplObjectStorage::attach' => ['void', 'object'=>'object', 'info='=>'mixed'], 'SplObjectStorage::contains' => ['bool', 'object'=>'object'], - 'SplObjectStorage::count' => ['int'], + 'SplObjectStorage::count' => ['int', 'mode='=>'int'], 'SplObjectStorage::current' => ['object'], 'SplObjectStorage::detach' => ['void', 'object'=>'object'], 'SplObjectStorage::getHash' => ['string', 'object'=>'object'], @@ -7667,18 +7661,18 @@ return [ 'SplObjectStorage::next' => ['void'], 'SplObjectStorage::offsetExists' => ['bool', 'object'=>'object'], 'SplObjectStorage::offsetGet' => ['mixed', 'object'=>'object'], - 'SplObjectStorage::offsetSet' => ['object', 'object'=>'object', 'data='=>'mixed'], + 'SplObjectStorage::offsetSet' => ['void', 'object'=>'object', 'info='=>'mixed'], 'SplObjectStorage::offsetUnset' => ['void', 'object'=>'object'], - 'SplObjectStorage::removeAll' => ['void', 'os'=>'splobjectstorage'], - 'SplObjectStorage::removeAllExcept' => ['void', 'os'=>'splobjectstorage'], + 'SplObjectStorage::removeAll' => ['int', 'storage'=>'SplObjectStorage'], + 'SplObjectStorage::removeAllExcept' => ['int', 'storage'=>'SplObjectStorage'], 'SplObjectStorage::rewind' => ['void'], 'SplObjectStorage::serialize' => ['string'], - 'SplObjectStorage::setInfo' => ['void', 'inf'=>'mixed'], - 'SplObjectStorage::unserialize' => ['void', 'serialized'=>'string'], + 'SplObjectStorage::setInfo' => ['void', 'info'=>'mixed'], + 'SplObjectStorage::unserialize' => ['void', 'data'=>'string'], 'SplObjectStorage::valid' => ['bool'], 'SplObserver::update' => ['void', 'subject'=>'SplSubject'], 'SplPriorityQueue::__construct' => ['void'], - 'SplPriorityQueue::compare' => ['int', 'a'=>'mixed', 'b'=>'mixed'], + 'SplPriorityQueue::compare' => ['int', 'priority1'=>'mixed', 'priority2'=>'mixed'], 'SplPriorityQueue::count' => ['int'], 'SplPriorityQueue::current' => ['mixed'], 'SplPriorityQueue::extract' => ['mixed'], @@ -7700,7 +7694,7 @@ return [ 'SplQueue::next' => ['void'], 'SplQueue::offsetExists' => ['bool', 'index'=>'mixed'], 'SplQueue::offsetGet' => ['mixed', 'index'=>'mixed'], - 'SplQueue::offsetSet' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], + 'SplQueue::offsetSet' => ['void', 'index'=>'?int', 'value'=>'mixed'], 'SplQueue::offsetUnset' => ['void', 'index'=>'mixed'], 'SplQueue::pop' => ['mixed'], 'SplQueue::prev' => ['void'], @@ -7710,11 +7704,11 @@ return [ 'SplQueue::setIteratorMode' => ['int', 'mode'=>'int'], 'SplQueue::shift' => ['mixed'], 'SplQueue::top' => ['mixed'], - 'SplQueue::unserialize' => ['void', 'serialized'=>'string'], + 'SplQueue::unserialize' => ['void', 'data'=>'string'], 'SplQueue::unshift' => ['void', 'value'=>'mixed'], 'SplQueue::valid' => ['bool'], 'SplStack::__construct' => ['void'], - 'SplStack::add' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], + 'SplStack::add' => ['void', 'index'=>'int', 'value'=>'mixed'], 'SplStack::bottom' => ['mixed'], 'SplStack::count' => ['int'], 'SplStack::current' => ['mixed'], @@ -7724,7 +7718,7 @@ return [ 'SplStack::next' => ['void'], 'SplStack::offsetExists' => ['bool', 'index'=>'mixed'], 'SplStack::offsetGet' => ['mixed', 'index'=>'mixed'], - 'SplStack::offsetSet' => ['void', 'index'=>'mixed', 'newval'=>'mixed'], + 'SplStack::offsetSet' => ['void', 'index'=>'?int', 'value'=>'mixed'], 'SplStack::offsetUnset' => ['void', 'index'=>'mixed'], 'SplStack::pop' => ['mixed'], 'SplStack::prev' => ['void'], @@ -7734,7 +7728,7 @@ return [ 'SplStack::setIteratorMode' => ['int', 'mode'=>'int'], 'SplStack::shift' => ['mixed'], 'SplStack::top' => ['mixed'], - 'SplStack::unserialize' => ['void', 'serialized'=>'string'], + 'SplStack::unserialize' => ['void', 'data'=>'string'], 'SplStack::unshift' => ['void', 'value'=>'mixed'], 'SplStack::valid' => ['bool'], 'SplSubject::attach' => ['void', 'observer'=>'SplObserver'], @@ -7766,7 +7760,7 @@ return [ 'SplTempFileObject::getCsvControl' => ['array'], 'SplTempFileObject::getCurrentLine' => ['string'], 'SplTempFileObject::getExtension' => ['string'], - 'SplTempFileObject::getFileInfo' => ['SplFileInfo', 'class='=>'string'], + 'SplTempFileObject::getFileInfo' => ['SplFileInfo', 'class='=>'class-string'], 'SplTempFileObject::getFilename' => ['string'], 'SplTempFileObject::getFlags' => ['int'], 'SplTempFileObject::getGroup' => ['int|false'], @@ -7776,7 +7770,7 @@ return [ 'SplTempFileObject::getMTime' => ['int|false'], 'SplTempFileObject::getOwner' => ['int|false'], 'SplTempFileObject::getPath' => ['string'], - 'SplTempFileObject::getPathInfo' => ['SplFileInfo|null', 'class='=>'string'], + 'SplTempFileObject::getPathInfo' => ['SplFileInfo|null', 'class='=>'class-string'], 'SplTempFileObject::getPathname' => ['string'], 'SplTempFileObject::getPerms' => ['int|false'], 'SplTempFileObject::getRealPath' => ['false|string'], @@ -7795,9 +7789,9 @@ return [ 'SplTempFileObject::rewind' => ['void'], 'SplTempFileObject::seek' => ['void', 'line'=>'int'], 'SplTempFileObject::setCsvControl' => ['void', 'separator='=>'string', 'enclosure='=>'string', 'escape='=>'string'], - 'SplTempFileObject::setFileClass' => ['void', 'class='=>'string'], + 'SplTempFileObject::setFileClass' => ['void', 'class='=>'class-string'], 'SplTempFileObject::setFlags' => ['void', 'flags'=>'int'], - 'SplTempFileObject::setInfoClass' => ['void', 'class='=>'string'], + 'SplTempFileObject::setInfoClass' => ['void', 'class='=>'class-string'], 'SplTempFileObject::setMaxLineLen' => ['void', 'maxLength'=>'int'], 'SplTempFileObject::valid' => ['bool'], 'SplType::__construct' => ['void', 'initial_value='=>'mixed', 'strict='=>'bool'], @@ -9351,29 +9345,29 @@ return [ 'apd_set_session' => ['void', 'debug_level'=>'int'], 'apd_set_session_trace' => ['void', 'debug_level'=>'int', 'dump_directory='=>'string'], 'apd_set_session_trace_socket' => ['bool', 'tcp_server'=>'string', 'socket_type'=>'int', 'port'=>'int', 'debug_level'=>'int'], - 'array_change_key_case' => ['associative-array', 'array'=>'array', 'case='=>'int'], + 'array_change_key_case' => ['array', 'array'=>'array', 'case='=>'int'], 'array_chunk' => ['list', 'array'=>'array', 'length'=>'int', 'preserve_keys='=>'bool'], 'array_column' => ['array', 'array'=>'array', 'column_key'=>'mixed', 'index_key='=>'mixed'], - 'array_combine' => ['associative-array|false', 'keys'=>'string[]|int[]', 'values'=>'array'], - 'array_count_values' => ['associative-array', 'array'=>'array'], - 'array_diff' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'array_diff_assoc' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'array_diff_key' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'array_diff_uassoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int'], - 'array_diff_uassoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], - 'array_diff_ukey' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'key_comp_func'=>'callable(mixed,mixed):int'], - 'array_diff_ukey\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], + 'array_combine' => ['array|false', 'keys'=>'string[]|int[]', 'values'=>'array'], + 'array_count_values' => ['array', 'array'=>'array'], + 'array_diff' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'array_diff_assoc' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'array_diff_key' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'array_diff_uassoc' => ['array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int'], + 'array_diff_uassoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], + 'array_diff_ukey' => ['array', 'array'=>'array', 'rest'=>'array', 'key_comp_func'=>'callable(mixed,mixed):int'], + 'array_diff_ukey\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], 'array_fill' => ['array', 'start_index'=>'int', 'count'=>'int', 'value'=>'mixed'], 'array_fill_keys' => ['array', 'keys'=>'array', 'value'=>'mixed'], - 'array_filter' => ['associative-array', 'array'=>'array', 'callback='=>'callable(mixed,mixed=):scalar', 'mode='=>'int'], - 'array_flip' => ['associative-array|associative-array', 'array'=>'array'], - 'array_intersect' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'array_intersect_assoc' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'array_intersect_key' => ['associative-array', 'array'=>'array', '...arrays'=>'array'], - 'array_intersect_uassoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'key_compare_func'=>'callable(mixed,mixed):int'], - 'array_intersect_uassoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest'=>'array|callable(mixed,mixed):int'], - 'array_intersect_ukey' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'key_compare_func'=>'callable(mixed,mixed):int'], - 'array_intersect_ukey\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest'=>'array|callable(mixed,mixed):int'], + 'array_filter' => ['array', 'array'=>'array', 'callback='=>'callable(mixed,mixed=):scalar', 'mode='=>'int'], + 'array_flip' => ['array', 'array'=>'array'], + 'array_intersect' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'array_intersect_assoc' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'array_intersect_key' => ['array', 'array'=>'array', '...arrays'=>'array'], + 'array_intersect_uassoc' => ['array', 'array'=>'array', 'rest'=>'array', 'key_compare_func'=>'callable(mixed,mixed):int'], + 'array_intersect_uassoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest'=>'array|callable(mixed,mixed):int'], + 'array_intersect_ukey' => ['array', 'array'=>'array', 'rest'=>'array', 'key_compare_func'=>'callable(mixed,mixed):int'], + 'array_intersect_ukey\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest'=>'array|callable(mixed,mixed):int'], 'array_key_exists' => ['bool', 'key'=>'string|int', 'array'=>'array|object'], 'array_keys' => ['list', 'array'=>'array', 'filter_value='=>'mixed', 'strict='=>'bool'], 'array_map' => ['array', 'callback'=>'?callable', 'array'=>'array', '...arrays='=>'array'], @@ -9395,18 +9389,18 @@ return [ 'array_slice' => ['array', 'array'=>'array', 'offset'=>'int', 'length='=>'?int', 'preserve_keys='=>'bool'], 'array_splice' => ['array', '&rw_array'=>'array', 'offset'=>'int', 'length='=>'int', 'replacement='=>'array|string'], 'array_sum' => ['int|float', 'array'=>'array'], - 'array_udiff' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int'], - 'array_udiff\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], - 'array_udiff_assoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'key_comp_func'=>'callable(mixed,mixed):int'], - 'array_udiff_assoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], - 'array_udiff_uassoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int', 'key_comp_func'=>'callable(mixed,mixed):int'], - 'array_udiff_uassoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', 'arg5'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], - 'array_uintersect' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int'], - 'array_uintersect\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], - 'array_uintersect_assoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int'], - 'array_uintersect_assoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable(mixed,mixed):int'], - 'array_uintersect_uassoc' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int', 'key_compare_func'=>'callable(mixed,mixed):int'], - 'array_uintersect_uassoc\'1' => ['associative-array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', 'arg5'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], + 'array_udiff' => ['array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int'], + 'array_udiff\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], + 'array_udiff_assoc' => ['array', 'array'=>'array', 'rest'=>'array', 'key_comp_func'=>'callable(mixed,mixed):int'], + 'array_udiff_assoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], + 'array_udiff_uassoc' => ['array', 'array'=>'array', 'rest'=>'array', 'data_comp_func'=>'callable(mixed,mixed):int', 'key_comp_func'=>'callable(mixed,mixed):int'], + 'array_udiff_uassoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', 'arg5'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], + 'array_uintersect' => ['array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int'], + 'array_uintersect\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], + 'array_uintersect_assoc' => ['array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int'], + 'array_uintersect_assoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable', '...rest='=>'array|callable(mixed,mixed):int'], + 'array_uintersect_uassoc' => ['array', 'array'=>'array', 'rest'=>'array', 'data_compare_func'=>'callable(mixed,mixed):int', 'key_compare_func'=>'callable(mixed,mixed):int'], + 'array_uintersect_uassoc\'1' => ['array', 'array'=>'array', 'rest'=>'array', 'arr3'=>'array', 'arg4'=>'array|callable(mixed,mixed):int', 'arg5'=>'array|callable(mixed,mixed):int', '...rest='=>'array|callable(mixed,mixed):int'], 'array_unique' => ['array', 'array'=>'array', 'flags='=>'0'], 'array_unique\'1' => ['array', 'array'=>'array', 'flags='=>'1'], 'array_unique\'2' => ['array', 'array'=>'array', 'flags='=>'2|5'], @@ -9852,62 +9846,62 @@ return [ 'datefmt_set_lenient' => ['void', 'formatter'=>'IntlDateFormatter', 'lenient'=>'bool'], 'datefmt_set_pattern' => ['bool', 'formatter'=>'IntlDateFormatter', 'pattern'=>'string'], 'datefmt_set_timezone' => ['false|null', 'formatter'=>'IntlDateFormatter', 'timezone'=>'IntlTimeZone|DateTimeZone|string|null'], - 'db2_autocommit' => ['mixed', 'connection'=>'resource', 'value='=>'int'], + 'db2_autocommit' => ['0|1|bool', 'connection'=>'resource', 'value='=>'0|1'], 'db2_bind_param' => ['bool', 'stmt'=>'resource', 'parameter_number'=>'int', 'variable_name'=>'string', 'parameter_type='=>'int', 'data_type='=>'int', 'precision='=>'int', 'scale='=>'int'], - 'db2_client_info' => ['object|false', 'connection'=>'resource'], + 'db2_client_info' => ['stdClass|false', 'connection'=>'resource'], 'db2_close' => ['bool', 'connection'=>'resource'], - 'db2_column_privileges' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'column_name='=>'string'], - 'db2_columns' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'column_name='=>'string'], + 'db2_column_privileges' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'?string', 'schema='=>'?string', 'table_name='=>'?string', 'column_name='=>'?string'], + 'db2_columns' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'?string', 'schema='=>'?string', 'table_name='=>'?string', 'column_name='=>'?string'], 'db2_commit' => ['bool', 'connection'=>'resource'], 'db2_conn_error' => ['string', 'connection='=>'resource'], 'db2_conn_errormsg' => ['string', 'connection='=>'resource'], - 'db2_connect' => ['resource|false', 'database'=>'string', 'username'=>'string', 'password'=>'string', 'options='=>'array'], + 'db2_connect' => ['resource|false', 'database'=>'string', 'username'=>'?string', 'password'=>'?string', 'options='=>'array'], 'db2_cursor_type' => ['int', 'stmt'=>'resource'], 'db2_escape_string' => ['string', 'string_literal'=>'string'], 'db2_exec' => ['resource|false', 'connection'=>'resource', 'statement'=>'string', 'options='=>'array'], 'db2_execute' => ['bool', 'stmt'=>'resource', 'parameters='=>'array'], - 'db2_fetch_array' => ['array|false', 'stmt'=>'resource', 'row_number='=>'int'], - 'db2_fetch_assoc' => ['array|false', 'stmt'=>'resource', 'row_number='=>'int'], - 'db2_fetch_both' => ['array|false', 'stmt'=>'resource', 'row_number='=>'int'], - 'db2_fetch_object' => ['object|false', 'stmt'=>'resource', 'row_number='=>'int'], - 'db2_fetch_row' => ['bool', 'stmt'=>'resource', 'row_number='=>'int'], - 'db2_field_display_size' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], - 'db2_field_name' => ['string|false', 'stmt'=>'resource', 'column'=>'mixed'], - 'db2_field_num' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], - 'db2_field_precision' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], - 'db2_field_scale' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], - 'db2_field_type' => ['string|false', 'stmt'=>'resource', 'column'=>'mixed'], - 'db2_field_width' => ['int|false', 'stmt'=>'resource', 'column'=>'mixed'], - 'db2_foreign_keys' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string'], + 'db2_fetch_array' => ['array|false', 'stmt'=>'resource', 'row_number='=>'?int'], + 'db2_fetch_assoc' => ['array|false', 'stmt'=>'resource', 'row_number='=>'?int'], + 'db2_fetch_both' => ['array|false', 'stmt'=>'resource', 'row_number='=>'?int'], + 'db2_fetch_object' => ['stdClass|false', 'stmt'=>'resource', 'row_number='=>'?int'], + 'db2_fetch_row' => ['bool', 'stmt'=>'resource', 'row_number='=>'?int'], + 'db2_field_display_size' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], + 'db2_field_name' => ['string|false', 'stmt'=>'resource', 'column'=>'string|int'], + 'db2_field_num' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], + 'db2_field_precision' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], + 'db2_field_scale' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], + 'db2_field_type' => ['string|false', 'stmt'=>'resource', 'column'=>'string|int'], + 'db2_field_width' => ['int|false', 'stmt'=>'resource', 'column'=>'string|int'], + 'db2_foreign_keys' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'?string', 'table_name'=>'string'], 'db2_free_result' => ['bool', 'stmt'=>'resource'], 'db2_free_stmt' => ['bool', 'stmt'=>'resource'], 'db2_get_option' => ['string|false', 'resource'=>'resource', 'option'=>'string'], - 'db2_last_insert_id' => ['string', 'resource'=>'resource'], + 'db2_last_insert_id' => ['string|null', 'resource'=>'resource'], 'db2_lob_read' => ['string|false', 'stmt'=>'resource', 'colnum'=>'int', 'length'=>'int'], 'db2_next_result' => ['resource|false', 'stmt'=>'resource'], 'db2_num_fields' => ['int|false', 'stmt'=>'resource'], - 'db2_num_rows' => ['int', 'stmt'=>'resource'], + 'db2_num_rows' => ['int|false', 'stmt'=>'resource'], 'db2_pclose' => ['bool', 'resource'=>'resource'], - 'db2_pconnect' => ['resource|false', 'database'=>'string', 'username'=>'string', 'password'=>'string', 'options='=>'array'], + 'db2_pconnect' => ['resource|false', 'database'=>'string', 'username'=>'?string', 'password'=>'?string', 'options='=>'array'], 'db2_prepare' => ['resource|false', 'connection'=>'resource', 'statement'=>'string', 'options='=>'array'], - 'db2_primary_keys' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string'], + 'db2_primary_keys' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'?string', 'table_name'=>'string'], 'db2_primarykeys' => [''], - 'db2_procedure_columns' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'procedure'=>'string', 'parameter'=>'string'], + 'db2_procedure_columns' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'string', 'procedure'=>'string', 'parameter'=>'?string'], 'db2_procedurecolumns' => [''], - 'db2_procedures' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'procedure'=>'string'], - 'db2_result' => ['mixed', 'stmt'=>'resource', 'column'=>'mixed'], + 'db2_procedures' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'string', 'procedure'=>'string'], + 'db2_result' => ['mixed', 'stmt'=>'resource', 'column'=>'string|int'], 'db2_rollback' => ['bool', 'connection'=>'resource'], - 'db2_server_info' => ['object|false', 'connection'=>'resource'], + 'db2_server_info' => ['stdClass|false', 'connection'=>'resource'], 'db2_set_option' => ['bool', 'resource'=>'resource', 'options'=>'array', 'type'=>'int'], 'db2_setoption' => [''], - 'db2_special_columns' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string', 'scope'=>'int'], + 'db2_special_columns' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'string', 'table_name'=>'string', 'scope'=>'int'], 'db2_specialcolumns' => [''], - 'db2_statistics' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'string', 'schema'=>'string', 'table_name'=>'string', 'unique'=>'bool'], + 'db2_statistics' => ['resource|false', 'connection'=>'resource', 'qualifier'=>'?string', 'schema'=>'?string', 'table_name'=>'string', 'unique'=>'bool'], 'db2_stmt_error' => ['string', 'stmt='=>'resource'], 'db2_stmt_errormsg' => ['string', 'stmt='=>'resource'], - 'db2_table_privileges' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string'], + 'db2_table_privileges' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'?string', 'schema='=>'?string', 'table_name='=>'?string'], 'db2_tableprivileges' => [''], - 'db2_tables' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'string', 'schema='=>'string', 'table_name='=>'string', 'table_type='=>'string'], + 'db2_tables' => ['resource|false', 'connection'=>'resource', 'qualifier='=>'?string', 'schema='=>'?string', 'table_name='=>'?string', 'table_type='=>'?string'], 'dba_close' => ['void', 'dba'=>'resource'], 'dba_delete' => ['bool', 'key'=>'string', 'dba'=>'resource'], 'dba_exists' => ['bool', 'key'=>'string', 'dba'=>'resource'], @@ -11917,8 +11911,8 @@ return [ 'intlcal_clear' => ['bool', 'calendar'=>'IntlCalendar', 'field='=>'?int'], 'intlcal_create_instance' => ['?IntlCalendar', 'timezone='=>'mixed', 'locale='=>'?string'], 'intlcal_equals' => ['bool', 'calendar'=>'IntlCalendar', 'other'=>'IntlCalendar'], - 'intlcal_field_difference' => ['int', 'calendar'=>'IntlCalendar', 'timestamp'=>'float', 'field'=>'int'], - 'intlcal_from_date_time' => ['IntlCalendar', 'datetime'=>'DateTime|string'], + 'intlcal_field_difference' => ['int|false', 'calendar'=>'IntlCalendar', 'timestamp'=>'float', 'field'=>'int'], + 'intlcal_from_date_time' => ['?IntlCalendar', 'datetime'=>'DateTime|string', 'locale='=>'?string'], 'intlcal_get' => ['int|false', 'calendar'=>'IntlCalendar', 'field'=>'int'], 'intlcal_get_actual_maximum' => ['int', 'calendar'=>'IntlCalendar', 'field'=>'int'], 'intlcal_get_actual_minimum' => ['int', 'calendar'=>'IntlCalendar', 'field'=>'int'], @@ -11938,7 +11932,7 @@ return [ 'intlcal_get_time' => ['float', 'calendar'=>'IntlCalendar'], 'intlcal_get_time_zone' => ['IntlTimeZone', 'calendar'=>'IntlCalendar'], 'intlcal_get_type' => ['string', 'calendar'=>'IntlCalendar'], - 'intlcal_get_weekend_transition' => ['int', 'calendar'=>'IntlCalendar', 'dayOfWeek'=>'string'], + 'intlcal_get_weekend_transition' => ['int|false', 'calendar'=>'IntlCalendar', 'dayOfWeek'=>'int'], 'intlcal_in_daylight_time' => ['bool', 'calendar'=>'IntlCalendar'], 'intlcal_is_equivalent_to' => ['bool', 'calendar'=>'IntlCalendar', 'other'=>'IntlCalendar'], 'intlcal_is_lenient' => ['bool', 'calendar'=>'IntlCalendar'], @@ -11949,22 +11943,22 @@ return [ 'intlcal_set\'1' => ['bool', 'calendar'=>'IntlCalendar', 'year'=>'int', 'month'=>'int', 'dayOfMonth='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'], 'intlcal_set_first_day_of_week' => ['bool', 'calendar'=>'IntlCalendar', 'dayOfWeek'=>'int'], 'intlcal_set_lenient' => ['bool', 'calendar'=>'IntlCalendar', 'lenient'=>'bool'], - 'intlcal_set_repeated_wall_time_option' => ['bool', 'calendar'=>'IntlCalendar', 'option'=>'int'], - 'intlcal_set_skipped_wall_time_option' => ['bool', 'calendar'=>'IntlCalendar', 'option'=>'int'], + 'intlcal_set_repeated_wall_time_option' => ['true', 'calendar'=>'IntlCalendar', 'option'=>'int'], + 'intlcal_set_skipped_wall_time_option' => ['true', 'calendar'=>'IntlCalendar', 'option'=>'int'], 'intlcal_set_time' => ['bool', 'calendar'=>'IntlCalendar', 'timestamp'=>'float'], 'intlcal_set_time_zone' => ['bool', 'calendar'=>'IntlCalendar', 'timezone'=>'mixed'], 'intlcal_to_date_time' => ['DateTime|false', 'calendar'=>'IntlCalendar'], - 'intlgregcal_create_instance' => ['IntlGregorianCalendar', 'timezoneOrYear='=>'mixed', 'localeOrMonth='=>'string'], + 'intlgregcal_create_instance' => ['?IntlGregorianCalendar', 'timezoneOrYear='=>'IntlTimeZone|DateTimeZone|string|null', 'localeOrMonth='=>'string|int|null', 'day='=>'int', 'hour='=>'int', 'minute='=>'int', 'second='=>'int'], 'intlgregcal_get_gregorian_change' => ['float', 'calendar'=>'IntlGregorianCalendar'], - 'intlgregcal_is_leap_year' => ['bool', 'calendar'=>'int'], + 'intlgregcal_is_leap_year' => ['bool', 'calendar'=>'IntlGregorianCalendar', 'year'=>'int'], 'intlgregcal_set_gregorian_change' => ['bool', 'calendar'=>'IntlGregorianCalendar', 'timestamp'=>'float'], 'intltz_count_equivalent_ids' => ['int', 'timezoneId'=>'string'], - 'intltz_create_enumeration' => ['IntlIterator', 'countryOrRawOffset'=>'mixed'], + 'intltz_create_enumeration' => ['IntlIterator|false', 'countryOrRawOffset='=>'IntlTimeZone|string|int|float|null'], 'intltz_create_time_zone' => ['?IntlTimeZone', 'timezoneId'=>'string'], 'intltz_from_date_time_zone' => ['?IntlTimeZone', 'timezone'=>'DateTimeZone'], 'intltz_getGMT' => ['IntlTimeZone'], - 'intltz_get_canonical_id' => ['string', 'timezoneId'=>'string', '&isSystemId'=>'bool'], - 'intltz_get_display_name' => ['string', 'timezone'=>'IntlTimeZone', 'dst'=>'bool', 'style'=>'int', 'locale'=>'string'], + 'intltz_get_canonical_id' => ['string|false', 'timezoneId'=>'string', '&isSystemId='=>'bool'], + 'intltz_get_display_name' => ['string|false', 'timezone'=>'IntlTimeZone', 'dst='=>'bool', 'style='=>'int', 'locale='=>'?string'], 'intltz_get_dst_savings' => ['int', 'timezone'=>'IntlTimeZone'], 'intltz_get_equivalent_id' => ['string', 'timezoneId'=>'string', 'offset'=>'int'], 'intltz_get_error_code' => ['int', 'timezone'=>'IntlTimeZone'], @@ -12807,7 +12801,7 @@ return [ 'mysqli_fetch_field_direct' => ['object|false', 'result'=>'mysqli_result', 'index'=>'int'], 'mysqli_fetch_fields' => ['stdClass[]', 'result'=>'mysqli_result'], 'mysqli_fetch_lengths' => ['array|false', 'result'=>'mysqli_result'], - 'mysqli_fetch_object' => ['object|false|null', 'result'=>'mysqli_result', 'class='=>'class-string', 'constructor_args='=>'array'], + 'mysqli_fetch_object' => ['object|false|null', 'result'=>'mysqli_result', 'class='=>'string', 'constructor_args='=>'array'], 'mysqli_fetch_row' => ['list|false|null', 'result'=>'mysqli_result'], 'mysqli_field_count' => ['int', 'mysql'=>'mysqli'], 'mysqli_field_seek' => ['bool', 'result'=>'mysqli_result', 'index'=>'int'], @@ -12861,7 +12855,7 @@ return [ 'mysqli_result::fetch_field' => ['object|false'], 'mysqli_result::fetch_field_direct' => ['object|false', 'index'=>'int'], 'mysqli_result::fetch_fields' => ['stdClass[]'], - 'mysqli_result::fetch_object' => ['object|false|null', 'class='=>'class-string', 'constructor_args='=>'array'], + 'mysqli_result::fetch_object' => ['object|false|null', 'class='=>'string', 'constructor_args='=>'array'], 'mysqli_result::fetch_row' => ['list|false|null'], 'mysqli_result::field_seek' => ['bool', 'index'=>'int'], 'mysqli_result::free' => ['void'], @@ -13445,8 +13439,6 @@ return [ 'pg_untrace' => ['bool', 'connection='=>'resource'], 'pg_update' => ['string|bool', 'connection'=>'resource', 'table_name'=>'string', 'values'=>'array', 'conditions'=>'array', 'flags='=>'int'], 'pg_version' => ['array', 'connection='=>'resource'], - 'phardata::setMetadata' => ['void', 'metadata'=>'mixed'], - 'phardata::setSignatureAlgorithm' => ['void', 'sigtype'=>'int'], 'phdfs::__construct' => ['void', 'ip'=>'string', 'port'=>'string'], 'phdfs::__destruct' => ['void'], 'phdfs::connect' => ['bool'], @@ -14030,7 +14022,7 @@ return [ 'simplexml_load_string' => ['SimpleXMLElement|false', 'data'=>'string', 'class_name='=>'?string', 'options='=>'int', 'namespace_or_prefix='=>'string', 'is_prefix='=>'bool'], 'sin' => ['float', 'num'=>'float'], 'sinh' => ['float', 'num'=>'float'], - 'sizeof' => ['int', 'value'=>'Countable|array', 'mode='=>'int'], + 'sizeof' => ['int<0, max>', 'value'=>'Countable|array|SimpleXMLElement', 'mode='=>'int'], 'sleep' => ['int|false', 'seconds'=>'0|positive-int'], 'snmp2_get' => ['string|false', 'hostname'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'], 'snmp2_getnext' => ['string|false', 'hostname'=>'string', 'community'=>'string', 'object_id'=>'string', 'timeout='=>'int', 'retries='=>'int'], @@ -15292,7 +15284,7 @@ return [ 'uopz_get_hook\'1' => ['?Closure', 'function'=>'string'], 'uopz_get_mock' => ['string|object|null', 'class'=>'string'], 'uopz_get_property' => ['mixed', 'class'=>'object|string', 'property'=>'string'], - 'uopz_get_return' => ['mixed', 'class='=>'string', 'function='=>'string'], + 'uopz_get_return' => ['mixed', 'class='=>'class-string', 'function='=>'string'], 'uopz_get_static' => ['?array', 'class'=>'string', 'function'=>'string'], 'uopz_implement' => ['bool', 'class'=>'string', 'interface'=>'string'], 'uopz_overload' => ['void', 'opcode'=>'int', 'callable'=>'Callable'], @@ -15314,7 +15306,7 @@ return [ 'uopz_unset_hook' => ['bool', 'class'=>'string', 'function'=>'string'], 'uopz_unset_hook\'1' => ['bool', 'function'=>'string'], 'uopz_unset_mock' => ['void', 'class'=>'string'], - 'uopz_unset_return' => ['bool', 'class='=>'string', 'function='=>'string'], + 'uopz_unset_return' => ['bool', 'class='=>'class-string', 'function='=>'string'], 'uopz_unset_return\'1' => ['bool', 'function'=>'string'], 'urldecode' => ['string', 'string'=>'string'], 'urlencode' => ['string', 'string'=>'string'], diff --git a/vendor/vimeo/psalm/dictionaries/InternalTaintSinkMap.php b/vendor/vimeo/psalm/dictionaries/InternalTaintSinkMap.php index cb8c6077..57431299 100644 --- a/vendor/vimeo/psalm/dictionaries/InternalTaintSinkMap.php +++ b/vendor/vimeo/psalm/dictionaries/InternalTaintSinkMap.php @@ -5,7 +5,7 @@ use Psalm\Type\TaintKind; // This maps internal function names to sink types that we don’t want to end up there /** - * @var array>> + * @var non-empty-array>> */ return [ 'exec' => [['shell']], diff --git a/vendor/vimeo/psalm/docs/running_psalm/error_levels.md b/vendor/vimeo/psalm/docs/running_psalm/error_levels.md index 7c7bfa2a..55a18b8f 100644 --- a/vendor/vimeo/psalm/docs/running_psalm/error_levels.md +++ b/vendor/vimeo/psalm/docs/running_psalm/error_levels.md @@ -238,6 +238,7 @@ Level 5 and above allows a more non-verifiable code, and higher levels are even - [MissingPropertyType](issues/MissingPropertyType.md) - [MissingReturnType](issues/MissingReturnType.md) - [NullOperand](issues/NullOperand.md) +- [PrivateFinalMethod](issues/PrivateFinalMethod.md) - [PropertyNotSetInConstructor](issues/PropertyNotSetInConstructor.md) - [RawObjectIteration](issues/RawObjectIteration.md) - [RedundantConditionGivenDocblockType](issues/RedundantConditionGivenDocblockType.md) diff --git a/vendor/vimeo/psalm/docs/running_psalm/issues.md b/vendor/vimeo/psalm/docs/running_psalm/issues.md index 996db7fa..9eb35fce 100644 --- a/vendor/vimeo/psalm/docs/running_psalm/issues.md +++ b/vendor/vimeo/psalm/docs/running_psalm/issues.md @@ -211,6 +211,7 @@ - [PossiblyUnusedParam](issues/PossiblyUnusedParam.md) - [PossiblyUnusedProperty](issues/PossiblyUnusedProperty.md) - [PossiblyUnusedReturnValue](issues/PossiblyUnusedReturnValue.md) + - [PrivateFinalMethod](issues/PrivateFinalMethod.md) - [PropertyNotSetInConstructor](issues/PropertyNotSetInConstructor.md) - [PropertyTypeCoercion](issues/PropertyTypeCoercion.md) - [RawObjectIteration](issues/RawObjectIteration.md) diff --git a/vendor/vimeo/psalm/docs/running_psalm/issues/PrivateFinalMethod.md b/vendor/vimeo/psalm/docs/running_psalm/issues/PrivateFinalMethod.md new file mode 100644 index 00000000..1c55158a --- /dev/null +++ b/vendor/vimeo/psalm/docs/running_psalm/issues/PrivateFinalMethod.md @@ -0,0 +1,14 @@ +# PrivateFinalMethod + +Emitted when a class defines private final method. PHP 8.0+ emits a warning when it sees private final method (except `__construct` where it's allowed), and allows redefinition in child classes (effectively ignoring `final` modifier). Before PHP 8.0, `final` was respected in this case. + +```php + + * @var array */ public $php_extensions = [ - "apcu" => false, - "decimal" => false, - "dom" => false, - "ds" => false, - "ffi" => false, - "geos" => false, - "gmp" => false, - "mongodb" => false, - "mysqli" => false, - "pdo" => false, - "random" => false, - "redis" => false, - "simplexml" => false, - "soap" => false, - "xdebug" => false, + "apcu" => null, + "decimal" => null, + "dom" => null, + "ds" => null, + "ffi" => null, + "geos" => null, + "gmp" => null, + "ibm_db2" => null, + "mongodb" => null, + "mysqli" => null, + "pdo" => null, + "random" => null, + "redis" => null, + "simplexml" => null, + "soap" => null, + "xdebug" => null, ]; /** @@ -645,6 +650,7 @@ class Config 'gettext', 'gmp', 'hash', + 'ibm_db2', 'iconv', 'imap', 'intl', @@ -1113,7 +1119,7 @@ class Config } } foreach ($required_extensions as $required_ext => $_) { - if (isset($config->php_extensions[$required_ext])) { + if (array_key_exists($required_ext, $config->php_extensions)) { $config->php_extensions[$required_ext] = true; } else { $config->php_extensions_not_supported[$required_ext] = true; @@ -2240,7 +2246,8 @@ class Config foreach ($extensions_to_load_stubs_using_deprecated_way as $ext_name) { $ext_stub_path = $ext_stubs_dir . DIRECTORY_SEPARATOR . "$ext_name.phpstub"; $is_stub_already_loaded = in_array($ext_stub_path, $this->internal_stubs, true); - if (! $is_stub_already_loaded && extension_loaded($ext_name)) { + $is_ext_explicitly_disabled = ($this->php_extensions[$ext_name] ?? null) === false; + if (! $is_stub_already_loaded && ! $is_ext_explicitly_disabled && extension_loaded($ext_name)) { $this->internal_stubs[] = $ext_stub_path; $this->config_warnings[] = "Psalm 6 will not automatically load stubs for ext-$ext_name." . " You should explicitly enable or disable this ext in composer.json or Psalm config."; diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/ClassAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/ClassAnalyzer.php index 7108d136..137b4755 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/ClassAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/ClassAnalyzer.php @@ -2360,6 +2360,18 @@ class ClassAnalyzer extends ClassLikeAnalyzer ); } + if ($parent_class_storage->readonly && !$storage->readonly) { + IssueBuffer::maybeAdd( + new InvalidExtendClass( + 'Non-readonly class ' . $fq_class_name . ' may not inherit from ' + . 'readonly class ' . $parent_fq_class_name, + $code_location, + $fq_class_name, + ), + $storage->suppressed_issues + $this->getSuppressedIssues(), + ); + } + if ($parent_class_storage->deprecated) { IssueBuffer::maybeAdd( new DeprecatedClass( diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php index 37d53354..dd2a1074 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php @@ -127,6 +127,10 @@ class InterfaceAnalyzer extends ClassLikeAnalyzer $class_storage->suppressed_issues + $this->getSuppressedIssues(), ); + foreach ($class_storage->docblock_issues as $docblock_issue) { + IssueBuffer::maybeAdd($docblock_issue); + } + $member_stmts = []; foreach ($this->class->stmts as $stmt) { if ($stmt instanceof PhpParser\Node\Stmt\ClassMethod) { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Block/ForeachAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Block/ForeachAnalyzer.php index 6a643999..7baed128 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Block/ForeachAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Block/ForeachAnalyzer.php @@ -21,6 +21,7 @@ use Psalm\Internal\Analyzer\Statements\ExpressionAnalyzer; use Psalm\Internal\Analyzer\StatementsAnalyzer; use Psalm\Internal\FileManipulation\FileManipulationBuffer; use Psalm\Internal\Scope\LoopScope; +use Psalm\Internal\Type\AssertionReconciler; use Psalm\Internal\Type\Comparator\AtomicTypeComparator; use Psalm\Internal\Type\TypeExpander; use Psalm\Issue\ImpureMethodCall; @@ -36,6 +37,7 @@ use Psalm\Issue\UnnecessaryVarAnnotation; use Psalm\IssueBuffer; use Psalm\Node\Expr\VirtualMethodCall; use Psalm\Node\VirtualIdentifier; +use Psalm\Storage\Assertion; use Psalm\Type; use Psalm\Type\Atomic; use Psalm\Type\Atomic\Scalar; @@ -268,6 +270,19 @@ class ForeachAnalyzer $foreach_context->vars_in_scope[$context_var_id] = $context_type; } + if ($var_id && $foreach_context->hasVariable($var_id)) { + // refine the type of the array variable we iterate over + // if we entered loop body, the array cannot be empty + $foreach_context->vars_in_scope[$var_id] = AssertionReconciler::reconcile( + new Assertion\NonEmpty(), + $foreach_context->vars_in_scope[$var_id], + null, + $statements_analyzer, + true, // inside loop ? + $statements_analyzer->getTemplateTypeMap() ?? [], + ); + } + $foreach_context->inside_loop = true; $foreach_context->break_types[] = 'loop'; diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php index db33280a..0c0e30fc 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php @@ -33,7 +33,6 @@ use Psalm\Type\Atomic\TList; use Psalm\Type\Atomic\TLiteralClassString; use Psalm\Type\Atomic\TLiteralFloat; use Psalm\Type\Atomic\TLiteralInt; -use Psalm\Type\Atomic\TLiteralString; use Psalm\Type\Atomic\TMixed; use Psalm\Type\Atomic\TNonEmptyArray; use Psalm\Type\Atomic\TObjectWithProperties; @@ -536,7 +535,7 @@ class ArrayAnalyzer continue 2; } $new_offset = $key; - $array_creation_info->item_key_atomic_types[] = new TLiteralString($new_offset); + $array_creation_info->item_key_atomic_types[] = Type::getAtomicStringFromLiteral($new_offset); $array_creation_info->all_list = false; } else { $new_offset = $array_creation_info->int_offset++; diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/AssertionFinder.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/AssertionFinder.php index cd3d910a..3396deae 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/AssertionFinder.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/AssertionFinder.php @@ -1542,7 +1542,7 @@ class AssertionFinder ) { if ($conditional->left instanceof PhpParser\Node\Expr\FuncCall && $conditional->left->name instanceof PhpParser\Node\Name - && strtolower($conditional->left->name->parts[0]) === 'count' + && in_array(strtolower($conditional->left->name->parts[0]), ['count', 'sizeof']) && $conditional->left->getArgs() && ($conditional instanceof BinaryOp\Greater || $conditional instanceof BinaryOp\GreaterOrEqual) ) { @@ -1551,7 +1551,7 @@ class AssertionFinder $comparison_adjustment = $conditional instanceof BinaryOp\Greater ? 1 : 0; } elseif ($conditional->right instanceof PhpParser\Node\Expr\FuncCall && $conditional->right->name instanceof PhpParser\Node\Name - && strtolower($conditional->right->name->parts[0]) === 'count' + && in_array(strtolower($conditional->right->name->parts[0]), ['count', 'sizeof']) && $conditional->right->getArgs() && ($conditional instanceof BinaryOp\Smaller || $conditional instanceof BinaryOp\SmallerOrEqual) ) { @@ -1584,7 +1584,7 @@ class AssertionFinder ) { $left_count = $conditional->left instanceof PhpParser\Node\Expr\FuncCall && $conditional->left->name instanceof PhpParser\Node\Name - && strtolower($conditional->left->name->parts[0]) === 'count' + && in_array(strtolower($conditional->left->name->parts[0]), ['count', 'sizeof']) && $conditional->left->getArgs(); $operator_less_than_or_equal = @@ -1603,7 +1603,7 @@ class AssertionFinder $right_count = $conditional->right instanceof PhpParser\Node\Expr\FuncCall && $conditional->right->name instanceof PhpParser\Node\Name - && strtolower($conditional->right->name->parts[0]) === 'count' + && in_array(strtolower($conditional->right->name->parts[0]), ['count', 'sizeof']) && $conditional->right->getArgs(); $operator_greater_than_or_equal = @@ -1633,7 +1633,7 @@ class AssertionFinder ) { $left_count = $conditional->left instanceof PhpParser\Node\Expr\FuncCall && $conditional->left->name instanceof PhpParser\Node\Name - && strtolower($conditional->left->name->parts[0]) === 'count' + && in_array(strtolower($conditional->left->name->parts[0]), ['count', 'sizeof']) && $conditional->left->getArgs(); if ($left_count && $conditional->right instanceof PhpParser\Node\Scalar\LNumber) { @@ -1644,7 +1644,7 @@ class AssertionFinder $right_count = $conditional->right instanceof PhpParser\Node\Expr\FuncCall && $conditional->right->name instanceof PhpParser\Node\Name - && strtolower($conditional->right->name->parts[0]) === 'count' + && in_array(strtolower($conditional->right->name->parts[0]), ['count', 'sizeof']) && $conditional->right->getArgs(); if ($right_count && $conditional->left instanceof PhpParser\Node\Scalar\LNumber) { @@ -1785,7 +1785,7 @@ class AssertionFinder ) { $left_count = $conditional->left instanceof PhpParser\Node\Expr\FuncCall && $conditional->left->name instanceof PhpParser\Node\Name - && strtolower($conditional->left->name->parts[0]) === 'count'; + && in_array(strtolower($conditional->left->name->parts[0]), ['count', 'sizeof']); $right_number = $conditional->right instanceof PhpParser\Node\Scalar\LNumber && $conditional->right->value === ( @@ -1871,9 +1871,9 @@ class AssertionFinder return new IsType(new Atomic\TString()); case 'is_int': case 'is_integer': + case 'is_long': return new IsType(new Atomic\TInt()); case 'is_float': - case 'is_long': case 'is_double': case 'is_real': return new IsType(new Atomic\TFloat()); @@ -2044,7 +2044,8 @@ class AssertionFinder protected static function hasNonEmptyCountCheck(PhpParser\Node\Expr\FuncCall $stmt): bool { - return $stmt->name instanceof PhpParser\Node\Name && strtolower($stmt->name->parts[0]) === 'count'; + return $stmt->name instanceof PhpParser\Node\Name && + in_array(strtolower($stmt->name->parts[0]), ['count', 'sizeof']); } protected static function hasArrayKeyExistsCheck(PhpParser\Node\Expr\FuncCall $stmt): bool diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/ArrayAssignmentAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/ArrayAssignmentAnalyzer.php index 4f11f44c..c071a741 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/ArrayAssignmentAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/ArrayAssignmentAnalyzer.php @@ -170,7 +170,10 @@ class ArrayAssignmentAnalyzer $key_values = []; if ($current_dim instanceof PhpParser\Node\Scalar\String_) { - $key_values[] = new TLiteralString($current_dim->value); + $value_type = Type::getAtomicStringFromLiteral($current_dim->value); + if ($value_type instanceof TLiteralString) { + $key_values[] = $value_type; + } } elseif ($current_dim instanceof PhpParser\Node\Scalar\LNumber && !$root_is_string) { $key_values[] = new TLiteralInt($current_dim->value); } elseif ($current_dim @@ -330,7 +333,7 @@ class ArrayAssignmentAnalyzer $v = $type->value; $v[0] = $new_char; $changed = true; - $type = new TLiteralString($v); + $type = Type::getAtomicStringFromLiteral($v); break; } } @@ -511,11 +514,8 @@ class ArrayAssignmentAnalyzer $array_atomic_key_type = Type::getArrayKey(); } - if ($offset_already_existed - && $parent_var_id - && ($parent_type = $context->vars_in_scope[$parent_var_id] ?? null) - ) { - if ($parent_type->hasList() && strpos($parent_var_id, '[') === false) { + if ($parent_var_id && ($parent_type = $context->vars_in_scope[$parent_var_id] ?? null)) { + if ($offset_already_existed && $parent_type->hasList() && strpos($parent_var_id, '[') === false) { $array_atomic_type_list = $value_type; } elseif ($parent_type->hasClassStringMap() && $key_type @@ -1036,7 +1036,10 @@ class ArrayAssignmentAnalyzer $key_values = []; if ($dim instanceof PhpParser\Node\Scalar\String_) { - $key_values[] = new TLiteralString($dim->value); + $value_type = Type::getAtomicStringFromLiteral($dim->value); + if ($value_type instanceof TLiteralString) { + $key_values[] = $value_type; + } } elseif ($dim instanceof PhpParser\Node\Scalar\LNumber) { $key_values[] = new TLiteralInt($dim->value); } else { @@ -1077,7 +1080,10 @@ class ArrayAssignmentAnalyzer && $child_stmt_dim_type->isSingleStringLiteral()) ) { if ($child_stmt->dim instanceof PhpParser\Node\Scalar\String_) { - $offset_type = new TLiteralString($child_stmt->dim->value); + $offset_type = Type::getAtomicStringFromLiteral($child_stmt->dim->value); + if (!$offset_type instanceof TLiteralString) { + return [null, '[string]', false]; + } } else { $offset_type = $child_stmt_dim_type->getSingleStringLiteral(); } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ConcatAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ConcatAnalyzer.php index f4d35664..b90ffbc3 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ConcatAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ConcatAnalyzer.php @@ -34,6 +34,7 @@ use Psalm\Type\Atomic\TLowercaseString; use Psalm\Type\Atomic\TNamedObject; use Psalm\Type\Atomic\TNonEmptyNonspecificLiteralString; use Psalm\Type\Atomic\TNonEmptyString; +use Psalm\Type\Atomic\TNonFalsyString; use Psalm\Type\Atomic\TNonspecificLiteralString; use Psalm\Type\Atomic\TNull; use Psalm\Type\Atomic\TNumericString; @@ -173,7 +174,7 @@ class ConcatAnalyzer break 2; } - $result_type_parts[] = new TLiteralString($literal); + $result_type_parts[] = Type::getAtomicStringFromLiteral($literal); } } @@ -278,6 +279,31 @@ class ConcatAnalyzer } } } + } elseif ($left_type || $right_type) { + /** + * @var Union $known_operand + */ + $known_operand = $right_type ?? $left_type; + + if ($known_operand->isSingle()) { + $known_operands_atomic = $known_operand->getSingleAtomic(); + + if ($known_operands_atomic instanceof TNonEmptyString) { + $result_type = Type::getNonEmptyString(); + } + + if ($known_operands_atomic instanceof TNonFalsyString) { + $result_type = Type::getNonFalsyString(); + } + + if ($known_operands_atomic instanceof TLiteralString) { + if ($known_operands_atomic->value) { + $result_type = Type::getNonFalsyString(); + } elseif ($known_operands_atomic->value !== '') { + $result_type = Type::getNonEmptyString(); + } + } + } } } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/BitwiseNotAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/BitwiseNotAnalyzer.php index 00542cbb..3efa5c6c 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/BitwiseNotAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/BitwiseNotAnalyzer.php @@ -50,7 +50,7 @@ class BitwiseNotAnalyzer if ($type_part instanceof TLiteralInt) { $type_part = new TLiteralInt(~$type_part->value); } elseif ($type_part instanceof TLiteralString) { - $type_part = new TLiteralString(~$type_part->value); + $type_part = Type::getAtomicStringFromLiteral(~$type_part->value); } $acceptable_types[] = $type_part; diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallReturnTypeFetcher.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallReturnTypeFetcher.php index 6c40bf78..123437eb 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallReturnTypeFetcher.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallReturnTypeFetcher.php @@ -35,7 +35,6 @@ use Psalm\Type\Atomic\TIntRange; use Psalm\Type\Atomic\TKeyedArray; use Psalm\Type\Atomic\TList; use Psalm\Type\Atomic\TLiteralInt; -use Psalm\Type\Atomic\TLiteralString; use Psalm\Type\Atomic\TNamedObject; use Psalm\Type\Atomic\TNonEmptyArray; use Psalm\Type\Atomic\TNull; @@ -80,7 +79,7 @@ class FunctionCallReturnTypeFetcher if ($stmt->isFirstClassCallable()) { $candidate_callable = CallableTypeComparator::getCallableFromAtomic( $codebase, - new TLiteralString($function_id), + Type::getAtomicStringFromLiteral($function_id), null, $statements_analyzer, true, @@ -354,6 +353,7 @@ class FunctionCallReturnTypeFetcher } else { switch ($call_map_key) { case 'count': + case 'sizeof': if (($first_arg_type = $statements_analyzer->node_data->getType($call_args[0]->value))) { $atomic_types = $first_arg_type->getAtomicTypes(); diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NamedFunctionCallHandler.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NamedFunctionCallHandler.php index 39cf5dd9..874f0618 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NamedFunctionCallHandler.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NamedFunctionCallHandler.php @@ -35,7 +35,6 @@ use Psalm\Type\Atomic\TDependentGetDebugType; use Psalm\Type\Atomic\TDependentGetType; use Psalm\Type\Atomic\TFloat; use Psalm\Type\Atomic\TInt; -use Psalm\Type\Atomic\TLiteralString; use Psalm\Type\Atomic\TLowercaseString; use Psalm\Type\Atomic\TMixed; use Psalm\Type\Atomic\TNamedObject; @@ -625,17 +624,17 @@ class NamedFunctionCallHandler $class_string_types[] = new TClassString(); } else { if ($class_type instanceof TInt) { - $class_string_types[] = new TLiteralString('int'); + $class_string_types[] = Type::getAtomicStringFromLiteral('int'); } elseif ($class_type instanceof TString) { - $class_string_types[] = new TLiteralString('string'); + $class_string_types[] = Type::getAtomicStringFromLiteral('string'); } elseif ($class_type instanceof TFloat) { - $class_string_types[] = new TLiteralString('float'); + $class_string_types[] = Type::getAtomicStringFromLiteral('float'); } elseif ($class_type instanceof TBool) { - $class_string_types[] = new TLiteralString('bool'); + $class_string_types[] = Type::getAtomicStringFromLiteral('bool'); } elseif ($class_type instanceof TClosedResource) { - $class_string_types[] = new TLiteralString('resource (closed)'); + $class_string_types[] = Type::getAtomicStringFromLiteral('resource (closed)'); } elseif ($class_type instanceof TNull) { - $class_string_types[] = new TLiteralString('null'); + $class_string_types[] = Type::getAtomicStringFromLiteral('null'); } else { $class_string_types[] = new TString(); } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/CastAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/CastAnalyzer.php index 21d67fdb..83825307 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/CastAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/CastAnalyzer.php @@ -721,7 +721,7 @@ class CastAnalyzer || $atomic_type instanceof TNumeric ) { if ($atomic_type instanceof TLiteralInt || $atomic_type instanceof TLiteralFloat) { - $castable_types[] = new TLiteralString((string) $atomic_type->value); + $castable_types[] = Type::getAtomicStringFromLiteral((string) $atomic_type->value); } elseif ($atomic_type instanceof TNonspecificLiteralInt) { $castable_types[] = new TNonspecificLiteralString(); } else { @@ -740,20 +740,20 @@ class CastAnalyzer if ($atomic_type instanceof TNull || $atomic_type instanceof TFalse ) { - $valid_strings[] = new TLiteralString(''); + $valid_strings[] = Type::getAtomicStringFromLiteral(''); continue; } if ($atomic_type instanceof TTrue ) { - $valid_strings[] = new TLiteralString('1'); + $valid_strings[] = Type::getAtomicStringFromLiteral('1'); continue; } if ($atomic_type instanceof TBool ) { - $valid_strings[] = new TLiteralString('1'); - $valid_strings[] = new TLiteralString(''); + $valid_strings[] = Type::getAtomicStringFromLiteral('1'); + $valid_strings[] = Type::getAtomicStringFromLiteral(''); continue; } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/EncapsulatedStringAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/EncapsulatedStringAnalyzer.php index 0bf09dcd..9792a91c 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/EncapsulatedStringAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/EncapsulatedStringAnalyzer.php @@ -10,6 +10,7 @@ use Psalm\Internal\Analyzer\Statements\ExpressionAnalyzer; use Psalm\Internal\Analyzer\StatementsAnalyzer; use Psalm\Internal\DataFlow\DataFlowNode; use Psalm\Plugin\EventHandler\Event\AddRemoveTaintsEvent; +use Psalm\Type; use Psalm\Type\Atomic\TLiteralFloat; use Psalm\Type\Atomic\TLiteralInt; use Psalm\Type\Atomic\TLiteralString; @@ -123,7 +124,7 @@ class EncapsulatedStringAnalyzer if ($non_empty) { if ($literal_string !== null) { $stmt_type = new Union( - [new TLiteralString($literal_string)], + [Type::getAtomicStringFromLiteral($literal_string)], ['parent_nodes' => $parent_nodes], ); } elseif ($all_literals) { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ArrayFetchAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ArrayFetchAnalyzer.php index b252981f..2567ca86 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ArrayFetchAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ArrayFetchAnalyzer.php @@ -481,7 +481,10 @@ class ArrayFetchAnalyzer $key_values = []; if ($stmt->dim instanceof PhpParser\Node\Scalar\String_) { - $key_values[] = new TLiteralString($stmt->dim->value); + $value_type = Type::getAtomicStringFromLiteral($stmt->dim->value); + if ($value_type instanceof TLiteralString) { + $key_values[] = $value_type; + } } elseif ($stmt->dim instanceof PhpParser\Node\Scalar\LNumber) { $key_values[] = new TLiteralInt($stmt->dim->value); } elseif ($stmt->dim && ($stmt_dim_type = $statements_analyzer->node_data->getType($stmt->dim))) { @@ -514,7 +517,7 @@ class ArrayFetchAnalyzer if ($in_assignment) { $offset_type->removeType('null'); - $offset_type->addType(new TLiteralString('')); + $offset_type->addType(Type::getAtomicStringFromLiteral('')); } } @@ -534,7 +537,7 @@ class ArrayFetchAnalyzer $offset_type->removeType('null'); if (!$offset_type->ignore_nullable_issues) { - $offset_type->addType(new TLiteralString('')); + $offset_type->addType(Type::getAtomicStringFromLiteral('')); } } } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/AtomicPropertyFetchAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/AtomicPropertyFetchAnalyzer.php index 9b3352c6..585d7ca1 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/AtomicPropertyFetchAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/AtomicPropertyFetchAnalyzer.php @@ -52,7 +52,6 @@ use Psalm\Type\Atomic\TFalse; use Psalm\Type\Atomic\TGenericObject; use Psalm\Type\Atomic\TInt; use Psalm\Type\Atomic\TLiteralInt; -use Psalm\Type\Atomic\TLiteralString; use Psalm\Type\Atomic\TMixed; use Psalm\Type\Atomic\TNamedObject; use Psalm\Type\Atomic\TNull; @@ -935,7 +934,7 @@ class AtomicPropertyFetchAnalyzer if ($lhs_type_part instanceof TEnumCase) { $statements_analyzer->node_data->setType( $stmt, - new Union([new TLiteralString($lhs_type_part->case_name)]), + new Union([Type::getAtomicStringFromLiteral($lhs_type_part->case_name)]), ); } else { $statements_analyzer->node_data->setType($stmt, Type::getNonEmptyString()); @@ -971,7 +970,7 @@ class AtomicPropertyFetchAnalyzer foreach ($enum_cases as $enum_case) { if (is_string($enum_case->value)) { - $case_values[] = new TLiteralString($enum_case->value); + $case_values[] = Type::getAtomicStringFromLiteral($enum_case->value); } elseif (is_int($enum_case->value)) { $case_values[] = new TLiteralInt($enum_case->value); } else { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/VariableFetchAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/VariableFetchAnalyzer.php index fef2f892..98e911a0 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/VariableFetchAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/VariableFetchAnalyzer.php @@ -321,11 +321,9 @@ class VariableFetchAnalyzer (bool) $statements_analyzer->getBranchPoint($var_name), ); } else { - if ($codebase->alter_code) { - if (!isset($project_analyzer->getIssuesToFix()['PossiblyUndefinedVariable'])) { - return true; - } - + if ($codebase->alter_code + && isset($project_analyzer->getIssuesToFix()['PossiblyUndefinedVariable']) + ) { $branch_point = $statements_analyzer->getBranchPoint($var_name); if ($branch_point) { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/MatchAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/MatchAnalyzer.php index 677d36a5..c1694804 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/MatchAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/MatchAnalyzer.php @@ -81,7 +81,8 @@ class MatchAnalyzer && ($stmt->cond->name->parts === ['get_class'] || $stmt->cond->name->parts === ['gettype'] || $stmt->cond->name->parts === ['get_debug_type'] - || $stmt->cond->name->parts === ['count']) + || $stmt->cond->name->parts === ['count'] + || $stmt->cond->name->parts === ['sizeof']) && $stmt->cond->getArgs() ) { $first_arg = $stmt->cond->getArgs()[0]; diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/SimpleTypeInferer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/SimpleTypeInferer.php index e5b03998..aa229281 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/SimpleTypeInferer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/SimpleTypeInferer.php @@ -758,7 +758,7 @@ class SimpleTypeInferer foreach ($unpacked_atomic_type->properties as $key => $property_value) { if (is_string($key)) { $new_offset = $key; - $array_creation_info->item_key_atomic_types[] = new TLiteralString($new_offset); + $array_creation_info->item_key_atomic_types[] = Type::getAtomicStringFromLiteral($new_offset); } else { $new_offset = $array_creation_info->int_offset++; $array_creation_info->item_key_atomic_types[] = new TLiteralInt($new_offset); diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php index 07f12204..eb4f256f 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php @@ -20,6 +20,8 @@ use Psalm\Type\Atomic\TString; use Psalm\Type\Union; use RuntimeException; +use function is_int; + /** * @internal */ @@ -51,7 +53,9 @@ class UnaryPlusMinusAnalyzer continue; } if ($type_part instanceof TLiteralInt) { - $type_part = new TLiteralInt(-$type_part->value); + /** @var int|float $value */ + $value = -$type_part->value; + $type_part = is_int($value) ? new TLiteralInt($value) : new TLiteralFloat($value); } elseif ($type_part instanceof TLiteralFloat) { $type_part = new TLiteralFloat(-$type_part->value); } elseif ($type_part instanceof TIntRange) { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/StatementsAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/StatementsAnalyzer.php index c13850f0..896f5ac3 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/StatementsAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/StatementsAnalyzer.php @@ -76,7 +76,6 @@ use function fwrite; use function get_class; use function in_array; use function is_string; -use function ltrim; use function preg_split; use function reset; use function round; @@ -794,21 +793,21 @@ class StatementsAnalyzer extends SourceAnalyzer if (isset($comments->tags['psalm-scope-this'])) { $trimmed = trim(reset($comments->tags['psalm-scope-this'])); - $trimmed = ltrim($trimmed, '\\'); + $scope_fqcn = Type::getFQCLNFromString($trimmed, $this->getAliases()); - if (!$codebase->classExists($trimmed)) { + if (!$codebase->classExists($scope_fqcn)) { IssueBuffer::maybeAdd( new UndefinedDocblockClass( - 'Scope class ' . $trimmed . ' does not exist', + 'Scope class ' . $scope_fqcn . ' does not exist', new CodeLocation($this->getSource(), $stmt, null, true), - $trimmed, + $scope_fqcn, ), ); } else { - $this_type = Type::parseString($trimmed); - $context->self = $trimmed; + $this_type = Type::parseString($scope_fqcn); + $context->self = $scope_fqcn; $context->vars_in_scope['$this'] = $this_type; - $this->setFQCLN($trimmed); + $this->setFQCLN($scope_fqcn); } } } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/TraitAnalyzer.php b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/TraitAnalyzer.php index 8bea62d0..c6192a66 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/TraitAnalyzer.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Analyzer/TraitAnalyzer.php @@ -5,6 +5,7 @@ namespace Psalm\Internal\Analyzer; use PhpParser\Node\Stmt\Trait_; use Psalm\Aliases; use Psalm\Context; +use Psalm\IssueBuffer; use function assert; @@ -80,5 +81,9 @@ class TraitAnalyzer extends ClassLikeAnalyzer AttributesAnalyzer::TARGET_CLASS, $storage->suppressed_issues + $statements_analyzer->getSuppressedIssues(), ); + + foreach ($storage->docblock_issues as $docblock_issue) { + IssueBuffer::maybeAdd($docblock_issue); + } } } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Cli/Psalm.php b/vendor/vimeo/psalm/src/Psalm/Internal/Cli/Psalm.php index f7f60c78..58ce6d78 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Cli/Psalm.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Cli/Psalm.php @@ -44,6 +44,7 @@ use function array_sum; use function array_values; use function chdir; use function count; +use function extension_loaded; use function file_exists; use function file_put_contents; use function function_exists; @@ -899,8 +900,17 @@ final class Psalm } } - if ($threads > 1) { + if ($threads > 1 + && extension_loaded('grpc') + && (ini_get('grpc.enable_fork_support') === '1' && ini_get('grpc.poll_strategy') === 'epoll1') === false + ) { $ini_handler->disableExtension('grpc'); + + $progress->warning(PHP_EOL + . 'grpc extension has been disabled. ' + . 'Set grpc.enable_fork_support = 1 and grpc.poll_strategy = epoll1 in php.ini to enable it. ' + . 'See https://github.com/grpc/grpc/issues/20250#issuecomment-531321945 for more information.' + . PHP_EOL . PHP_EOL); } $ini_handler->disableExtensions([ diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ClassLikes.php b/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ClassLikes.php index 08e43ac4..618ba707 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ClassLikes.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ClassLikes.php @@ -1703,6 +1703,10 @@ class ClassLikes continue; } + if ($method_storage->public_api) { + continue; + } + if ($method_storage->location && !$project_analyzer->canReportIssues($method_storage->location->file_path) && !$codebase->analyzer->canReportIssues($method_storage->location->file_path) diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ConstantTypeResolver.php b/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ConstantTypeResolver.php index a67ed0ff..d341bbc9 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ConstantTypeResolver.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/ConstantTypeResolver.php @@ -94,7 +94,7 @@ class ConstantTypeResolver || $right instanceof TLiteralFloat || $right instanceof TLiteralInt) ) { - return new TLiteralString($left->value . $right->value); + return Type::getAtomicStringFromLiteral($left->value . $right->value); } return new TString(); @@ -355,7 +355,7 @@ class ConstantTypeResolver } if (is_string($value)) { - return new TLiteralString($value); + return Type::getAtomicStringFromLiteral($value); } if (is_int($value)) { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/Functions.php b/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/Functions.php index 9ba277fe..50e3f60f 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/Functions.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/Functions.php @@ -555,7 +555,7 @@ class Functions return true; } - if ($function_id === 'count' && isset($args[0]) && $type_provider) { + if (in_array($function_id, ['count', 'sizeof']) && isset($args[0]) && $type_provider) { $count_type = $type_provider->getType($args[0]->value); if ($count_type) { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/InternalCallMapHandler.php b/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/InternalCallMapHandler.php index f25840dc..71ce092e 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/InternalCallMapHandler.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Codebase/InternalCallMapHandler.php @@ -36,26 +36,26 @@ use function version_compare; class InternalCallMapHandler { private const PHP_MAJOR_VERSION = 8; - private const PHP_MINOR_VERSION = 2; + private const PHP_MINOR_VERSION = 3; private const LOWEST_AVAILABLE_DELTA = 71; private static ?int $loaded_php_major_version = null; private static ?int $loaded_php_minor_version = null; /** - * @var array>|null + * @var non-empty-array>|null */ private static ?array $call_map = null; /** - * @var array>|null + * @var array>|null */ private static ?array $call_map_callables = []; /** - * @var array>> + * @var non-empty-array>>|null */ - private static array $taint_sink_map = []; + private static ?array $taint_sink_map = null; /** * @param list $args @@ -84,7 +84,7 @@ class InternalCallMapHandler } /** - * @param array $callables + * @param non-empty-list $callables * @param list $args */ public static function getMatchingCallableFromCallMapOptions( @@ -216,7 +216,7 @@ class InternalCallMapHandler } /** - * @return list|null + * @return non-empty-list|null */ public static function getCallablesFromCallMap(string $function_id): ?array { @@ -332,7 +332,9 @@ class InternalCallMapHandler /** * Gets the method/function call map * - * @return array> + * @return non-empty-array> + * @psalm-assert !null self::$taint_sink_map + * @psalm-assert !null self::$call_map */ public static function getCallMap(): array { @@ -353,26 +355,31 @@ class InternalCallMapHandler return self::$call_map; } - /** @var array> */ - $call_map = require(dirname(__DIR__, 4) . '/dictionaries/CallMap.php'); + /** @var non-empty-array> */ + $call_map_data = require(dirname(__DIR__, 4) . '/dictionaries/CallMap.php'); - self::$call_map = []; + $call_map = []; - foreach ($call_map as $key => $value) { + foreach ($call_map_data as $key => $value) { $cased_key = strtolower($key); - self::$call_map[$cased_key] = $value; + $call_map[$cased_key] = $value; } + self::$call_map = $call_map; + /** - * @var array>> + * @var non-empty-array>> */ - $taint_map = require(dirname(__DIR__, 4) . '/dictionaries/InternalTaintSinkMap.php'); + $taint_map_data = require(dirname(__DIR__, 4) . '/dictionaries/InternalTaintSinkMap.php'); - foreach ($taint_map as $key => $value) { + $taint_map = []; + foreach ($taint_map_data as $key => $value) { $cased_key = strtolower($key); - self::$taint_sink_map[$cased_key] = $value; + $taint_map[$cased_key] = $value; } + self::$taint_sink_map = $taint_map; + if (version_compare($analyzer_version, $current_version, '<')) { // the following assumes both minor and major versions a single digits for ($i = $current_version_int; $i > $analyzer_version_int && $i >= self::LOWEST_AVAILABLE_DELTA; --$i) { @@ -408,6 +415,7 @@ class InternalCallMapHandler } } } + assert(!empty(self::$call_map)); self::$loaded_php_major_version = $analyzer_major_version; self::$loaded_php_minor_version = $analyzer_minor_version; diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/FileManipulation/FunctionDocblockManipulator.php b/vendor/vimeo/psalm/src/Psalm/Internal/FileManipulation/FunctionDocblockManipulator.php index 9608c2d4..9b1762db 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/FileManipulation/FunctionDocblockManipulator.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/FileManipulation/FunctionDocblockManipulator.php @@ -17,7 +17,9 @@ use Psalm\Internal\Scanner\ParsedDocblock; use function array_key_exists; use function array_merge; use function array_reduce; +use function array_slice; use function count; +use function implode; use function is_string; use function ltrim; use function preg_match; @@ -332,7 +334,29 @@ class FunctionDocblockManipulator foreach ($parsed_docblock->tags['param'] as &$param_block) { $doc_parts = CommentAnalyzer::splitDocLine($param_block); + // If there's no type + if (($doc_parts[0] ?? null) === '$' . $param_name) { + // If the parameter has a description add that back + if (count($doc_parts) > 1) { + $new_param_block .= " ". implode(" ", array_slice($doc_parts, 1)); + } + + if ($param_block !== $new_param_block) { + $modified_docblock = true; + } + + $param_block = $new_param_block; + $found_in_params = true; + break; + } + + // If there is a type if (($doc_parts[1] ?? null) === '$' . $param_name) { + // If the parameter has a description add that back + if (count($doc_parts) > 2) { + $new_param_block .= " ". implode(" ", array_slice($doc_parts, 2)); + } + if ($param_block !== $new_param_block) { $modified_docblock = true; } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php index 59805870..38f524b6 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php @@ -356,7 +356,12 @@ class ClassLikeDocblockParser $method_tree = $parse_tree_creator->create(); } catch (TypeParseTreeException $e) { - throw new DocblockParseException($method_entry . ' is not a valid method'); + throw new DocblockParseException( + $method_entry . ' is not a valid method: ' + . $e->getMessage(), + 0, + $e, + ); } if (!$method_tree instanceof MethodWithReturnTypeTree diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php index 3da672a6..6331b7ec 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php @@ -42,11 +42,13 @@ use Psalm\Issue\ConstantDeclarationInTrait; use Psalm\Issue\DuplicateClass; use Psalm\Issue\DuplicateConstant; use Psalm\Issue\DuplicateEnumCase; +use Psalm\Issue\InvalidAttribute; use Psalm\Issue\InvalidDocblock; use Psalm\Issue\InvalidEnumBackingType; use Psalm\Issue\InvalidEnumCaseValue; use Psalm\Issue\InvalidTypeImport; use Psalm\Issue\MissingDocblockType; +use Psalm\Issue\MissingPropertyType; use Psalm\Issue\ParseError; use Psalm\IssueBuffer; use Psalm\Storage\AttributeStorage; @@ -256,6 +258,7 @@ class ClassLikeNodeScanner if ($node instanceof PhpParser\Node\Stmt\Class_) { $storage->abstract = $node->isAbstract(); $storage->final = $node->isFinal(); + $storage->readonly = $node->isReadonly(); $this->codebase->classlikes->addFullyQualifiedClassName($fq_classlike_name, $this->file_path); @@ -704,10 +707,10 @@ class ClassLikeNodeScanner $name_types = []; $values_types = []; foreach ($storage->enum_cases as $name => $enumCaseStorage) { - $name_types[] = new Type\Atomic\TLiteralString($name); + $name_types[] = Type::getAtomicStringFromLiteral($name); if ($storage->enum_type !== null) { if (is_string($enumCaseStorage->value)) { - $values_types[] = new Type\Atomic\TLiteralString($enumCaseStorage->value); + $values_types[] = Type::getAtomicStringFromLiteral($enumCaseStorage->value); } elseif (is_int($enumCaseStorage->value)) { $values_types[] = new Type\Atomic\TLiteralInt($enumCaseStorage->value); } @@ -765,6 +768,14 @@ class ClassLikeNodeScanner $storage->external_mutation_free = true; } + if ($attribute->fq_class_name === 'AllowDynamicProperties' && $storage->readonly) { + IssueBuffer::maybeAdd(new InvalidAttribute( + 'Readonly classes cannot have dynamic properties', + new CodeLocation($this->file_scanner, $attr, null, true), + )); + continue; + } + $storage->attributes[] = $attribute; } } @@ -1586,10 +1597,22 @@ class ClassLikeNodeScanner if (count($property_storage->internal) === 0 && $var_comment && $var_comment->internal) { $property_storage->internal = [NamespaceAnalyzer::getNameSpaceRoot($fq_classlike_name)]; } - $property_storage->readonly = $stmt->isReadonly() || ($var_comment && $var_comment->readonly); + $property_storage->readonly = $storage->readonly + || $stmt->isReadonly() + || ($var_comment && $var_comment->readonly); $property_storage->allow_private_mutation = $var_comment ? $var_comment->allow_private_mutation : false; $property_storage->description = $var_comment ? $var_comment->description : null; + if (!$signature_type && $storage->readonly) { + IssueBuffer::maybeAdd( + new MissingPropertyType( + 'Properties of readonly classes must have a type', + new CodeLocation($this->file_scanner, $stmt, null, true), + $fq_classlike_name . '::$' . $property->name->name, + ), + ); + } + if (!$signature_type && !$doc_var_group_type) { if ($property->default) { $property_storage->suggested_type = SimpleTypeInferer::infer( @@ -1883,8 +1906,8 @@ class ClassLikeNodeScanner $type_string = str_replace("\n", '', implode('', $var_line_parts)); - $type_string = preg_replace('/>[^>^\}]*$/', '>', $type_string, 1); - $type_string = preg_replace('/\}[^>^\}]*$/', '}', $type_string, 1); + // Strip any remaining characters after the last grouping character >, } or ) + $type_string = preg_replace('/(?<=[>})])[^>})]*$/', '', $type_string, 1); try { $type_tokens = TypeTokenizer::getFullyQualifiedTokens( diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockParser.php b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockParser.php index 639692a8..7ade521f 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockParser.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockParser.php @@ -555,6 +555,8 @@ class FunctionLikeDocblockParser $info->description = $parsed_docblock->description; } + $info->public_api = isset($parsed_docblock->tags['psalm-api']) || isset($parsed_docblock->tags['api']); + return $info; } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockScanner.php b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockScanner.php index c61377cd..f0cc1dc5 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockScanner.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockScanner.php @@ -417,6 +417,8 @@ class FunctionLikeDocblockScanner if ($docblock_info->description) { $storage->description = $docblock_info->description; } + + $storage->public_api = $docblock_info->public_api; } /** @@ -489,7 +491,8 @@ class FunctionLikeDocblockScanner // spaces are allowed before $foo in get(string $foo) magic method // definitions, but we want to remove them in this instance - if (isset($fixed_type_tokens[$i - 1]) + if ($i > 0 + && isset($fixed_type_tokens[$i - 1]) && $fixed_type_tokens[$i - 1][0][0] === ' ' ) { unset($fixed_type_tokens[$i - 1]); diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php index ce008167..ed3463b9 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php @@ -34,6 +34,7 @@ use Psalm\Issue\DuplicateParam; use Psalm\Issue\InvalidDocblock; use Psalm\Issue\MissingDocblockType; use Psalm\Issue\ParseError; +use Psalm\Issue\PrivateFinalMethod; use Psalm\IssueBuffer; use Psalm\Storage\ClassLikeStorage; use Psalm\Storage\FileStorage; @@ -1101,7 +1102,24 @@ class FunctionLikeNodeScanner $storage->is_static = $stmt->isStatic(); $storage->abstract = $stmt->isAbstract(); - $storage->final = $classlike_storage->final || $stmt->isFinal(); + if ($stmt->isPrivate() && $stmt->isFinal() && $method_name_lc !== '__construct') { + IssueBuffer::maybeAdd( + new PrivateFinalMethod( + 'Private methods cannot be final', + new CodeLocation($this->file_scanner, $stmt, null, true), + (string) $method_id, + ), + ); + if ($this->codebase->analysis_php_version_id >= 8_00_00) { + // ignore `final` on the method as that's what PHP does + $storage->final = $classlike_storage->final; + } else { + $storage->final = true; + } + } else { + $storage->final = $classlike_storage->final || $stmt->isFinal(); + } + $storage->final_from_docblock = $classlike_storage->final_from_docblock; if ($stmt->isPrivate()) { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php b/vendor/vimeo/psalm/src/Psalm/Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php index 19606c9a..c96a50f1 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php @@ -46,6 +46,9 @@ class HtmlFunctionTainter implements AddTaintsInterface, RemoveTaintsInterface $second_arg = $item->getArgs()[1]->value ?? null; if ($second_arg === null) { + if ($statements_analyzer->getCodebase()->analysis_php_version_id >= 8_01_00) { + return ['html', 'has_quotes']; + } return ['html']; } @@ -95,6 +98,9 @@ class HtmlFunctionTainter implements AddTaintsInterface, RemoveTaintsInterface $second_arg = $item->getArgs()[1]->value ?? null; if ($second_arg === null) { + if ($statements_analyzer->getCodebase()->analysis_php_version_id >= 8_01_00) { + return ['html', 'has_quotes']; + } return ['html']; } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Provider/ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php b/vendor/vimeo/psalm/src/Psalm/Internal/Provider/ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php index ee7938f7..04b8b59c 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Provider/ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Provider/ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php @@ -56,7 +56,7 @@ class GetObjectVarsReturnTypeProvider implements FunctionReturnTypeProviderInter $object_type = reset($atomics); if ($object_type instanceof Atomic\TEnumCase) { - $properties = ['name' => new Union([new Atomic\TLiteralString($object_type->case_name)])]; + $properties = ['name' => new Union([Type::getAtomicStringFromLiteral($object_type->case_name)])]; $codebase = $statements_source->getCodebase(); $enum_classlike_storage = $codebase->classlike_storage_provider->get($object_type->value); if ($enum_classlike_storage->enum_type === null) { @@ -66,7 +66,7 @@ class GetObjectVarsReturnTypeProvider implements FunctionReturnTypeProviderInter if (is_int($enum_case_storage->value)) { $properties['value'] = new Union([new Atomic\TLiteralInt($enum_case_storage->value)]); } elseif (is_string($enum_case_storage->value)) { - $properties['value'] = new Union([new Atomic\TLiteralString($enum_case_storage->value)]); + $properties['value'] = new Union([Type::getAtomicStringFromLiteral($enum_case_storage->value)]); } return new TKeyedArray($properties); } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Provider/ReturnTypeProvider/VersionCompareReturnTypeProvider.php b/vendor/vimeo/psalm/src/Psalm/Internal/Provider/ReturnTypeProvider/VersionCompareReturnTypeProvider.php index 739d254c..6340fedd 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Provider/ReturnTypeProvider/VersionCompareReturnTypeProvider.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Provider/ReturnTypeProvider/VersionCompareReturnTypeProvider.php @@ -9,7 +9,6 @@ use Psalm\Plugin\EventHandler\FunctionReturnTypeProviderInterface; use Psalm\Type; use Psalm\Type\Atomic\TBool; use Psalm\Type\Atomic\TLiteralInt; -use Psalm\Type\Atomic\TLiteralString; use Psalm\Type\Atomic\TNull; use Psalm\Type\Union; @@ -42,20 +41,20 @@ class VersionCompareReturnTypeProvider implements FunctionReturnTypeProviderInte if ($operator_type) { if (!$operator_type->hasMixed()) { $acceptable_operator_type = new Union([ - new TLiteralString('<'), - new TLiteralString('lt'), - new TLiteralString('<='), - new TLiteralString('le'), - new TLiteralString('>'), - new TLiteralString('gt'), - new TLiteralString('>='), - new TLiteralString('ge'), - new TLiteralString('=='), - new TLiteralString('='), - new TLiteralString('eq'), - new TLiteralString('!='), - new TLiteralString('<>'), - new TLiteralString('ne'), + Type::getAtomicStringFromLiteral('<'), + Type::getAtomicStringFromLiteral('lt'), + Type::getAtomicStringFromLiteral('<='), + Type::getAtomicStringFromLiteral('le'), + Type::getAtomicStringFromLiteral('>'), + Type::getAtomicStringFromLiteral('gt'), + Type::getAtomicStringFromLiteral('>='), + Type::getAtomicStringFromLiteral('ge'), + Type::getAtomicStringFromLiteral('=='), + Type::getAtomicStringFromLiteral('='), + Type::getAtomicStringFromLiteral('eq'), + Type::getAtomicStringFromLiteral('!='), + Type::getAtomicStringFromLiteral('<>'), + Type::getAtomicStringFromLiteral('ne'), ]); $codebase = $statements_source->getCodebase(); diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Scanner/FunctionDocblockComment.php b/vendor/vimeo/psalm/src/Psalm/Internal/Scanner/FunctionDocblockComment.php index 74b31560..400dbcc6 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Scanner/FunctionDocblockComment.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Scanner/FunctionDocblockComment.php @@ -174,4 +174,6 @@ class FunctionDocblockComment /** @var array, suggested_replacement?:string}> */ public array $unexpected_tags = []; + + public bool $public_api = false; } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Type/AssertionReconciler.php b/vendor/vimeo/psalm/src/Psalm/Internal/Type/AssertionReconciler.php index b33d7b3a..ac8419f3 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Type/AssertionReconciler.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Type/AssertionReconciler.php @@ -945,6 +945,15 @@ class AssertionReconciler extends Reconciler $redundant = false; $existing_var_type->removeType($atomic_key); $existing_var_type->addType(new TEnumCase($fq_enum_name, $case_name)); + } elseif (AtomicTypeComparator::canBeIdentical( + $statements_analyzer->getCodebase(), + $atomic_type, + $assertion_type, + )) { + $can_be_equal = true; + $redundant = $atomic_key === $assertion_type->getKey(); + $existing_var_type->removeType($atomic_key); + $existing_var_type->addType(new TEnumCase($fq_enum_name, $case_name)); } elseif ($atomic_key !== $assertion_type->getKey()) { $existing_var_type->removeType($atomic_key); $redundant = false; diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Type/ParseTreeCreator.php b/vendor/vimeo/psalm/src/Psalm/Internal/Type/ParseTreeCreator.php index 9449448a..34502e11 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Type/ParseTreeCreator.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Type/ParseTreeCreator.php @@ -780,8 +780,7 @@ class ParseTreeCreator $type_token[0], $new_parent, ); - } elseif ($type_token[0] !== 'array' - && $type_token[0][0] !== '\\' + } elseif ($type_token[0][0] !== '\\' && $this->current_leaf instanceof Root ) { $new_leaf = new MethodTree( diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php b/vendor/vimeo/psalm/src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php index 5f7d8e12..160bdc74 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php @@ -987,17 +987,17 @@ class SimpleNegatedAssertionReconciler extends Reconciler if (get_class($string_atomic_type) === TString::class) { $existing_var_type->removeType('string'); - $existing_var_type->addType(new TLiteralString('')); - $existing_var_type->addType(new TLiteralString('0')); + $existing_var_type->addType(Type::getAtomicStringFromLiteral('')); + $existing_var_type->addType(Type::getAtomicStringFromLiteral('0')); } elseif (get_class($string_atomic_type) === TNonEmptyString::class) { $existing_var_type->removeType('string'); - $existing_var_type->addType(new TLiteralString('0')); + $existing_var_type->addType(Type::getAtomicStringFromLiteral('0')); } elseif (get_class($string_atomic_type) === TNonEmptyLowercaseString::class) { $existing_var_type->removeType('string'); - $existing_var_type->addType(new TLiteralString('0')); + $existing_var_type->addType(Type::getAtomicStringFromLiteral('0')); } elseif (get_class($string_atomic_type) === TNonEmptyNonspecificLiteralString::class) { $existing_var_type->removeType('string'); - $existing_var_type->addType(new TLiteralString('0')); + $existing_var_type->addType(Type::getAtomicStringFromLiteral('0')); } } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Type/TypeCombiner.php b/vendor/vimeo/psalm/src/Psalm/Internal/Type/TypeCombiner.php index f22dd918..85aad52b 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Type/TypeCombiner.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Type/TypeCombiner.php @@ -1473,7 +1473,7 @@ class TypeCombiner } elseif ($type instanceof TKeyedArray && isset($type->class_strings[$property_name])) { $objectlike_keys[$property_name] = new TLiteralClassString($property_name, $from_docblock); } else { - $objectlike_keys[$property_name] = new TLiteralString($property_name, $from_docblock); + $objectlike_keys[$property_name] = Type::getAtomicStringFromLiteral($property_name, $from_docblock); } } diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/Type/TypeParser.php b/vendor/vimeo/psalm/src/Psalm/Internal/Type/TypeParser.php index cf95fbec..fc0016f7 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/Type/TypeParser.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/Type/TypeParser.php @@ -47,7 +47,6 @@ use Psalm\Type\Atomic\TKeyedArray; use Psalm\Type\Atomic\TLiteralClassString; use Psalm\Type\Atomic\TLiteralFloat; use Psalm\Type\Atomic\TLiteralInt; -use Psalm\Type\Atomic\TLiteralString; use Psalm\Type\Atomic\TMixed; use Psalm\Type\Atomic\TNamedObject; use Psalm\Type\Atomic\TNonEmptyArray; @@ -393,7 +392,7 @@ class TypeParser } if ($parse_tree->value[0] === '"' || $parse_tree->value[0] === '\'') { - return new TLiteralString(substr($parse_tree->value, 1, -1), $from_docblock); + return Type::getAtomicStringFromLiteral(substr($parse_tree->value, 1, -1), $from_docblock); } if (strpos($parse_tree->value, '::')) { diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/TypeVisitor/TypeChecker.php b/vendor/vimeo/psalm/src/Psalm/Internal/TypeVisitor/TypeChecker.php index d135de1b..4c2e52c9 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/TypeVisitor/TypeChecker.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/TypeVisitor/TypeChecker.php @@ -348,6 +348,7 @@ class TypeChecker extends TypeVisitor { if ($this->prevent_template_covariance && strpos($atomic->defining_class, 'fn-') !== 0 + && $atomic->defining_class !== 'class-string-map' ) { $codebase = $this->source->getCodebase(); diff --git a/vendor/vimeo/psalm/src/Psalm/Internal/VersionUtils.php b/vendor/vimeo/psalm/src/Psalm/Internal/VersionUtils.php index 7dbda1b6..ac0d6575 100644 --- a/vendor/vimeo/psalm/src/Psalm/Internal/VersionUtils.php +++ b/vendor/vimeo/psalm/src/Psalm/Internal/VersionUtils.php @@ -2,8 +2,8 @@ namespace Psalm\Internal; +use Composer\InstalledVersions; use OutOfBoundsException; -use PackageVersions\Versions; use Phar; use function class_exists; @@ -89,11 +89,17 @@ final class VersionUtils { try { return [ - self::PSALM_PACKAGE => Versions::getVersion(self::PSALM_PACKAGE), - self::PHP_PARSER_PACKAGE => Versions::getVersion(self::PHP_PARSER_PACKAGE), + self::PSALM_PACKAGE => self::getVersion(self::PSALM_PACKAGE), + self::PHP_PARSER_PACKAGE => self::getVersion(self::PHP_PARSER_PACKAGE), ]; } catch (OutOfBoundsException $ex) { } return null; } + + private static function getVersion(string $packageName): string + { + return InstalledVersions::getPrettyVersion($packageName) + . '@' . InstalledVersions::getReference($packageName); + } } diff --git a/vendor/vimeo/psalm/src/Psalm/Issue/PrivateFinalMethod.php b/vendor/vimeo/psalm/src/Psalm/Issue/PrivateFinalMethod.php new file mode 100644 index 00000000..bdf63371 --- /dev/null +++ b/vendor/vimeo/psalm/src/Psalm/Issue/PrivateFinalMethod.php @@ -0,0 +1,9 @@ +getCodebase(); - $issues = $event->getIssues(); - $build_info = $event->getBuildInfo(); - $source_control_info = $event->getSourceControlInfo(); - if (!function_exists('curl_init')) { - fwrite(STDERR, 'No curl found, cannot send data to ' . $codebase->config->shepherd_host . PHP_EOL); + fwrite(STDERR, "No curl found, cannot send data to shepherd server.\n"); return; } + $rawPayload = self::collectPayloadToSend($event); + + if ($rawPayload === null) { + return; + } + + $config = $event->getCodebase()->config; + + /** + * Deprecated logic, in Psalm 6 just use $config->shepherd_endpoint + * '#' here is just a hack/marker to use a custom endpoint instead just a custom domain + * case 1: empty option (use https://shepherd.dev/hooks/psalm/) + * case 2: custom domain (/hooks/psalm should be appended) (use https://custom.domain/hooks/psalm) + * case 3: custom endpoint (/hooks/psalm should be appended) (use custom endpoint) + */ + if (substr_compare($config->shepherd_endpoint, '#', -1) === 0) { + $shepherd_endpoint = $config->shepherd_endpoint; + } else { + /** @psalm-suppress DeprecatedProperty, DeprecatedMethod */ + $shepherd_endpoint = self::buildShepherdUrlFromHost($config->shepherd_host); + } + + self::sendPayload($shepherd_endpoint, $rawPayload); + } + + /** + * @psalm-pure + * @deprecated Will be removed in Psalm 6 + */ + private static function buildShepherdUrlFromHost(string $host): string + { + if (parse_url($host, PHP_URL_SCHEME) === null) { + $host = 'https://' . $host; + } + + return $host . '/hooks/psalm'; + } + + /** + * @return array{build: array, git: array, issues: array, coverage: list, level: int<1,8>}|null + */ + private static function collectPayloadToSend(AfterAnalysisEvent $event): ?array + { + /** @see \Psalm\Internal\ExecutionEnvironment\BuildInfoCollector::collect */ + $build_info = $event->getBuildInfo(); + + $is_ci_env = array_key_exists('CI_NAME', $build_info); // 'git' key always presents + if (! $is_ci_env) { + return null; + } + + $source_control_info = $event->getSourceControlInfo(); $source_control_data = $source_control_info ? $source_control_info->toArray() : []; - if (!$source_control_data && isset($build_info['git']) && is_array($build_info['git'])) { + if ($source_control_data === [] && isset($build_info['git']) && is_array($build_info['git'])) { $source_control_data = $build_info['git']; } unset($build_info['git']); - if ($build_info) { - $normalized_data = $issues === [] ? [] : array_filter( - array_merge(...array_values($issues)), - static fn(IssueData $i): bool => $i->severity === 'error', - ); - - $data = [ - 'build' => $build_info, - 'git' => $source_control_data, - 'issues' => $normalized_data, - 'coverage' => $codebase->analyzer->getTotalTypeCoverage($codebase), - 'level' => Config::getInstance()->level, - ]; - - $payload = json_encode($data, JSON_THROW_ON_ERROR); - - /** @psalm-suppress DeprecatedProperty */ - $base_address = $codebase->config->shepherd_host; - - if (parse_url($base_address, PHP_URL_SCHEME) === null) { - $base_address = 'https://' . $base_address; - } - - // Prepare new cURL resource - $ch = curl_init($base_address . '/hooks/psalm'); - curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); - curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); - curl_setopt($ch, CURLINFO_HEADER_OUT, true); - curl_setopt($ch, CURLOPT_POST, true); - curl_setopt($ch, CURLOPT_POSTFIELDS, $payload); - - // Set HTTP Header for POST request - curl_setopt( - $ch, - CURLOPT_HTTPHEADER, - [ - 'Content-Type: application/json', - 'Content-Length: ' . strlen($payload), - ], - ); - - // Submit the POST request - $curl_result = curl_exec($ch); - - /** @var array{http_code: int, ssl_verify_result: int} $curl_info */ - $curl_info = curl_getinfo($ch); - - // Close cURL session handle - curl_close($ch); - - $response_status_code = $curl_info['http_code']; - if ($response_status_code >= 200 && $response_status_code < 300) { - $shepherd_host = parse_url($codebase->config->shepherd_endpoint, PHP_URL_HOST); - - fwrite(STDERR, "🐑 results sent to $shepherd_host 🐑" . PHP_EOL); - return; - } - - $is_ssl_error = $curl_info['ssl_verify_result'] > 1; - if ($is_ssl_error) { - fwrite(STDERR, self::getCurlSslErrorMessage($curl_info['ssl_verify_result']) . PHP_EOL); - return; - } - - fwrite(STDERR, "Shepherd error: server responded with $response_status_code HTTP status code.\n"); - $response_content = is_string($curl_result) ? strip_tags($curl_result) : 'n/a'; - fwrite(STDERR, "Shepherd response: $response_content\n"); + if ($build_info === []) { + return null; } + + $issues = $event->getIssues(); + $normalized_data = $issues === [] ? [] : array_filter( + array_merge(...array_values($issues)), + static fn(IssueData $i): bool => $i->severity === 'error', + ); + + $codebase = $event->getCodebase(); + + return [ + 'build' => $build_info, + 'git' => $source_control_data, + 'issues' => $normalized_data, + 'coverage' => $codebase->analyzer->getTotalTypeCoverage($codebase), + 'level' => Config::getInstance()->level, + ]; + } + + private static function sendPayload(string $endpoint, array $rawPayload): void + { + $payload = json_encode($rawPayload, JSON_THROW_ON_ERROR); + + // Prepare new cURL resource + $ch = curl_init($endpoint); + curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); + curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); + curl_setopt($ch, CURLINFO_HEADER_OUT, true); + curl_setopt($ch, CURLOPT_POST, true); + curl_setopt($ch, CURLOPT_POSTFIELDS, $payload); + + // Set HTTP Header for POST request + curl_setopt( + $ch, + CURLOPT_HTTPHEADER, + [ + 'Content-Type: application/json', + 'Content-Length: ' . strlen($payload), + ], + ); + + // Submit the POST request + $curl_result = curl_exec($ch); + + /** @var array{http_code: int, ssl_verify_result: int} $curl_info */ + $curl_info = curl_getinfo($ch); + + // Close cURL session handle + curl_close($ch); + + $response_status_code = $curl_info['http_code']; + if ($response_status_code >= 200 && $response_status_code < 300) { + $shepherd_host = parse_url($endpoint, PHP_URL_HOST); + + fwrite(STDERR, "🐑 results sent to $shepherd_host 🐑" . PHP_EOL); + return; + } + + $is_ssl_error = $curl_info['ssl_verify_result'] > 1; + if ($is_ssl_error) { + fwrite(STDERR, self::getCurlSslErrorMessage($curl_info['ssl_verify_result']) . PHP_EOL); + return; + } + + $output = "Shepherd error: $endpoint endpoint responded with $response_status_code HTTP status code.\n"; + $response_content = is_string($curl_result) ? strip_tags($curl_result) : 'n/a'; + $output .= "Shepherd response: $response_content\n"; + if ($response_status_code === 0) { + $output .= "Please check shepherd endpoint — it should be a valid URL.\n"; + } + + $output .= sprintf("cURL Debug info:\n%s\n", var_export($curl_info, true)); + fwrite(STDERR, $output); } /** diff --git a/vendor/vimeo/psalm/src/Psalm/Storage/ClassLikeStorage.php b/vendor/vimeo/psalm/src/Psalm/Storage/ClassLikeStorage.php index d095cefb..45fa635d 100644 --- a/vendor/vimeo/psalm/src/Psalm/Storage/ClassLikeStorage.php +++ b/vendor/vimeo/psalm/src/Psalm/Storage/ClassLikeStorage.php @@ -470,6 +470,8 @@ final class ClassLikeStorage implements HasAttributesInterface public bool $public_api = false; + public bool $readonly = false; + public function __construct(string $name) { $this->name = $name; diff --git a/vendor/vimeo/psalm/src/Psalm/Storage/FunctionLikeStorage.php b/vendor/vimeo/psalm/src/Psalm/Storage/FunctionLikeStorage.php index e581e35e..63f3c895 100644 --- a/vendor/vimeo/psalm/src/Psalm/Storage/FunctionLikeStorage.php +++ b/vendor/vimeo/psalm/src/Psalm/Storage/FunctionLikeStorage.php @@ -243,6 +243,8 @@ abstract class FunctionLikeStorage implements HasAttributesInterface */ public $description; + public bool $public_api = false; + public function __toString(): string { return $this->getSignature(false); diff --git a/vendor/vimeo/psalm/src/Psalm/Type.php b/vendor/vimeo/psalm/src/Psalm/Type.php index 5ae85202..4a066707 100644 --- a/vendor/vimeo/psalm/src/Psalm/Type.php +++ b/vendor/vimeo/psalm/src/Psalm/Type.php @@ -251,29 +251,27 @@ abstract class Type public static function getString(?string $value = null): Union { - $type = null; + return new Union([$value === null ? new TString() : self::getAtomicStringFromLiteral($value)]); + } - if ($value !== null) { - $config = Config::getInstance(); + /** @return TLiteralString|TNonEmptyString */ + public static function getAtomicStringFromLiteral(string $value, bool $from_docblock = false): TString + { + $config = Config::getInstance(); - $event = new StringInterpreterEvent($value, ProjectAnalyzer::getInstance()->getCodebase()); + $event = new StringInterpreterEvent($value, ProjectAnalyzer::getInstance()->getCodebase()); - $type = $config->eventDispatcher->dispatchStringInterpreter($event); + $type = $config->eventDispatcher->dispatchStringInterpreter($event); - if (!$type) { - if (strlen($value) < $config->max_string_length) { - $type = new TLiteralString($value); - } else { - $type = new TNonEmptyString(); - } + if (!$type) { + if (strlen($value) < $config->max_string_length) { + $type = new TLiteralString($value, $from_docblock); + } else { + $type = new TNonEmptyString($from_docblock); } } - if (!$type) { - $type = new TString(); - } - - return new Union([$type]); + return $type; } /** diff --git a/vendor/vimeo/psalm/src/Psalm/Type/Atomic/TKeyedArray.php b/vendor/vimeo/psalm/src/Psalm/Type/Atomic/TKeyedArray.php index b78fa865..45dfb6b2 100644 --- a/vendor/vimeo/psalm/src/Psalm/Type/Atomic/TKeyedArray.php +++ b/vendor/vimeo/psalm/src/Psalm/Type/Atomic/TKeyedArray.php @@ -13,7 +13,6 @@ use Psalm\Type\Atomic; use Psalm\Type\Atomic\TArray; use Psalm\Type\Atomic\TLiteralClassString; use Psalm\Type\Atomic\TLiteralInt; -use Psalm\Type\Atomic\TLiteralString; use Psalm\Type\Atomic\TNonEmptyArray; use Psalm\Type\Union; use UnexpectedValueException; @@ -309,7 +308,8 @@ class TKeyedArray extends Atomic } elseif (isset($this->class_strings[$key])) { $key_types[] = new TLiteralClassString($key); } else { - $key_types[] = new TLiteralString($key); + /** @psalm-suppress ImpureMethodCall let's assume string interpreters are pure */ + $key_types[] = Type::getAtomicStringFromLiteral($key); } } @@ -362,7 +362,8 @@ class TKeyedArray extends Atomic } elseif (isset($this->class_strings[$key])) { $key_types[] = new TLiteralClassString($key); } else { - $key_types[] = new TLiteralString($key); + /** @psalm-suppress ImpureMethodCall let's assume string interpreters are pure */ + $key_types[] = Type::getAtomicStringFromLiteral($key); } $value_type = Type::combineUnionTypes($property, $value_type); diff --git a/vendor/vimeo/psalm/src/Psalm/Type/Atomic/TLiteralString.php b/vendor/vimeo/psalm/src/Psalm/Type/Atomic/TLiteralString.php index 901fb866..7346e5a0 100644 --- a/vendor/vimeo/psalm/src/Psalm/Type/Atomic/TLiteralString.php +++ b/vendor/vimeo/psalm/src/Psalm/Type/Atomic/TLiteralString.php @@ -2,9 +2,13 @@ namespace Psalm\Type\Atomic; +use InvalidArgumentException; +use Psalm\Config; + use function addcslashes; use function mb_strlen; use function mb_substr; +use function strlen; /** * Denotes a string whose value is known. @@ -16,12 +20,43 @@ class TLiteralString extends TString /** @var string */ public $value; + /** + * Creates a literal string with a known value. + * + * Internal. + * String interpreters should use {@see TLiteralString::make} instead. + * All other clients should use {@see Type::getAtomicStringFromLiteral}. + * + * @psalm-internal Psalm\Type::getAtomicStringFromLiteral + * @psalm-internal Psalm\Type\Atomic\TLiteralClassString::__construct + * @psalm-internal Psalm\Type\Atomic\TLiteralString::make + */ public function __construct(string $value, bool $from_docblock = false) { + $config = Config::getInstance(); + if (strlen($value) >= $config->max_string_length) { + throw new InvalidArgumentException( + 'Literal string length should be below the configured limit (' + . $config->max_string_length + . ')', + ); + } $this->value = $value; $this->from_docblock = $from_docblock; } + /** + * Should only be used by string interpreters to avoid recursive calls. + * + * For all other purposes use {@see Type::getAtomicStringFromLiteral} + * + * @psalm-api + */ + public static function make(string $value, bool $from_docblock = false): self + { + return new self($value, $from_docblock); + } + /** * @psalm-suppress PossiblyUnusedMethod * @return static diff --git a/vendor/vimeo/psalm/stubs/CoreGenericClasses.phpstub b/vendor/vimeo/psalm/stubs/CoreGenericClasses.phpstub index 74a2353c..528f59ab 100644 --- a/vendor/vimeo/psalm/stubs/CoreGenericClasses.phpstub +++ b/vendor/vimeo/psalm/stubs/CoreGenericClasses.phpstub @@ -531,14 +531,3 @@ final class ReturnTypeWillChange public function __construct() {} } -#[Attribute(Attribute::TARGET_PARAMETER)] -final class SensitiveParameter -{ - public function __construct() {} -} - -#[Attribute(Attribute::TARGET_CLASS)] -final class AllowDynamicProperties -{ - public function __construct() {} -} diff --git a/vendor/vimeo/psalm/stubs/Php80.phpstub b/vendor/vimeo/psalm/stubs/Php80.phpstub index 42e0ad79..2f2d5bf0 100644 --- a/vendor/vimeo/psalm/stubs/Php80.phpstub +++ b/vendor/vimeo/psalm/stubs/Php80.phpstub @@ -240,6 +240,13 @@ class DatePeriod implements IteratorAggregate */ function get_headers(string $url, bool $associative = false, $context = null) : array|false {} +/** + * @psalm-pure + * + * @psalm-flow ($values) -> return + */ +function pack(string $format, mixed ...$values): string {} + final class CurlHandle { private function __construct() diff --git a/vendor/vimeo/psalm/stubs/Php82.phpstub b/vendor/vimeo/psalm/stubs/Php82.phpstub index f6da0a6c..40d60e3e 100644 --- a/vendor/vimeo/psalm/stubs/Php82.phpstub +++ b/vendor/vimeo/psalm/stubs/Php82.phpstub @@ -33,4 +33,16 @@ namespace { /** @psalm-return (Start is string ? Iterator : Iterator) */ public function getIterator(): Iterator {} } + + #[Attribute(Attribute::TARGET_PARAMETER)] + final class SensitiveParameter + { + public function __construct() {} + } + + #[Attribute(Attribute::TARGET_CLASS)] + final class AllowDynamicProperties + { + public function __construct() {} + } } diff --git a/vendor/vimeo/psalm/stubs/extensions/ffi.phpstub b/vendor/vimeo/psalm/stubs/extensions/ffi.phpstub index bd6152fa..6e14a77c 100644 --- a/vendor/vimeo/psalm/stubs/extensions/ffi.phpstub +++ b/vendor/vimeo/psalm/stubs/extensions/ffi.phpstub @@ -19,9 +19,10 @@ namespace { } /** + * Note: Official docs say this could return `null`, but it throws exceptions instead. * @param \FFI\CType|string $type */ - public static function new($type, bool $owned = true, bool $persistent = false): ?\FFI\CData + public static function new($type, bool $owned = true, bool $persistent = false): \FFI\CData { } @@ -106,6 +107,25 @@ namespace { public static function isNull(\FFI\CData $ptr): bool { } + + public function __call(...$values) + { + } + + /** + * @param mixed $value + * @return mixed $value + */ + public function __set(string $key, $value) + { + } + + /** + * @return string|int|float|\FFI\CData|null + */ + public function __get(string $key) + { + } } } @@ -115,9 +135,36 @@ namespace FFI { /** * @since 7.4.0 */ - final class CData + final class CData implements \Countable, \ArrayAccess, \Countable, \Traversable { + /** + * @return bool + */ + public function offsetExists($offset) + { + } + /** + * @return mixed|null + */ + public function offsetGet($offset) + { + } + + /** + * @param mixed|null $value + * @return void + */ + public function offsetSet($offset, $value) + { + } + + /** + * @return void + */ + public function offsetUnset($offset) + { + } } /** diff --git a/vendor/vimeo/psalm/stubs/extensions/ibm_db2.phpstub b/vendor/vimeo/psalm/stubs/extensions/ibm_db2.phpstub new file mode 100644 index 00000000..de8a47a0 --- /dev/null +++ b/vendor/vimeo/psalm/stubs/extensions/ibm_db2.phpstub @@ -0,0 +1,9 @@ + 1 ? bool : (0|1)) + */ +function db2_autocommit($connection, int $value = null): int|bool {}