This run took 331 seconds.
From 10ad0d23c18038ca612869567af1627578a08eb8 Mon Sep 17 00:00:00 2001 From: libraryupgrader <tools.libraryupgrader@tools.wmflabs.org> Date: Sat, 2 Nov 2024 06:12:12 +0000 Subject: [PATCH] build: Updating mediawiki/mediawiki-codesniffer to 45.0.0 Change-Id: I9552ab159970c5da16d65b762eba77cc67dabd06 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 036773b..9e75e90 100644 --- a/composer.json +++ b/composer.json @@ -38,7 +38,7 @@ }, "require-dev": { "ext-pdo": "*", - "mediawiki/mediawiki-codesniffer": "44.0.0", + "mediawiki/mediawiki-codesniffer": "45.0.0", "mediawiki/minus-x": "1.1.3", "php-parallel-lint/php-console-highlighter": "1.0.0", "php-parallel-lint/php-parallel-lint": "1.4.0", -- 2.39.2
$ date --- stdout --- Sat Nov 2 06:06:44 UTC 2024 --- end --- $ git clone file:///srv/git/mediawiki-tools-phan-SecurityCheckPlugin.git repo --depth=1 -b master --- stderr --- Cloning into 'repo'... --- stdout --- --- end --- $ git config user.name libraryupgrader --- stdout --- --- end --- $ git config user.email tools.libraryupgrader@tools.wmflabs.org --- stdout --- --- end --- $ git submodule update --init --- stdout --- --- end --- $ grr init --- stdout --- Installed commit-msg hook. --- end --- $ git show-ref refs/heads/master --- stdout --- 0faff96570d20605c2bd57f7478e205c5acb75af refs/heads/master --- end --- $ /usr/bin/composer install --- stderr --- No composer.lock file present. Updating dependencies to latest instead of installing from lock file. See https://getcomposer.org/install for more information. Loading composer repositories with package information Updating dependencies Lock file operations: 64 installs, 0 updates, 0 removals - Locking composer/pcre (3.3.1) - Locking composer/semver (3.4.2) - Locking composer/spdx-licenses (1.5.8) - Locking composer/xdebug-handler (3.0.5) - Locking dealerdirect/phpcodesniffer-composer-installer (v1.0.0) - Locking doctrine/deprecations (1.1.3) - Locking doctrine/instantiator (2.0.0) - Locking felixfbecker/advanced-json-rpc (v3.2.1) - Locking mediawiki/mediawiki-codesniffer (v44.0.0) - Locking mediawiki/minus-x (1.1.3) - Locking microsoft/tolerant-php-parser (v0.1.2) - Locking myclabs/deep-copy (1.12.0) - Locking netresearch/jsonmapper (v4.5.0) - Locking nikic/php-parser (v5.3.1) - Locking phan/phan (5.4.5) - Locking phar-io/manifest (2.0.4) - Locking phar-io/version (3.2.1) - Locking php-parallel-lint/php-console-color (v1.0.1) - Locking php-parallel-lint/php-console-highlighter (v1.0.0) - Locking php-parallel-lint/php-parallel-lint (v1.4.0) - Locking phpcsstandards/phpcsextra (1.2.1) - Locking phpcsstandards/phpcsutils (1.0.11) - Locking phpdocumentor/reflection-common (2.2.0) - Locking phpdocumentor/reflection-docblock (5.4.1) - Locking phpdocumentor/type-resolver (1.8.2) - Locking phpstan/phpdoc-parser (1.33.0) - Locking phpunit/php-code-coverage (9.2.32) - Locking phpunit/php-file-iterator (3.0.6) - Locking phpunit/php-invoker (3.1.1) - Locking phpunit/php-text-template (2.0.4) - Locking phpunit/php-timer (5.0.3) - Locking phpunit/phpunit (9.6.21) - Locking psr/container (2.0.2) - Locking psr/log (3.0.2) - Locking sabre/event (5.1.7) - Locking sebastian/cli-parser (1.0.2) - Locking sebastian/code-unit (1.0.8) - Locking sebastian/code-unit-reverse-lookup (2.0.3) - Locking sebastian/comparator (4.0.8) - Locking sebastian/complexity (2.0.3) - Locking sebastian/diff (4.0.6) - Locking sebastian/environment (5.1.5) - Locking sebastian/exporter (4.0.6) - Locking sebastian/global-state (5.0.7) - Locking sebastian/lines-of-code (1.0.4) - Locking sebastian/object-enumerator (4.0.4) - Locking sebastian/object-reflector (2.0.4) - Locking sebastian/recursion-context (4.0.5) - Locking sebastian/resource-operations (3.0.4) - Locking sebastian/type (3.2.1) - Locking sebastian/version (3.0.2) - Locking squizlabs/php_codesniffer (3.9.0) - Locking symfony/console (v7.1.6) - Locking symfony/deprecation-contracts (v3.5.0) - Locking symfony/polyfill-ctype (v1.31.0) - Locking symfony/polyfill-intl-grapheme (v1.31.0) - Locking symfony/polyfill-intl-normalizer (v1.31.0) - Locking symfony/polyfill-mbstring (v1.31.0) - Locking symfony/polyfill-php80 (v1.31.0) - Locking symfony/service-contracts (v3.5.0) - Locking symfony/string (v7.1.6) - Locking theseer/tokenizer (1.2.3) - Locking tysonandre/var_representation_polyfill (0.1.3) - Locking webmozart/assert (1.11.0) Writing lock file Installing dependencies from lock file (including require-dev) Package operations: 64 installs, 0 updates, 0 removals 0 [>---------------------------] 0 [->--------------------------] - Installing squizlabs/php_codesniffer (3.9.0): Extracting archive - Installing dealerdirect/phpcodesniffer-composer-installer (v1.0.0): Extracting archive - Installing composer/pcre (3.3.1): Extracting archive - Installing symfony/polyfill-php80 (v1.31.0): Extracting archive - Installing phpcsstandards/phpcsutils (1.0.11): Extracting archive - Installing phpcsstandards/phpcsextra (1.2.1): Extracting archive - Installing symfony/polyfill-mbstring (v1.31.0): Extracting archive - Installing composer/spdx-licenses (1.5.8): Extracting archive - Installing composer/semver (3.4.2): Extracting archive - Installing mediawiki/mediawiki-codesniffer (v44.0.0): Extracting archive - Installing symfony/polyfill-intl-normalizer (v1.31.0): Extracting archive - Installing symfony/polyfill-intl-grapheme (v1.31.0): Extracting archive - Installing symfony/polyfill-ctype (v1.31.0): Extracting archive - Installing symfony/string (v7.1.6): Extracting archive - Installing symfony/deprecation-contracts (v3.5.0): Extracting archive - Installing psr/container (2.0.2): Extracting archive - Installing symfony/service-contracts (v3.5.0): Extracting archive - Installing symfony/console (v7.1.6): Extracting archive - Installing mediawiki/minus-x (1.1.3): Extracting archive - Installing tysonandre/var_representation_polyfill (0.1.3): Extracting archive - Installing sabre/event (5.1.7): Extracting archive - Installing netresearch/jsonmapper (v4.5.0): Extracting archive - Installing microsoft/tolerant-php-parser (v0.1.2): Extracting archive - Installing webmozart/assert (1.11.0): Extracting archive - Installing phpstan/phpdoc-parser (1.33.0): Extracting archive - Installing phpdocumentor/reflection-common (2.2.0): Extracting archive - Installing doctrine/deprecations (1.1.3): Extracting archive - Installing phpdocumentor/type-resolver (1.8.2): Extracting archive - Installing phpdocumentor/reflection-docblock (5.4.1): Extracting archive - Installing felixfbecker/advanced-json-rpc (v3.2.1): Extracting archive - Installing psr/log (3.0.2): Extracting archive - Installing composer/xdebug-handler (3.0.5): Extracting archive - Installing phan/phan (5.4.5): Extracting archive - Installing php-parallel-lint/php-console-color (v1.0.1): Extracting archive - Installing php-parallel-lint/php-console-highlighter (v1.0.0): Extracting archive - Installing php-parallel-lint/php-parallel-lint (v1.4.0): Extracting archive - Installing sebastian/version (3.0.2): Extracting archive - Installing sebastian/type (3.2.1): Extracting archive - Installing sebastian/resource-operations (3.0.4): Extracting archive - Installing sebastian/recursion-context (4.0.5): Extracting archive - Installing sebastian/object-reflector (2.0.4): Extracting archive - Installing sebastian/object-enumerator (4.0.4): Extracting archive - Installing sebastian/global-state (5.0.7): Extracting archive - Installing sebastian/exporter (4.0.6): Extracting archive - Installing sebastian/environment (5.1.5): Extracting archive - Installing sebastian/diff (4.0.6): Extracting archive - Installing sebastian/comparator (4.0.8): Extracting archive - Installing sebastian/code-unit (1.0.8): Extracting archive - Installing sebastian/cli-parser (1.0.2): Extracting archive - Installing phpunit/php-timer (5.0.3): Extracting archive - Installing phpunit/php-text-template (2.0.4): Extracting archive - Installing phpunit/php-invoker (3.1.1): Extracting archive - Installing phpunit/php-file-iterator (3.0.6): Extracting archive - Installing theseer/tokenizer (1.2.3): Extracting archive - Installing nikic/php-parser (v5.3.1): Extracting archive - Installing sebastian/lines-of-code (1.0.4): Extracting archive - Installing sebastian/complexity (2.0.3): Extracting archive - Installing sebastian/code-unit-reverse-lookup (2.0.3): Extracting archive - Installing phpunit/php-code-coverage (9.2.32): Extracting archive - Installing phar-io/version (3.2.1): Extracting archive - Installing phar-io/manifest (2.0.4): Extracting archive - Installing myclabs/deep-copy (1.12.0): Extracting archive - Installing doctrine/instantiator (2.0.0): Extracting archive - Installing phpunit/phpunit (9.6.21): Extracting archive 0/62 [>---------------------------] 0% 20/62 [=========>------------------] 32% 34/62 [===============>------------] 54% 49/62 [======================>-----] 79% 59/62 [==========================>-] 95% 62/62 [============================] 100% 5 package suggestions were added by new dependencies, use `composer suggest` to see details. Generating autoload files 42 packages you are using are looking for funding. Use the `composer fund` command to find out more! --- stdout --- PHP CodeSniffer Config installed_paths set to ../../mediawiki/mediawiki-codesniffer,../../phpcsstandards/phpcsextra,../../phpcsstandards/phpcsutils --- end --- Upgrading c:mediawiki/mediawiki-codesniffer from 44.0.0 -> 45.0.0 $ /usr/bin/composer update --- stderr --- Loading composer repositories with package information Updating dependencies Lock file operations: 0 installs, 4 updates, 0 removals - Upgrading composer/semver (3.4.2 => 3.4.3) - Upgrading mediawiki/mediawiki-codesniffer (v44.0.0 => v45.0.0) - Upgrading phpcsstandards/phpcsutils (1.0.11 => 1.0.12) - Upgrading squizlabs/php_codesniffer (3.9.0 => 3.10.3) Writing lock file Installing dependencies from lock file (including require-dev) Package operations: 0 installs, 4 updates, 0 removals 0 [>---------------------------] 0 [->--------------------------] - Upgrading squizlabs/php_codesniffer (3.9.0 => 3.10.3): Extracting archive - Upgrading phpcsstandards/phpcsutils (1.0.11 => 1.0.12): Extracting archive - Upgrading composer/semver (3.4.2 => 3.4.3): Extracting archive - Upgrading mediawiki/mediawiki-codesniffer (v44.0.0 => v45.0.0): Extracting archive 0/4 [>---------------------------] 0% 3/4 [=====================>------] 75% 4/4 [============================] 100% Generating autoload files 42 packages you are using are looking for funding. Use the `composer fund` command to find out more! No security vulnerability advisories found --- stdout --- PHP CodeSniffer Config installed_paths set to ../../mediawiki/mediawiki-codesniffer,../../phpcsstandards/phpcsextra,../../phpcsstandards/phpcsutils --- end --- Previously failing phpcs rules: {'MediaWiki.Usage.ForbiddenFunctions.assert'} $ vendor/bin/phpcs --report=json --- stdout --- {"totals":{"errors":0,"warnings":48,"fixable":0},"files":{"\/src\/repo\/src\/VarLinksSet.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/TaintednessWithError.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/TaintednessLoopVisitor.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/phan-interaction-test-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/LinksSet.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/GenericSecurityCheckPlugin.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/bootstrap.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/internal\/make_phar.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/PreTaintednessVisitor.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/self-phan-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/scripts\/generic-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/SingleMethodLinks.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/MWPreVisitor.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/TestMediaWikiSecurityCheckPlugin.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/scripts\/base-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/MediaWikiHooksHelper.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/PreservedTaintedness.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/integration-test-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/FunctionCausedByLines.php":{"errors":0,"warnings":4,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":73,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":95,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":142,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":165,"column":9}]},"\/src\/repo\/src\/ParamLinksOffsets.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/ReturnObjectsCollectVisitor.php":{"errors":0,"warnings":2,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":28,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":243,"column":9}]},"\/src\/repo\/src\/TaintednessAccessorsTrait.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/TaintednessAssignVisitor.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/TaintednessBackpropVisitor.php":{"errors":0,"warnings":1,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":283,"column":9}]},"\/src\/repo\/src\/FunctionTaintedness.php":{"errors":0,"warnings":4,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":88,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":104,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":112,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":121,"column":9}]},"\/src\/repo\/MediaWikiSecurityCheckPlugin.php":{"errors":0,"warnings":1,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":246,"column":9}]},"\/src\/repo\/tests\/SecurityCheckTest.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/MethodLinks.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/Taintedness.php":{"errors":0,"warnings":1,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":74,"column":13}]},"\/src\/repo\/src\/CausedByLines.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/SecurityCheckPlugin.php":{"errors":0,"warnings":1,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":465,"column":21}]},"\/src\/repo\/src\/MWVisitor.php":{"errors":0,"warnings":12,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":57,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":59,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":192,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":261,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":295,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":411,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":569,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":612,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":682,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":700,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":805,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":973,"column":13}]},"\/src\/repo\/src\/TaintednessVisitor.php":{"errors":0,"warnings":7,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":133,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":872,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":895,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":946,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":952,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":996,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1025,"column":13}]},"\/src\/repo\/src\/TaintednessBaseVisitor.php":{"errors":0,"warnings":15,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":215,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":274,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":858,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":901,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":930,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":959,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":962,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1127,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1252,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1330,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1560,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1755,"column":21},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1787,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":2129,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":2251,"column":13}]}}} --- end --- PHPCS run failed $ vendor/bin/phpcs --report=json --- stdout --- {"totals":{"errors":0,"warnings":48,"fixable":0},"files":{"\/src\/repo\/src\/VarLinksSet.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/TaintednessWithError.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/TaintednessLoopVisitor.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/LinksSet.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/phan-interaction-test-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/GenericSecurityCheckPlugin.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/bootstrap.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/internal\/make_phar.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/SingleMethodLinks.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/PreTaintednessVisitor.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/self-phan-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/scripts\/base-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/scripts\/generic-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/MWPreVisitor.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/MediaWikiHooksHelper.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/TestMediaWikiSecurityCheckPlugin.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/tests\/integration-test-config.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/ReturnObjectsCollectVisitor.php":{"errors":0,"warnings":2,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":28,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":243,"column":9}]},"\/src\/repo\/src\/TaintednessAccessorsTrait.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/PreservedTaintedness.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/TaintednessAssignVisitor.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/ParamLinksOffsets.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/FunctionCausedByLines.php":{"errors":0,"warnings":4,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":73,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":95,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":142,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":165,"column":9}]},"\/src\/repo\/src\/TaintednessBackpropVisitor.php":{"errors":0,"warnings":1,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":283,"column":9}]},"\/src\/repo\/src\/FunctionTaintedness.php":{"errors":0,"warnings":4,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":88,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":104,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":112,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":121,"column":9}]},"\/src\/repo\/MediaWikiSecurityCheckPlugin.php":{"errors":0,"warnings":1,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":246,"column":9}]},"\/src\/repo\/tests\/SecurityCheckTest.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/CausedByLines.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/SecurityCheckPlugin.php":{"errors":0,"warnings":1,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":465,"column":21}]},"\/src\/repo\/src\/MethodLinks.php":{"errors":0,"warnings":0,"messages":[]},"\/src\/repo\/src\/Taintedness.php":{"errors":0,"warnings":1,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":74,"column":13}]},"\/src\/repo\/src\/MWVisitor.php":{"errors":0,"warnings":12,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":57,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":59,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":192,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":261,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":295,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":411,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":569,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":612,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":682,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":700,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":805,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":973,"column":13}]},"\/src\/repo\/src\/TaintednessVisitor.php":{"errors":0,"warnings":7,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":133,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":872,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":895,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":946,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":952,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":996,"column":13},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1025,"column":13}]},"\/src\/repo\/src\/TaintednessBaseVisitor.php":{"errors":0,"warnings":15,"messages":[{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":215,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":274,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":858,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":901,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":930,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":959,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":962,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1127,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1252,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1330,"column":17},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1560,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1755,"column":21},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":1787,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":2129,"column":9},{"message":"assert should not be used","source":"MediaWiki.Usage.ForbiddenFunctions.assert","severity":5,"fixable":false,"type":"WARNING","line":2251,"column":13}]}}} --- end --- $ git checkout .phpcs.xml --- stderr --- Updated 1 path from the index --- stdout --- --- end --- $ /usr/bin/composer install --- stderr --- Installing dependencies from lock file (including require-dev) Verifying lock file contents can be installed on current platform. Nothing to install, update or remove Generating autoload files 42 packages you are using are looking for funding. Use the `composer fund` command to find out more! --- stdout --- --- end --- $ /usr/bin/composer test --- stderr --- > parallel-lint . --exclude vendor --exclude tests/integration > phpcs -p -s > minus-x check . > ./tests/run-phan-on-plugin.sh Parsing files... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 54 / 2464 ( 2%) 59MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 108 / 2464 ( 4%) 70MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 162 / 2464 ( 6%) 112MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 216 / 2464 ( 9%) 148MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 270 / 2464 ( 11%) 174MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 324 / 2464 ( 13%) 179MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 378 / 2464 ( 18%) 207MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 432 / 2464 ( 18%) 207MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 486 / 2464 ( 20%) 218MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 540 / 2464 ( 23%) 238MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 594 / 2464 ( 27%) 248MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 648 / 2464 ( 27%) 248MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 702 / 2464 ( 35%) 255MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 756 / 2464 ( 35%) 255MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 810 / 2464 ( 35%) 255MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 864 / 2464 ( 35%) 255MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 918 / 2464 ( 40%) 260MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 972 / 2464 ( 40%) 260MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1026 / 2464 ( 49%) 267MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1080 / 2464 ( 49%) 267MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1134 / 2464 ( 49%) 267MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1188 / 2464 ( 49%) 267MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1242 / 2464 ( 56%) 277MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1296 / 2464 ( 56%) 277MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1350 / 2464 ( 56%) 277MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1404 / 2464 ( 66%) 284MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1458 / 2464 ( 66%) 284MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1512 / 2464 ( 66%) 284MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1566 / 2464 ( 66%) 284MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1620 / 2464 ( 66%) 284MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1674 / 2464 ( 83%) 289MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1728 / 2464 ( 83%) 289MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1782 / 2464 ( 83%) 289MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1836 / 2464 ( 83%) 289MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1890 / 2464 ( 83%) 289MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1944 / 2464 ( 83%) 289MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1998 / 2464 ( 83%) 289MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2052 / 2464 ( 83%) 289MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2106 / 2464 ( 92%) 295MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2160 / 2464 ( 92%) 295MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2214 / 2464 ( 92%) 295MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2268 / 2464 ( 92%) 295MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2322 / 2464 ( 99%) 303MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2376 / 2464 ( 99%) 303MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2430 / 2464 ( 99%) 303MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 2464 / 2464 (100%) 304MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 358MB Analyzing functions... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 361MB Analyzing methods... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 374MB Analyzing files... ░░░░░░░░░░░░░░░░░░░░░░░░░ 25 / 25 (100%) 394MB Checking for dead code... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 397MB > phpunit > ./tests/run-phan-tests.sh + php -m + grep -q '^ast$' + [[ ! -d vendor/phan/phan/tests ]] + TESTDIR=phan-tests + mv ./phpunit.xml.dist phpunit-OLD.xml + cp composer.json composer-OLD.json + trap restoreEverything exit + cp -r vendor/phan/phan/tests/ phan-tests + cp -r vendor/phan/phan/.phan . + cp vendor/phan/phan/phan vendor/phan/phan/phpunit.xml . + DISCARD_TESTS='(__FakeSelfTest|__FakeSelfFallbackTest|__FakeToolTest|__FakePhantasmTest|__FakeFixerTest)' + sed -r -i 's/.*(__FakeSelfTest|__FakeSelfFallbackTest|__FakeToolTest|__FakePhantasmTest|__FakeFixerTest).*//' phan-tests/run_all_tests + sed -r -i 's/tests\/run_test/phan-tests\/run_test/' phan-tests/run_all_tests + sed -r -i 's/cd tests\//cd phan-tests\//' phan-tests/run_test + sed -r -i 's/require_once __DIR__ . '\''\/src/require_once __DIR__ . '\''\/vendor\/phan\/phan\/src/' ./phan + sed -r -i 's/tests\//phan-tests\//' phpunit.xml + sed -r -i 's/.\/tests\//.\/phan-tests\//' phan-tests/bootstrap.php + sed -r -i 's/\/src\/Phan/\/vendor\/phan\/phan\/src\/Phan/' phan-tests/bootstrap.php + sed -r -i 's/'\''\/src/'\''\/vendor\/phan\/phan\/src/' phan-tests/Phan/Language/UnionTypeTest.php + sed -i 's/verbose="false"/verbose="true"/' phpunit.xml + EXCLUDED_TESTS_ROOT=(ForkPoolTest.php SoapTest.php CLITest.php PluginV3Test.php Internal LanguageServer) ++ IFS='|' ++ echo 'ForkPoolTest.php|SoapTest.php|CLITest.php|PluginV3Test.php|Internal|LanguageServer' + EXCLUDED_TESTS_ROOT_REGEX='ForkPoolTest.php|SoapTest.php|CLITest.php|PluginV3Test.php|Internal|LanguageServer' + sed -r -i 's/<(file|directory)>.+(ForkPoolTest.php|SoapTest.php|CLITest.php|PluginV3Test.php|Internal|LanguageServer)<\/(file|directory)>//' phpunit.xml + for EXCLUDED_FILE in "${EXCLUDED_TESTS_ROOT[@]}" + rm -rf phan-tests/Phan/ForkPoolTest.php + for EXCLUDED_FILE in "${EXCLUDED_TESTS_ROOT[@]}" + rm -rf phan-tests/Phan/SoapTest.php + for EXCLUDED_FILE in "${EXCLUDED_TESTS_ROOT[@]}" + rm -rf phan-tests/Phan/CLITest.php + for EXCLUDED_FILE in "${EXCLUDED_TESTS_ROOT[@]}" + rm -rf phan-tests/Phan/PluginV3Test.php + for EXCLUDED_FILE in "${EXCLUDED_TESTS_ROOT[@]}" + rm -rf phan-tests/Phan/Internal + for EXCLUDED_FILE in "${EXCLUDED_TESTS_ROOT[@]}" + rm -rf phan-tests/Phan/LanguageServer + rm -r phan-tests/Phan/Language/Internal + rm phan-tests/files/src/0545_require_testing.php phan-tests/Phan/Language/FileRefTest.php + sed -r -i ':a;N;$!ba;s/src\/\S+41 PhanPluginNonBoolInLogicalArith[^\n]+\n//' phan-tests/plugin_test/expected/160_useless_return.php.expected + sed -r -i 's/(src\/\S+:(30|37)) PhanPartialTypeMismatchReturn.+/&\n\1 PhanTypeInvalidLeftOperandOfNumericOp Invalid operator: left operand of * is string (expected number)/' phan-tests/plugin_test/expected/152_phan_pure_annotation.php.expected + sed -r -i s/backupStaticAttributesBlacklist/backupStaticAttributesExcludeList/ phan-tests/Phan/BaseTest.php + grep -rl assertRegExp phan-tests + xargs sed -r -i 's/>assertRegExp\(/>assertMatchesRegularExpression\(/' + grep -rl assertNotRegExp phan-tests + xargs sed -r -i 's/>assertNotRegExp\(/>assertDoesNotMatchRegularExpression\(/' + sed -r -i 's/"SecurityCheckPlugin\\\\": "src"/\0, "Phan\\\\Tests\\\\": "phan-tests\/Phan"/' composer.json + composer dump-autoload + SECCHECK_ISSUES=''\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', ' + SECCHECK_ISSUES+=''\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', ' + SECCHECK_ISSUES+=''\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'',' + INNER_TEST_DIRS='misc/rewriting_test misc/fallback_test misc/config_override_test misc/empty_methods_plugin_test plugin_test real_types_test infer_missing_types_test' + for DIR in $INNER_TEST_DIRS + CFG_PATH=phan-tests/misc/rewriting_test/.phan/config.php + JUMP= + [[ misc/rewriting_test == \m\i\s\c* ]] + JUMP='..\/' + grep -q 'plugins['\''"] => \[' phan-tests/misc/rewriting_test/.phan/config.php + sed -r -i 's/'\''plugins['\''"] => \[/\0\n'\''.\/..\/..\/..\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/misc/rewriting_test/.phan/config.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/misc/rewriting_test/.phan/config.php + sed -r -i 's/^return \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/misc/rewriting_test/.phan/config.php + for DIR in $INNER_TEST_DIRS + CFG_PATH=phan-tests/misc/fallback_test/.phan/config.php + JUMP= + [[ misc/fallback_test == \m\i\s\c* ]] + JUMP='..\/' + grep -q 'plugins['\''"] => \[' phan-tests/misc/fallback_test/.phan/config.php + sed -r -i 's/'\''plugins['\''"] => \[/\0\n'\''.\/..\/..\/..\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/misc/fallback_test/.phan/config.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/misc/fallback_test/.phan/config.php + sed -r -i 's/^return \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/misc/fallback_test/.phan/config.php + for DIR in $INNER_TEST_DIRS + CFG_PATH=phan-tests/misc/config_override_test/.phan/config.php + JUMP= + [[ misc/config_override_test == \m\i\s\c* ]] + JUMP='..\/' + grep -q 'plugins['\''"] => \[' phan-tests/misc/config_override_test/.phan/config.php + sed -r -i 's/'\''plugins['\''"] => \[/\0\n'\''.\/..\/..\/..\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/misc/config_override_test/.phan/config.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/misc/config_override_test/.phan/config.php + sed -r -i 's/^return \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/misc/config_override_test/.phan/config.php + for DIR in $INNER_TEST_DIRS + CFG_PATH=phan-tests/misc/empty_methods_plugin_test/.phan/config.php + JUMP= + [[ misc/empty_methods_plugin_test == \m\i\s\c* ]] + JUMP='..\/' + grep -q 'plugins['\''"] => \[' phan-tests/misc/empty_methods_plugin_test/.phan/config.php + sed -r -i 's/'\''plugins['\''"] => \[/\0\n'\''.\/..\/..\/..\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/misc/empty_methods_plugin_test/.phan/config.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/misc/empty_methods_plugin_test/.phan/config.php + sed -r -i 's/^return \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/misc/empty_methods_plugin_test/.phan/config.php + for DIR in $INNER_TEST_DIRS + CFG_PATH=phan-tests/plugin_test/.phan/config.php + JUMP= + [[ plugin_test == \m\i\s\c* ]] + grep -q 'plugins['\''"] => \[' phan-tests/plugin_test/.phan/config.php + sed -r -i 's/'\''plugins['\''"] => \[/\0\n'\''.\/..\/..\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/plugin_test/.phan/config.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/plugin_test/.phan/config.php + sed -r -i 's/^return \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/plugin_test/.phan/config.php + for DIR in $INNER_TEST_DIRS + CFG_PATH=phan-tests/real_types_test/.phan/config.php + JUMP= + [[ real_types_test == \m\i\s\c* ]] + grep -q 'plugins['\''"] => \[' phan-tests/real_types_test/.phan/config.php + sed -r -i 's/'\''plugins['\''"] => \[/\0\n'\''.\/..\/..\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/real_types_test/.phan/config.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/real_types_test/.phan/config.php + sed -r -i 's/^return \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/real_types_test/.phan/config.php + for DIR in $INNER_TEST_DIRS + CFG_PATH=phan-tests/infer_missing_types_test/.phan/config.php + JUMP= + [[ infer_missing_types_test == \m\i\s\c* ]] + grep -q 'plugins['\''"] => \[' phan-tests/infer_missing_types_test/.phan/config.php + sed -r -i 's/'\''plugins['\''"] => \[/\0\n'\''.\/..\/..\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/infer_missing_types_test/.phan/config.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/infer_missing_types_test/.phan/config.php + sed -r -i 's/^return \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/infer_missing_types_test/.phan/config.php + sed -r -i 's/^return \[/\0 '\''plugins'\'' => [ '\''.\/MediaWikiSecurityCheckPlugin.php'\'' ],/' phan-tests/.phan_for_test/config.php + sed -r -i 's/'\''suppress_issue_types'\'' => \[/\0 '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'',/' phan-tests/.phan_for_test/config.php + BASE_TESTS='PHP70Test PHP72Test PHP73Test PHP74Test PHP80Test' + for BASE_TEST in $BASE_TESTS + grep -q ''\''plugins'\'' =>' phan-tests/Phan/PHP70Test.php + sed -r -i 's/'\''plugins'\'' => \[/\0'\''.\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/Phan/PHP70Test.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/Phan/PHP70Test.php + sed -r -i 's/OVERRIDES = \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/Phan/PHP70Test.php + for BASE_TEST in $BASE_TESTS + grep -q ''\''plugins'\'' =>' phan-tests/Phan/PHP72Test.php + sed -r -i 's/OVERRIDES = \[/\0'\''plugins'\'' => ['\''.\/MediaWikiSecurityCheckPlugin.php'\''],/' phan-tests/Phan/PHP72Test.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/Phan/PHP72Test.php + sed -r -i 's/OVERRIDES = \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/Phan/PHP72Test.php + for BASE_TEST in $BASE_TESTS + grep -q ''\''plugins'\'' =>' phan-tests/Phan/PHP73Test.php + sed -r -i 's/OVERRIDES = \[/\0'\''plugins'\'' => ['\''.\/MediaWikiSecurityCheckPlugin.php'\''],/' phan-tests/Phan/PHP73Test.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/Phan/PHP73Test.php + sed -r -i 's/OVERRIDES = \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/Phan/PHP73Test.php + for BASE_TEST in $BASE_TESTS + grep -q ''\''plugins'\'' =>' phan-tests/Phan/PHP74Test.php + sed -r -i 's/'\''plugins'\'' => \[/\0'\''.\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/Phan/PHP74Test.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/Phan/PHP74Test.php + sed -r -i 's/OVERRIDES = \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/Phan/PHP74Test.php + for BASE_TEST in $BASE_TESTS + grep -q ''\''plugins'\'' =>' phan-tests/Phan/PHP80Test.php + sed -r -i 's/'\''plugins'\'' => \[/\0'\''.\/MediaWikiSecurityCheckPlugin.php'\'',/' phan-tests/Phan/PHP80Test.php + grep -q 'suppress_issue_types['\''"] => \[' phan-tests/Phan/PHP80Test.php + sed -r -i 's/OVERRIDES = \[/\0 '\''suppress_issue_types'\'' => [ '\''SecurityCheck-DoubleEscaped'\'', '\''SecurityCheck-SQLInjection'\'', '\''SecurityCheck-XSS'\'', '\''SecurityCheck-ShellInjection'\'', '\''SecurityCheck-PHPSerializeInjection'\'', '\''SecurityCheck-CUSTOM1'\'', '\''SecurityCheck-CUSTOM2'\'', '\''SecurityCheck-PathTraversal'\'', '\''SecurityCheck-RCE'\'', '\''SecurityCheck-ReDoS'\'', '\''SecurityCheck-LikelyFalsePositive'\'', ],/' phan-tests/Phan/PHP80Test.php + export PHAN_TEST_PARALLEL=0 + PHAN_TEST_PARALLEL=0 + ./phan-tests/run_all_tests If you are using php 7.3+, you may wish to run 'composer install --ignore-platform-reqs' in internal/paratest/ to run tests in paratest. - **Phan's paratest configuration is not supported by paratest's maintainers - if you encounter issues, run vendor/bin/phpunit instead.** - (The separate paratest installation is a kludgy workaround so that other dependencies in Phan's composer.lock such as composer/semver are not held back) Parsing files... ░░░░░ 5 / 5 (100%) 28MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 31MB Analyzing functions... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 31MB Analyzing methods... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 32MB Analyzing files... ░░░░░ 5 / 5 (100%) 39MB Parsing files... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 54 / 216 ( 56%) 40MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 108 / 216 ( 56%) 40MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 162 / 216 ( 96%) 43MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 216 / 216 (100%) 43MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 45MB Analyzing functions... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 46MB Analyzing methods... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 46MB Analyzing files... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 54 / 216 ( 26%) 58MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 108 / 216 ( 50%) 60MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 162 / 216 ( 75%) 62MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 216 / 216 (100%) 63MB Checking for dead code... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 63MB ./test.sh: line 45: type: colordiff: not found Parsing files... ░░░░░░░░░░ 10 / 10 (100%) 17MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 21MB Analyzing functions... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 21MB Analyzing methods... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 34MB Analyzing files... ░░░░░░░░░░ 10 / 10 (100%) 42MB Checking for dead code... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 42MB ./test.sh: line 33: type: colordiff: not found Parsing files... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 54 / 82 (100%) 33MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 82 / 82 (100%) 33MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 33MB Analyzing functions... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 33MB Analyzing methods... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 33MB Analyzing files... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 54 / 82 (100%) 44MB ░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 82 / 82 (100%) 44MB Parsing files... ░ 1 / 1 (100%) 12MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 16MB Analyzing files... ░ 1 / 1 (100%) 31MB Parsing files... ░░░░░░ 6 / 6 (100%) 18MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 21MB Analyzing functions... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 34MB Analyzing methods... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 35MB Analyzing files... ░░░░░░ 6 / 6 (100%) 42MB Analyzing files a second time... ░░░░░░ 6 / 6 (100%) 42MB Checking for dead code... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 42MB ./test.sh: line 33: type: colordiff: not found Parsing files... ░ 1 / 1 (100%) 12MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 19MB Analyzing methods... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 19MB Analyzing files... ░ 1 / 1 (100%) 35MB Analyzing files a second time... ░ 1 / 1 (100%) 38MB Checking for dead code... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 38MB ./test.sh: line 26: type: colordiff: not found Parsing files... ░ 1 / 1 (100%) 12MB Analyzing classes... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 32MB Analyzing functions... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 32MB Analyzing methods... ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 32MB Analyzing files... ░ 1 / 1 (100%) 35MB + restoreEverything + rm -rf phan-tests ./phan .phan phpunit.xml + mv phpunit-OLD.xml phpunit.xml.dist + mv composer-OLD.json composer.json + composer dump-autoload --- stdout --- PHP 8.2.20 | 10 parallel jobs ......................................................... 57/57 (100%) Checked 57 files in 0.3 seconds No syntax error found .................................. 34 / 34 (100%) Time: 1.46 secs; Memory: 8MB MinusX ====== Processing /src/repo... ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. ............................................................. .................... All good! Starting phan PHPUnit 9.6.21 by Sebastian Bergmann and contributors. ............................................................... 63 / 731 ( 8%) ............................................................... 126 / 731 ( 17%) ............................................................... 189 / 731 ( 25%) ............................................................... 252 / 731 ( 34%) ............................................................... 315 / 731 ( 43%) ............................................................... 378 / 731 ( 51%) ............................................................... 441 / 731 ( 60%) ............................................................... 504 / 731 ( 68%) ............................................................... 567 / 731 ( 77%) .......................................S....................... 630 / 731 ( 86%) ............................................................... 693 / 731 ( 94%) ...................................... 731 / 731 (100%) Time: 01:13.937, Memory: 90.00 MB OK, but incomplete, skipped, or risky tests! Tests: 731, Assertions: 760, Skipped: 1. Generating autoload files Generated autoload files Running test suite: __FakeAllPHPUnitTests PHPUnit 9.6.21 by Sebastian Bergmann and contributors. Runtime: PHP 8.2.20 Configuration: /src/repo/phpunit.xml Warning: Your XML configuration validates against a deprecated schema. Suggestion: Migrate your XML configuration using "--migrate-configuration"! ............................................................. 61 / 2022 ( 3%) ............................................................. 122 / 2022 ( 6%) ............................................................. 183 / 2022 ( 9%) ............................................................. 244 / 2022 ( 12%) ............................................................. 305 / 2022 ( 15%) ............................................................. 366 / 2022 ( 18%) ............................................................. 427 / 2022 ( 21%) ............................................................. 488 / 2022 ( 24%) ............................................................. 549 / 2022 ( 27%) ............................................................. 610 / 2022 ( 30%) ............................................................. 671 / 2022 ( 33%) ............................................................. 732 / 2022 ( 36%) ............................................................. 793 / 2022 ( 39%) ............................................................. 854 / 2022 ( 42%) ............................................................. 915 / 2022 ( 45%) ............................................................. 976 / 2022 ( 48%) ............................................................. 1037 / 2022 ( 51%) ............................................................. 1098 / 2022 ( 54%) ............................................................. 1159 / 2022 ( 57%) ............................................................. 1220 / 2022 ( 60%) ............................................................. 1281 / 2022 ( 63%) ............................................................. 1342 / 2022 ( 66%) ............................................................. 1403 / 2022 ( 69%) ............................................................. 1464 / 2022 ( 72%) ............................................................. 1525 / 2022 ( 75%) ............................................................. 1586 / 2022 ( 78%) .............................................I............... 1647 / 2022 ( 81%) ............................................................. 1708 / 2022 ( 84%) ............................................................. 1769 / 2022 ( 87%) ............................................................. 1830 / 2022 ( 90%) .............S............................................... 1891 / 2022 ( 93%) ............................................................. 1952 / 2022 ( 96%) ....................S........................................ 2013 / 2022 ( 99%) ......... 2022 / 2022 (100%) Time: 00:58.616, Memory: 100.00 MB There was 1 incomplete test: 1) Phan\Tests\AST\TolerantASTConverter\ConversionTest::testFallbackFromParser with data set #39 ('/src/repo/phan-tests/misc/fal...le.php', 85) php-ast cannot parse php8.0 syntax when running in php7.4 or older /src/repo/phan-tests/Phan/AST/TolerantASTConverter/ConversionTest.php:220 -- There were 2 skipped tests: 1) Phan\Tests\PHP72Test::testFiles with data set "0006_deprecated_create_internal_function.php" (array('./phan-tests/php72_files/src/...on.php'), './phan-tests/php72_files/expe...pected') Skipping test for 0006_deprecated_create_internal_function.php: Skip create_internal_function was removed /src/repo/phan-tests/Phan/PHP72Test.php:50 2) Phan\Tests\PHP83Test::testFiles with data set "001_typed_class_constant.php" (array('./phan-tests/php83_files/src/...nt.php'), './phan-tests/php83_files/expe...pected') Skipping test for 001_typed_class_constant.php: Skip PHP 8.3 is required /src/repo/phan-tests/Phan/PHP83Test.php:61 OK, but incomplete, skipped, or risky tests! Tests: 2022, Assertions: 5900, Skipped: 2, Incomplete: 1. Running test suite: __FakeRewritingTest Running phan in '/src/repo/phan-tests/misc/rewriting_test' ... src/000_ast_rewriting_check.php:11 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $a of type int but \strlen() takes string src/000_ast_rewriting_check.php:24 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $a of type non-zero-int but \strlen() takes string src/001_phpdoc_rewriting_test.php:8 PhanUndeclaredTypeParameter Parameter $z has undeclared type \missingClass src/001_phpdoc_rewriting_test.php:9 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $x of type float|int but \strlen() takes string src/003_preg_match.php:13 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $matches of type array{0:string} but \intdiv() takes int src/004_crash_rewrite_if.php:2 PhanInvalidNode Expected left side of assignment to be a variable src/004_crash_rewrite_if.php:2 PhanSyntaxError syntax error, unexpected token "=" (at column 14) src/004_crash_rewrite_if.php:2 PhanUndeclaredGlobalVariable Global variable $p2 is undeclared Comparing the output: Files expected/all_output.expected and output all_output.actual are identical Running test suite: __FakePluginTest Generating test cases Running phan in '/src/repo/phan-tests/plugin_test' ... src/000_plugins.php:4 PhanPluginInstanceOfObject Cannot call instanceof against `object` src/000_plugins.php:4 PhanTypeInvalidInstanceof Found an instanceof class name object of type object, but class name must be a valid object or a string src/000_plugins.php:9 PhanUnusedGlobalFunctionParameter Parameter $a is never used src/000_plugins.php:10 PhanPluginDollarDollar $$ Variables are not allowed. src/000_plugins.php:18 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(0) detected in array - the earlier entry '0' at line 17 will be ignored. src/000_plugins.php:21 PhanPluginMixedKeyNoKey Should not mix array entries of the form [key => value,] with entries of the form [value,]. src/000_plugins.php:28 PhanPluginUndeclaredVariableIsset undeclared variable $foo in isset() src/000_plugins.php:29 PhanPluginComplexVariableInIsset Unanalyzable complex variable expression in isset src/000_plugins.php:29 PhanPluginDollarDollar $$ Variables are not allowed. src/000_plugins.php:33 PhanPluginNonBoolBranch Non bool value of type array evaluated in if clause src/000_plugins.php:40 PhanPluginNonBoolBranch Non bool value of type array evaluated in if clause src/000_plugins.php:47 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: '2e3' == '2000' (result is true) src/000_plugins.php:47 PhanPluginNumericalComparison non numerical values compared by the operators '==' or '!=' src/000_plugins.php:48 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: '2e3' === '2000' (result is false) src/000_plugins.php:49 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 2.0 !== 2 (result is true) src/000_plugins.php:49 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/000_plugins.php:50 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 2.0 != 2 (result is false) src/000_plugins.php:55 UnusedSuppression Element \testUnusedSuppressionPlugin suppresses issue PhanParamTooFew but does not use it src/000_plugins.php:61 PhanPluginUseReturnValueNoopVoid The function/method \testUnreferencedFunction() is declared to return void and it has no side effects src/000_plugins.php:61 PhanUnreferencedFunction Possibly zero references to function \testUnreferencedFunction() src/000_plugins.php:64 PhanCompatibleAutoload Declaring an autoloader with function __autoload() was deprecated in PHP 7.2 and is a fatal error in PHP 8.0+. Use spl_autoload_register() instead (supported since PHP 5.1). src/000_plugins.php:64 PhanNativePHPSyntaxCheckPlugin Saw error or notice for php --syntax-check: "Fatal error: __autoload() is no longer supported, use spl_autoload_register() instead" src/000_plugins.php:64 PhanPluginUseReturnValueNoopVoid The function/method \__autoload() is declared to return void and it has no side effects src/000_plugins.php:64 PhanUnusedGlobalFunctionParameter Parameter $className is never used src/000_plugins.php:66 PhanUnreferencedClass Possibly zero references to class \__autoload src/000_plugins.php:67 PhanUnreferencedConstant Possibly zero references to global constant \__autoload src/000_plugins.php:69 PhanPluginAlwaysReturnFunction Function \missingReturnType has a return type of int, but may fail to return a value src/000_plugins.php:74 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \missingReturnType() defined at src/000_plugins.php:69 src/000_plugins.php:77 PhanPluginAlwaysReturnMethod Method \ReturnChecks::missingReturnTypeSwitch has a return type of int, but may fail to return a value src/000_plugins.php:80 PhanThrowTypeAbsent \ReturnChecks::missingReturnTypeSwitch() can throw new \RuntimeException('saw 2') of type \RuntimeException here, but has no '@throws' declarations for that class src/000_plugins.php:93 PhanThrowTypeAbsent \ReturnChecks::missingReturnTypeSwitchGood() can throw new \RuntimeException('saw 3') of type \RuntimeException here, but has no '@throws' declarations for that class src/000_plugins.php:114 PhanUnusedVariable Unused definition of variable $x src/000_plugins.php:127 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $a of type int but \strlen() takes string src/000_plugins.php:133 PhanPluginUseReturnValueGenerator Expected to use the return value of the function/method \ReturnChecks::generator(int $x) returning a generator of type \Traversable src/000_plugins.php:138 DemoPluginMethodName Method \TestDemoPlugin::function cannot be called `function` src/000_plugins.php:138 PhanPluginUseReturnValueNoopVoid The function/method \TestDemoPlugin::function() is declared to return (empty union type) and it has no side effects src/000_plugins.php:139 DemoPluginPropertyName Property \TestDemoPlugin::property should not be called `property` src/000_plugins.php:139 PhanReadOnlyPublicProperty Possibly zero write references to public property \TestDemoPlugin->property src/000_plugins.php:145 PhanTypeInvalidInstanceof Found an instanceof class name mixed of type mixed, but class name must be a valid object or a string src/000_plugins.php:149 PhanTypeInvalidInstanceof Found an instanceof class name string of type string, but class name must be a valid object or a string src/001_dead_code.php:4 PhanRedefineFunction Function duplicateFnA defined at src/001_dead_code.php:4 was previously defined at src/001_dead_code.php:29 src/001_dead_code.php:8 PhanRedefineFunction Function duplicateFnB defined at src/001_dead_code.php:8 was previously defined at src/001_dead_code.php:33 src/001_dead_code.php:8 PhanUnreferencedFunction Possibly zero references to function \duplicateFnB() src/001_dead_code.php:13 PhanUnreferencedConstant Possibly zero references to global constant \Const1B src/001_dead_code.php:15 PhanRedefineClass Class \DuplicateClass001 defined at src/001_dead_code.php:15 was previously defined as Class \DuplicateClass001 at src/001_dead_code.php:39 src/001_dead_code.php:18 PhanReadOnlyPublicProperty Possibly zero write references to public property \DuplicateClass001::$static_prop1 src/001_dead_code.php:19 PhanUnreferencedPublicProperty Possibly zero references to public property \DuplicateClass001::$static_prop2 src/001_dead_code.php:21 PhanReadOnlyPublicProperty Possibly zero write references to public property \DuplicateClass001->instance_prop1 src/001_dead_code.php:22 PhanUnreferencedPublicProperty Possibly zero references to public property \DuplicateClass001->instance_prop2 src/001_dead_code.php:24 PhanPluginUseReturnValueNoopVoid The function/method \DuplicateClass001::f1() is declared to return (empty union type) and it has no side effects src/001_dead_code.php:25 PhanPluginUseReturnValueNoopVoid The function/method \DuplicateClass001::f2() is declared to return (empty union type) and it has no side effects src/001_dead_code.php:25 PhanUnreferencedPublicMethod Possibly zero references to public method \DuplicateClass001::f2() src/001_dead_code.php:26 PhanPluginUseReturnValueNoopVoid The function/method \DuplicateClass001::f3() is declared to return (empty union type) and it has no side effects src/001_dead_code.php:26 PhanUnreferencedPublicMethod Possibly zero references to public method \DuplicateClass001::f3() src/001_dead_code.php:29 PhanRedefineFunction Function duplicateFnA defined at src/001_dead_code.php:29 was previously defined at src/001_dead_code.php:4 src/001_dead_code.php:33 PhanRedefineFunction Function duplicateFnB defined at src/001_dead_code.php:33 was previously defined at src/001_dead_code.php:8 src/001_dead_code.php:33 PhanUnreferencedFunction Possibly zero references to function \duplicateFnB,1() src/001_dead_code.php:39 PhanRedefineClass Class \DuplicateClass001 defined at src/001_dead_code.php:39 was previously defined as Class \DuplicateClass001 at src/001_dead_code.php:15 src/001_dead_code.php:41 PhanUnreferencedPublicClassConstant Possibly zero references to public class constant \DuplicateClass001,1::D src/001_dead_code.php:44 PhanUnreferencedPublicProperty Possibly zero references to public property \DuplicateClass001,1::$static_prop2 src/001_dead_code.php:47 PhanUnreferencedPublicProperty Possibly zero references to public property \DuplicateClass001,1->instance_prop2 src/001_dead_code.php:49 PhanPluginUseReturnValueNoopVoid The function/method \DuplicateClass001,1::f1() is declared to return (empty union type) and it has no side effects src/001_dead_code.php:50 PhanPluginUseReturnValueNoopVoid The function/method \DuplicateClass001,1::f2() is declared to return (empty union type) and it has no side effects src/001_dead_code.php:50 PhanUnreferencedPublicMethod Possibly zero references to public method \DuplicateClass001,1::f2() src/001_dead_code.php:51 PhanPluginUseReturnValueNoopVoid The function/method \DuplicateClass001,1::f4() is declared to return (empty union type) and it has no side effects src/001_dead_code.php:51 PhanUnreferencedPublicMethod Possibly zero references to public method \DuplicateClass001,1::f4() src/001_dead_code.php:56 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \duplicateFnA() defined at src/001_dead_code.php:4 src/001_dead_code.php:58 PhanRedefinedClassReference Saw reference to \DuplicateClass001 declared at src/001_dead_code.php:15 which is also declared at src/001_dead_code.php:39. This may lead to confusing errors. It may be possible to exclude the class that isn't used with exclude_file_list. In addition to normal ways to suppress issues, this issue type can be suppressed on either of the class definitions if it is impractical to exclude one file. src/001_dead_code.php:59 PhanRedefinedClassReference Saw reference to \DuplicateClass001 declared at src/001_dead_code.php:15 which is also declared at src/001_dead_code.php:39. This may lead to confusing errors. It may be possible to exclude the class that isn't used with exclude_file_list. In addition to normal ways to suppress issues, this issue type can be suppressed on either of the class definitions if it is impractical to exclude one file. src/001_dead_code.php:59 PhanTypeSuspiciousStringExpression Suspicious type true of a variable or expression DuplicateClass001::C used to build a string. (Expected type to be able to cast to a string) src/001_dead_code.php:60 PhanRedefinedClassReference Saw reference to \DuplicateClass001 declared at src/001_dead_code.php:15 which is also declared at src/001_dead_code.php:39. This may lead to confusing errors. It may be possible to exclude the class that isn't used with exclude_file_list. In addition to normal ways to suppress issues, this issue type can be suppressed on either of the class definitions if it is impractical to exclude one file. src/001_dead_code.php:61 PhanRedefinedClassReference Saw reference to \DuplicateClass001 declared at src/001_dead_code.php:15 which is also declared at src/001_dead_code.php:39. This may lead to confusing errors. It may be possible to exclude the class that isn't used with exclude_file_list. In addition to normal ways to suppress issues, this issue type can be suppressed on either of the class definitions if it is impractical to exclude one file. src/001_dead_code.php:62 PhanRedefinedClassReference Saw reference to \DuplicateClass001 declared at src/001_dead_code.php:15 which is also declared at src/001_dead_code.php:39. This may lead to confusing errors. It may be possible to exclude the class that isn't used with exclude_file_list. In addition to normal ways to suppress issues, this issue type can be suppressed on either of the class definitions if it is impractical to exclude one file. src/001_dead_code.php:67 PhanRedefinedClassReference Saw reference to \DuplicateClass001 declared at src/001_dead_code.php:15 which is also declared at src/001_dead_code.php:39. This may lead to confusing errors. It may be possible to exclude the class that isn't used with exclude_file_list. In addition to normal ways to suppress issues, this issue type can be suppressed on either of the class definitions if it is impractical to exclude one file. src/001_dead_code.php:72 PhanRedefinedClassReference Saw reference to \DuplicateClass001 declared at src/001_dead_code.php:15 which is also declared at src/001_dead_code.php:39. This may lead to confusing errors. It may be possible to exclude the class that isn't used with exclude_file_list. In addition to normal ways to suppress issues, this issue type can be suppressed on either of the class definitions if it is impractical to exclude one file. src/001_dead_code.php:78 PhanRedefinedClassReference Saw reference to \DuplicateClass001 declared at src/001_dead_code.php:15 which is also declared at src/001_dead_code.php:39. This may lead to confusing errors. It may be possible to exclude the class that isn't used with exclude_file_list. In addition to normal ways to suppress issues, this issue type can be suppressed on either of the class definitions if it is impractical to exclude one file. src/001_dead_code.php:78 PhanWriteOnlyPublicProperty Possibly zero read references to public property \HasDuplicateProp::$p src/001_globals_type_map.php:5 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $test_global_exception of type \Exception|\Stringable|\Throwable but \intdiv() takes int src/001_globals_type_map.php:8 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $test_global_error of type \Error|\Stringable|\Throwable but \intdiv() takes int src/001_globals_type_map.php:12 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $test_global_exception of type \Exception|\Stringable|\Throwable but \intdiv() takes int src/001_globals_type_map.php:15 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $test_global_error of type \Error|\Stringable|\Throwable but \intdiv() takes int src/002_unreachable_code.php:3 PhanPluginNeverReturnFunction Function \unreachableCode() never returns and has a return type of (empty union type), but phpdoc type never could be used instead src/002_unreachable_code.php:4 PhanThrowTypeAbsent \unreachableCode() can throw new \RuntimeException('Exception') of type \RuntimeException here, but has no '@throws' declarations for that class src/002_unreachable_code.php:5 PhanPluginUnreachableCode Unreachable statement detected src/002_unreachable_code.php:23 PhanPluginUnreachableCode Unreachable statement detected src/002_unreachable_code.php:25 PhanPluginUnreachableCode Unreachable statement detected src/002_unreachable_code.php:40 PhanPluginUnreachableCode Unreachable statement detected src/002_unreachable_code.php:64 PhanPluginUnreachableCode Unreachable statement detected src/002_unreachable_code.php:66 PhanPluginUseReturnValueNoopVoid The function/method \reachableFunction() is declared to return void and it has no side effects src/003_suppress_on_property.php:7 PhanReadOnlyPublicProperty Possibly zero write references to public property \A3->x src/003_suppress_on_property.php:8 PhanPluginMixedKeyNoKey Should not mix array entries of the form [key => value,] with entries of the form [value,]. src/003_suppress_on_property.php:19 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value('key') detected in array - the earlier entry 'key' at line 18 will be ignored. src/004_unused_suppression_plugin.php:6 UnusedSuppression Element \SuppressionTest suppresses issue PhanPluginNotARealIssue but does not use it src/004_unused_suppression_plugin.php:11 UnusedSuppression Element \SuppressionTest::foo suppresses issue PhanParamTooMany but does not use it src/004_unused_suppression_plugin.php:15 PhanUnusedPublicMethodParameter Parameter $x is never used src/004_unused_suppression_plugin.php:23 UnusedSuppression Element \suppression_test_fn suppresses issue PhanParamTooFew but does not use it src/004_unused_suppression_plugin.php:27 PhanTypeMismatchArgumentReal Argument 1 ($x) is [] of type array{} but \SuppressionTest::bar() takes int defined at src/004_unused_suppression_plugin.php:15 src/004_unused_suppression_plugin.php:31 PhanUnreferencedClass Possibly zero references to class \ExtraSuppressionTest src/005_always_return.php:3 PhanPluginAlwaysReturnFunction Function \test5 has a return type of ?string, but may fail to return a value src/005_always_return.php:23 PhanPluginAlwaysReturnFunction Function \soft_non_nullable_test5 has a return type of string, but may fail to return a value src/005_always_return.php:30 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \test5() defined at src/005_always_return.php:3 src/005_always_return.php:31 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \soft_nullable_test5() defined at src/005_always_return.php:13 src/005_always_return.php:32 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \soft_non_nullable_test5() defined at src/005_always_return.php:23 src/005_always_return.php:39 PhanPluginAlwaysReturnMethod Method \C5::test has a return type of ?string, but may fail to return a value src/005_always_return.php:59 PhanPluginAlwaysReturnMethod Method \C5::soft_non_nullable_test5 has a return type of string, but may fail to return a value src/005_always_return.php:66 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \C5::test() defined at src/005_always_return.php:39 src/005_always_return.php:68 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \C5::soft_nullable_test5() defined at src/005_always_return.php:49 src/005_always_return.php:69 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \C5::soft_non_nullable_test5() defined at src/005_always_return.php:59 src/005_always_return.php:71 PhanPluginAlwaysReturnFunction Function \testmixed5 has a return type of mixed, but may fail to return a value src/006_preg_regex.php:3 PhanPluginInvalidPregRegex Call to \preg_match was passed an invalid regex '@foo': No ending delimiter '@' found src/006_preg_regex.php:6 PhanPluginInvalidPregRegex Call to \preg_replace was passed an invalid regex '@foo(@': Compilation failed: missing closing parenthesis at offset 4 src/006_preg_regex.php:11 PhanPluginPossiblyStaticClosure Closure() can be static src/006_preg_regex.php:12 PhanPluginPossiblyStaticClosure Closure($x) can be static src/006_preg_regex.php:12 PhanUnusedClosureParameter Parameter $x is never used src/006_preg_regex.php:13 PhanPluginInvalidPregRegex Call to \preg_replace_callback_array was passed an invalid regex '@a': No ending delimiter '@' found src/006_preg_regex.php:13 PhanPluginPossiblyStaticClosure Closure($x) can be static src/006_preg_regex.php:13 PhanUnusedClosureParameter Parameter $x is never used src/006_preg_regex.php:14 PhanPluginPossiblyStaticClosure Closure($x) can be static src/006_preg_regex.php:14 PhanUnusedClosureParameter Parameter $x is never used src/006_preg_regex.php:15 PhanPluginInvalidPregRegex Call to \preg_replace_callback was passed an invalid regex '^a': No ending delimiter '^' found src/006_preg_regex.php:15 PhanPluginPossiblyStaticClosure Closure($x) can be static src/006_preg_regex.php:15 PhanUnusedClosureParameter Parameter $x is never used src/006_preg_regex.php:16 PhanPluginInvalidPregRegex Call to \preg_split was passed an invalid regex '/\\s//': Unknown modifier '/' src/006_preg_regex.php:17 PhanPluginInvalidPregRegex Call to \preg_match_all was passed an invalid regex '/\\w/i/': Unknown modifier '/' src/006_preg_regex.php:18 PhanPluginInvalidPregRegex Call to \preg_grep was passed an invalid regex '/\\w/i/': Unknown modifier '/' src/006_preg_regex.php:21 PhanPluginInvalidPregRegex Call to \preg_replace_callback_array was passed an invalid regex '0': Delimiter must not be alphanumeric, backslash, or NUL src/006_preg_regex.php:21 PhanPluginPossiblyStaticClosure Closure($x) can be static src/006_preg_regex.php:21 PhanTypeMismatchArgumentInternal Argument 1 ($pattern) is [(function)] of type array{0:Closure(mixed):'i'} but \preg_replace_callback_array() takes array<string,callable(array):string> src/006_preg_regex.php:21 PhanUnusedClosureParameter Parameter $x is never used src/006_preg_regex.php:22 PhanPluginInvalidPregRegex Call to \preg_replace_callback_array was passed an invalid regex '0': Delimiter must not be alphanumeric, backslash, or NUL src/006_preg_regex.php:22 PhanPluginPossiblyStaticClosure Closure($x) can be static src/006_preg_regex.php:22 PhanTypeInvalidArrayKeyLiteral Saw array key false with key value false but expected a value that could cast to int|string src/006_preg_regex.php:22 PhanTypeMismatchArgumentInternal Argument 1 ($pattern) is [false=>(function)] of type array{0:Closure(mixed):'i'} but \preg_replace_callback_array() takes array<string,callable(array):string> src/006_preg_regex.php:22 PhanUnusedClosureParameter Parameter $x is never used src/006_preg_regex.php:26 PhanPluginConstantVariableScalar Variable $str is probably constant with a value of 'arg' src/006_preg_regex.php:26 PhanPluginInvalidPregRegex Call to \preg_match was passed an invalid regex '/^(a/': Compilation failed: missing closing parenthesis at offset 3 src/006_preg_regex.php:29 PhanPluginConstantVariableScalar Variable $str is probably constant with a value of 'arg' src/006_preg_regex.php:29 PhanPluginInvalidPregRegex Call to \preg_match was passed an invalid regex '/^(a/': Compilation failed: missing closing parenthesis at offset 3 src/007_printf.php:3 PhanPluginPrintfNoArguments No format string arguments are given for "%s", consider using echo instead src/007_printf.php:3 PhanPluginPrintfNonexistentArgument Format string "%s" refers to nonexistent argument #1 in "%s". This will be an ArgumentCountError in PHP 8. src/007_printf.php:4 PhanPluginPrintfNoArguments No format string arguments are given for "some literal", consider using echo instead src/007_printf.php:6 PhanPluginPrintfNonexistentArgument Format string "%d dollars 100% down\n" refers to nonexistent argument #2 in "% d". This will be an ArgumentCountError in PHP 8. src/007_printf.php:6 PhanPluginPrintfNotPercent Format string "%d dollars 100% down\n" contains something that is not a percent sign, it will be treated as a format string '% d' with padding of " " and alignment of '' but no width. Use %% for a literal percent sign, or '%2$d' to be less ambiguous src/007_printf.php:7 PhanPluginPrintfNoSpecifiers None of the formatting arguments passed alongside format string "Not using args" are used src/007_printf.php:8 PhanPluginPrintfNoSpecifiers None of the formatting arguments passed alongside format string "Not using args\n" are used src/007_printf.php:9 PhanPluginDuplicateAdjacentStatement Statement printf("Not using args\n", 3) is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/007_printf.php:9 PhanPluginPrintfNoSpecifiers None of the formatting arguments passed alongside format string "Not using args\n" are used src/007_printf.php:10 PhanPluginPrintfNoSpecifiers None of the formatting arguments passed alongside format string "Not using args\n" are used src/007_printf.php:11 PhanPluginDuplicateAdjacentStatement Statement printf("Not using args\n", 3, 4) is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/007_printf.php:11 PhanPluginPrintfNoSpecifiers None of the formatting arguments passed alongside format string "Not using args\n" are used src/007_printf.php:13 PhanPluginPrintfVariableFormatString Code [] has a dynamic format string that could not be inferred by Phan src/007_printf.php:13 PhanTypeMismatchArgumentInternalReal Argument 1 ($format) is [] of type array{} but \printf() takes string src/007_printf.php:14 PhanPluginPrintfNoSpecifiers None of the formatting arguments passed alongside format string "3" are used src/007_printf.php:14 PhanTypeMismatchArgumentInternal Argument 1 ($format) is 3 of type 3 but \printf() takes string src/007_printf.php:16 PhanPluginPrintfNoArguments No format string arguments are given for "Hello world\n", consider using fwrite instead src/007_printf.php:19 PhanPluginPrintfUnusedArgument Format string "Hello %10s" does not use provided argument #2 src/007_printf.php:20 PhanPluginPrintfNoArguments No format string arguments are given for "Hello %10s", consider using fwrite instead src/007_printf.php:20 PhanPluginPrintfNonexistentArgument Format string "Hello %10s" refers to nonexistent argument #1 in "%10s". This will be an ArgumentCountError in PHP 8. src/007_printf.php:23 PhanPluginPrintfNoArguments No format string arguments are given for "%1$f dollars", consider using echo instead src/007_printf.php:23 PhanPluginPrintfNonexistentArgument Format string "%1$f dollars" refers to nonexistent argument #1 in "%1$f". This will be an ArgumentCountError in PHP 8. src/007_printf.php:25 PhanPluginPrintfNoArguments No format string arguments are given for "%1$f dollars", consider using echo instead src/007_printf.php:25 PhanPluginPrintfNonexistentArgument Format string "%1$f dollars" refers to nonexistent argument #1 in "%1$f". This will be an ArgumentCountError in PHP 8. src/007_printf.php:27 PhanPluginPrintfNoArguments No format string arguments are given for "%1$f dollars", consider using echo instead src/007_printf.php:27 PhanPluginPrintfNonexistentArgument Format string "%1$f dollars" refers to nonexistent argument #1 in "%1$f". This will be an ArgumentCountError in PHP 8. src/007_printf.php:29 PhanPluginPrintfNoArguments No format string arguments are given for "%1$f dollars", consider using echo instead src/007_printf.php:29 PhanPluginPrintfNonexistentArgument Format string "%1$f dollars" refers to nonexistent argument #1 in "%1$f". This will be an ArgumentCountError in PHP 8. src/007_printf.php:30 PhanPluginPrintfNoArguments No format string arguments are given for "%1$f separated dollars", consider using echo instead src/007_printf.php:30 PhanPluginPrintfNonexistentArgument Format string "%1$f separated dollars" refers to nonexistent argument #1 in "%1$f". This will be an ArgumentCountError in PHP 8. src/007_printf.php:32 PhanPluginPrintfIncompatibleSpecifier Format string "%1$d == %1$s: %s" refers to argument #1 in different ways: %1$d,%1$s src/007_printf.php:32 PhanPluginPrintfUnusedArgument Format string "%1$d == %1$s: %s" does not use provided argument #2 src/007_printf.php:33 PhanPluginPrintfIncompatibleArgumentTypeWeak Format string "%1s of %2s\n" refers to argument #1 as %1s, so type string is expected. However, printf was passed the type 5 (which is weaker than string) src/007_printf.php:33 PhanPluginPrintfIncompatibleArgumentTypeWeak Format string "%1s of %2s\n" refers to argument #2 as %2s, so type string is expected. However, printf was passed the type 9 (which is weaker than string) src/007_printf.php:34 PhanPluginPrintfIncompatibleArgumentTypeWeak Format string "%1s of %2s" refers to argument #1 as %1s, so type string is expected. However, printf was passed the type 5 (which is weaker than string) src/007_printf.php:34 PhanPluginPrintfIncompatibleArgumentTypeWeak Format string "%1s of %2s" refers to argument #2 as %2s, so type string is expected. However, printf was passed the type 9 (which is weaker than string) src/007_printf.php:36 PhanPluginPrintfNoArguments No format string arguments are given for "1", consider using echo instead src/007_printf.php:36 PhanTypeMismatchArgumentInternal Argument 1 ($format) is true of type true but \printf() takes string src/007_printf.php:37 PhanPluginPrintfNoArguments No format string arguments are given for "", consider using echo instead src/007_printf.php:37 PhanTypeMismatchArgumentInternal Argument 1 ($format) is false of type false but \printf() takes string src/007_printf.php:38 PhanPluginPrintfNoArguments No format string arguments are given for "", consider using echo instead src/007_printf.php:38 PhanTypeMismatchArgumentInternalReal Argument 1 ($format) is null of type null but \printf() takes string src/007_printf.php:39 PhanPluginPrintfNoArguments No format string arguments are given for "1", consider using echo instead src/007_printf.php:39 PhanTypeMismatchArgumentInternal Argument 1 ($format) is E_ERROR of type 1 but \printf() takes string src/007_printf.php:41 PhanPluginPrintfNonexistentArgument Format string "%d dollars 100%-down\n" refers to nonexistent argument #2 in "%-d". This will be an ArgumentCountError in PHP 8. src/007_printf.php:41 PhanPluginPrintfNotPercent Format string "%d dollars 100%-down\n" contains something that is not a percent sign, it will be treated as a format string '%-d' with padding of "" and alignment of '-' but no width. Use %% for a literal percent sign, or '%2$d' to be less ambiguous src/007_printf.php:42 PhanPluginPrintfNonexistentArgument Format string "%d dollars 100%'xdown\n" refers to nonexistent argument #2 in "%'xd". This will be an ArgumentCountError in PHP 8. src/007_printf.php:42 PhanPluginPrintfNotPercent Format string "%d dollars 100%'xdown\n" contains something that is not a percent sign, it will be treated as a format string '%'xd' with padding of "'x" and alignment of '' but no width. Use %% for a literal percent sign, or '%2$d' to be less ambiguous src/007_printf.php:43 PhanPluginPrintfNonexistentArgument Format string "%d dollars 100%'x10down\n" refers to nonexistent argument #2 in "%'x10d". This will be an ArgumentCountError in PHP 8. src/007_printf.php:44 PhanPluginPrintfNotPercent Format string "%0.2f\n" contains something that is not a percent sign, it will be treated as a format string '%0.2f' with padding of "0" and alignment of '' but no width. Use %% for a literal percent sign, or '%1$.2f' to be less ambiguous src/007_printf.php:45 PhanPluginPrintfNotPercent Format string "%'_.2f\n" contains something that is not a percent sign, it will be treated as a format string '%'_.2f' with padding of "'_" and alignment of '' but no width. Use %% for a literal percent sign, or '%1$.2f' to be less ambiguous src/007_printf.php:47 PhanPluginPrintfNoArguments No format string arguments are given for (unknown), consider using echo instead src/007_printf.php:47 PhanPluginPrintfVariableFormatString Code $argv[0] has a dynamic format string that could not be inferred by Phan src/008_printf_search.php:6 PhanPluginPrintfUnusedArgument Format string "class const: %1$d of 2" does not use provided argument #2 src/008_printf_search.php:13 PhanPluginPrintfNoArguments No format string arguments are given for "%s", consider using echo instead src/008_printf_search.php:13 PhanPluginPrintfNonexistentArgument Format string "%s" refers to nonexistent argument #1 in "%s". This will be an ArgumentCountError in PHP 8. src/008_printf_search.php:15 PhanPluginPrintfUnusedArgument Format string "global const Hello, %s" does not use provided argument #2 src/008_printf_search.php:16 PhanPluginPrintfNoArguments No format string arguments are given for "global const Hello, %s", consider using echo instead src/008_printf_search.php:16 PhanPluginPrintfNonexistentArgument Format string "global const Hello, %s" refers to nonexistent argument #1 in "%s". This will be an ArgumentCountError in PHP 8. src/009_vprintf.php:6 PhanPluginPrintfNoArguments No format string arguments are given for "%s", consider using fwrite instead src/009_vprintf.php:6 PhanPluginPrintfNonexistentArgument Format string "%s" refers to nonexistent argument #1 in "%s". This will be an ArgumentCountError in PHP 8. src/009_vprintf.php:7 PhanPluginPrintfNoArguments No format string arguments are given for "some literal", consider using echo instead src/009_vprintf.php:9 PhanPluginPrintfNonexistentArgument Format string "%d dollars 100% down\n" refers to nonexistent argument #2 in "% d". This will be an ArgumentCountError in PHP 8. src/009_vprintf.php:9 PhanPluginPrintfNotPercent Format string "%d dollars 100% down\n" contains something that is not a percent sign, it will be treated as a format string '% d' with padding of " " and alignment of '' but no width. Use %% for a literal percent sign, or '%2$d' to be less ambiguous src/009_vprintf.php:10 PhanPluginPrintfNoSpecifiers None of the formatting arguments passed alongside format string "Not using args" are used src/009_vprintf.php:11 PhanPluginPrintfNoSpecifiers None of the formatting arguments passed alongside format string "Not using args" are used src/009_vprintf.php:12 PhanPluginPrintfUnusedArgument Format string "Not using %d\n args\n" does not use provided argument #2 src/009_vprintf.php:14 PhanPluginPrintfVariableFormatString Code [] has a dynamic format string that could not be inferred by Phan src/009_vprintf.php:14 PhanTypeMismatchArgumentInternalReal Argument 1 ($format) is [] of type array{} but \vprintf() takes string src/009_vprintf.php:14 PhanTypeMismatchArgumentInternalReal Argument 2 ($values) is 2 of type 2 but \vprintf() takes array src/009_vprintf.php:16 PhanPluginPrintfNoArguments No format string arguments are given for "Hello world\n", consider using fwrite instead src/009_vprintf.php:18 PhanTypeMismatchArgumentInternalReal Argument 3 ($values) is 'world' of type 'world' but \vfprintf() takes array src/009_vprintf.php:19 PhanTypeMismatchArgumentInternalReal Argument 3 ($values) is true of type true but \vfprintf() takes array src/009_vprintf.php:23 PhanPartialTypeMismatchArgumentInternal Argument 1 ($format) is ...($tmp) of type 'arg %s'|array{0:'name'} but \vprintf() takes string (array{0:'name'} is incompatible) src/009_vprintf.php:23 PhanPartialTypeMismatchArgumentInternal Argument 2 ($values) is ...($tmp) of type 'arg %s'|array{0:'name'} but \vprintf() takes array ('arg %s' is incompatible) src/010_printf_types.php:7 PhanPluginPrintfIncompatibleArgumentTypeWeak Format string "Hello, %s" refers to argument #1 as %s, so type string is expected. However, printf was passed the type 3.3 (which is weaker than string) src/010_printf_types.php:8 PhanPluginPrintfIncompatibleArgumentTypeWeak Format string "Hello, %s" refers to argument #1 as %s, so type string is expected. However, printf was passed the type 2 (which is weaker than string) src/010_printf_types.php:9 PhanPluginPrintfIncompatibleArgumentType Format string "Hello, %s" refers to argument #1 as %s, so type string is expected, but printf was passed incompatible type ?int src/010_printf_types.php:9 PhanTypeMismatchArgumentNullableInternal Argument 2 ($values) is get_nullable_int() of type ?int but \printf() takes \Stringable|float|int|string (expected type to be non-nullable) src/010_printf_types.php:10 PhanPluginPrintfIncompatibleArgumentType Format string "Hello, %s" refers to argument #1 as %s, so type string is expected, but printf was passed incompatible type false src/010_printf_types.php:10 PhanTypeMismatchArgumentInternal Argument 2 ($values) is false of type false but \printf() takes \Stringable|float|int|string src/010_printf_types.php:11 PhanPluginPrintfIncompatibleArgumentType Format string "Hello, %s" refers to argument #1 as %s, so type string is expected, but printf was passed incompatible type array{} src/010_printf_types.php:11 PhanTypeMismatchArgumentInternalProbablyReal Argument 2 ($values) is [] of type array{} but \printf() takes \Stringable|float|int|string src/010_printf_types.php:12 PhanPluginPrintfIncompatibleArgumentTypeWeak Format string "Hello, %f %s" refers to argument #2 as %s, so type string is expected. However, printf was passed the type 2 (which is weaker than string) src/010_printf_types.php:12 PhanPluginPrintfIncompatibleArgumentType Format string "Hello, %f %s" refers to argument #1 as %f, so type float is expected, but printf was passed incompatible type 'World' src/010_printf_types.php:13 PhanPluginPrintfIncompatibleArgumentType Format string "Hello, %1$d %1$f" refers to argument #1 as %1$d,%1$f, so type float|int is expected, but printf was passed incompatible type 'x' src/010_printf_types.php:13 PhanPluginPrintfIncompatibleSpecifier Format string "Hello, %1$d %1$f" refers to argument #1 in different ways: %1$d,%1$f src/010_printf_types.php:15 PhanPluginPrintfUnusedArgument Format string "Hello, %-10d,%+3d" does not use provided argument #3 src/010_printf_types.php:26 PhanPluginPrintfIncompatibleArgumentType Format string "Hello, %s\n" refers to argument #1 as %s, so type string is expected, but printf was passed incompatible type \Bar src/010_printf_types.php:26 PhanTypeMismatchArgumentInternal Argument 2 ($values) is $bar of type \Bar but \printf() takes \Stringable|float|int|string src/011_goto_not_unreachable.php:12 PhanThrowTypeAbsent \goto11() can throw new RuntimeException("Missing {$x}") of type \RuntimeException here, but has no '@throws' declarations for that class src/011_goto_not_unreachable.php:13 PhanPluginUnreachableCode Unreachable statement detected src/012_duplicate_array_key.php:16 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(1) detected in array - the earlier entry Y at line 15 will be ignored. src/012_duplicate_array_key.php:17 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(1) detected in array - the earlier entry Z at line 16 will be ignored. src/012_duplicate_array_key.php:18 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(1) detected in array - the earlier entry Test::XYZ at line 17 will be ignored. src/012_duplicate_array_key.php:18 PhanTypeInvalidArrayKeyLiteral Saw array key Test::TRUE with key value true but expected a value that could cast to int|string src/012_duplicate_array_key.php:19 PhanTypeInvalidArrayKeyLiteral Saw array key Test::FALSE with key value false but expected a value that could cast to int|string src/012_duplicate_array_key.php:20 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(1) detected in array - the earlier entry Test::TRUE at line 18 will be ignored. src/012_duplicate_array_key.php:20 PhanTypeInvalidArrayKeyLiteral Saw array key A with key value true but expected a value that could cast to int|string src/012_duplicate_array_key.php:21 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(0) detected in array - the earlier entry Test::FALSE at line 19 will be ignored. src/012_duplicate_array_key.php:21 PhanTypeInvalidArrayKeyLiteral Saw array key B with key value false but expected a value that could cast to int|string src/012_duplicate_array_key.php:22 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(0) detected in array - the earlier entry B at line 21 will be ignored. src/012_duplicate_array_key.php:22 PhanTypeInvalidArrayKeyLiteral Saw array key false with key value false but expected a value that could cast to int|string src/012_duplicate_array_key.php:23 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(1) detected in array - the earlier entry A at line 20 will be ignored. src/012_duplicate_array_key.php:23 PhanTypeInvalidArrayKeyLiteral Saw array key true with key value true but expected a value that could cast to int|string src/012_duplicate_array_key.php:24 PhanTypeInvalidArrayKeyLiteral Saw array key null with key value null but expected a value that could cast to int|string src/012_duplicate_array_key.php:25 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value('') detected in array - the earlier entry null at line 24 will be ignored. src/013_duplicate_array_key_uncaught.php:7 PhanUndeclaredConstantOfClass Reference to undeclared class constant \Bar13::B src/013_duplicate_array_key_uncaught.php:17 PhanUndeclaredConstantOfClass Reference to undeclared class constant \Bar13::a src/014_unreferenced_constant.php:6 PhanUnreferencedPublicClassConstant Possibly zero references to public class constant \A14::unreferencedconst src/014_unreferenced_constant.php:9 PhanWriteOnlyPublicProperty Possibly zero read references to public property \A14::$prop src/014_unreferenced_constant.php:10 PhanUnreferencedPublicProperty Possibly zero references to public property \A14::$prop2 src/014_unreferenced_constant.php:12 PhanUnreferencedPublicMethod Possibly zero references to public method \A14::foo_unused() src/015_trait_method.php:9 PhanUnreferencedProtectedMethod Possibly zero references to protected method \T15::fn2() src/015_trait_method.php:19 PhanUnreferencedPublicClassConstant Possibly zero references to public class constant \I15::CI2 src/015_trait_method.php:31 PhanUnreferencedPublicMethod Possibly zero references to public method \Base15::baseInstanceMethod2() src/015_trait_method.php:35 PhanUnreferencedPublicClassConstant Possibly zero references to public class constant \Base15::C2 src/015_trait_method.php:37 PhanUnreferencedPublicProperty Possibly zero references to public property \Base15::$p2 src/016_dead_code_callable.php:7 PhanUnreferencedFunction Possibly zero references to function \myfunc16unused() src/016_dead_code_callable.php:12 PhanUnreferencedFunction Possibly zero references to function \double16unused() src/016_dead_code_callable.php:20 PhanUnreferencedPublicMethod Possibly zero references to public method \MyClass16::static_func_unused() src/016_dead_code_callable.php:26 PhanUnreferencedPublicMethod Possibly zero references to public method \MyClass16::instanceFuncUnused() src/016_dead_code_callable.php:45 PhanTypeVoidArgument Cannot use void return value user_defined_caller('undeclared_func_16') as a function argument src/016_dead_code_callable.php:45 PhanUndeclaredFunctionInCallable Call to undeclared function undeclared_func_16 in callable src/016_dead_code_fromCallable.php:4 PhanUnreferencedFunction Possibly zero references to function \callable16bUnused() src/016_dead_code_fromCallable.php:8 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \main16b() defined at src/016_dead_code_fromCallable.php:5 src/017_unreferenced_closure.php:10 PhanUnreferencedClosure Possibly zero references to Closure(string $x) src/018_duplicate_switch.php:18 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(1) detected in switch statement - the later entry will be ignored in favor of case Y at line 17. src/018_duplicate_switch.php:19 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(1) detected in switch statement - the later entry will be ignored in favor of case Z at line 18. src/018_duplicate_switch.php:22 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(true) detected in switch statement - the later entry will be ignored in favor of case NSwitch::TRUE at line 20. src/018_duplicate_switch.php:23 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(false) detected in switch statement - the later entry will be ignored in favor of case NSwitch::FALSE at line 21. src/018_duplicate_switch.php:24 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(false) detected in switch statement - the later entry will be ignored in favor of case B at line 23. src/018_duplicate_switch.php:25 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(true) detected in switch statement - the later entry will be ignored in favor of case A at line 22. src/018_duplicate_switch.php:29 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case('(test literal)') detected in switch statement - the later entry will be ignored in favor of case '(test literal)' at line 28. src/018_duplicate_switch.php:33 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(32) detected in switch statement - the later entry will be ignored in favor of case __LINE__ at line 32. src/018_duplicate_switch.php:34 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case('') detected in switch statement - the later entry will be ignored in favor of case '' at line 27. src/018_duplicate_switch.php:35 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(null) detected in switch statement - the later entry will be ignored in favor of case null at line 26. src/019_duplicate_magic.php:9 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(9) detected in array - the earlier entry __LINE__ at line 9 will be ignored. src/019_duplicate_magic.php:10 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value('/src/repo/phan-tests/plugin_test/src/019_duplicate_magic.php') detected in array - the earlier entry __FILE__ at line 7 will be ignored. src/019_duplicate_magic.php:12 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value('Bar') detected in array - the earlier entry __NAME__ at line 11 will be ignored. src/019_duplicate_magic.php:13 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value('Bar') detected in array - the earlier entry 'Bar' at line 12 will be ignored. src/019_duplicate_magic.php:15 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value('/src/repo/phan-tests/plugin_test/src') detected in array - the earlier entry __DIR__ at line 14 will be ignored. src/019_duplicate_magic.php:16 PhanTypeInvalidArrayKeyLiteral Saw array key false with key value false but expected a value that could cast to int|string src/019_duplicate_magic.php:17 PhanTypeInvalidArrayKeyLiteral Saw array key true with key value true but expected a value that could cast to int|string src/019_duplicate_magic.php:18 PhanTypeInvalidArrayKeyLiteral Saw array key Null with key value null but expected a value that could cast to int|string src/019_duplicate_magic.php:19 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(1) detected in array - the earlier entry true at line 17 will be ignored. src/019_duplicate_magic.php:19 PhanTypeInvalidArrayKeyLiteral Saw array key true with key value true but expected a value that could cast to int|string src/019_duplicate_magic.php:20 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(0) detected in array - the earlier entry false at line 16 will be ignored. src/020_bool.php:18 PhanPluginEmptyStatementIf Empty statement list detected for the last if/elseif statement src/020_bool.php:19 PhanPluginEmptyStatementIf Empty statement list detected for the last if/elseif statement src/020_bool.php:20 PhanPluginEmptyStatementIf Empty statement list detected for the last if/elseif statement src/020_bool.php:20 PhanPluginNonBoolBranch Non bool value of type 80220 evaluated in if clause src/020_bool.php:21 PhanPluginNonBoolBranch Non bool value of type null evaluated in if clause src/020_bool.php:22 PhanPluginNonBoolBranch Non bool value of type ?bool evaluated in if clause src/020_bool.php:23 PhanPluginEmptyStatementIf Empty statement list detected for the last if/elseif statement src/020_bool.php:23 PhanPluginNonBoolBranch Non bool value of type array|bool evaluated in if clause src/020_bool.php:26 PhanPluginNonBoolBranch Non bool value of type ?bool evaluated in if clause src/020_bool.php:30 PhanPluginNonBoolBranch Non bool value of type array|bool evaluated in if clause src/021_param_default.php:3 PhanUnreferencedClass Possibly zero references to class \Example21 src/021_param_default.php:5 PhanUnreferencedPublicClassConstant Possibly zero references to public class constant \Example21::D21 src/022_trait_method.php:5 PhanUnreferencedPublicMethod Possibly zero references to public method \T22::myUnusedFunction() src/023_write_only_property.php:4 PhanWriteOnlyPublicProperty Possibly zero read references to public property \MyClass23->a src/023_write_only_property.php:5 PhanWriteOnlyProtectedProperty Possibly zero read references to protected property \MyClass23->b src/023_write_only_property.php:6 PhanWriteOnlyPrivateProperty Possibly zero read references to private property \MyClass23->c src/023_write_only_property.php:15 PhanUnreferencedPublicProperty Possibly zero references to public property \MyClass23->g src/023_write_only_property.php:34 PhanWriteOnlyPublicProperty Possibly zero read references to public property \OtherClass->subclassProp src/023_write_only_property.php:35 PhanUnreferencedPublicProperty Possibly zero references to public property \OtherClass->subclassPropUnused src/024_strict_property_assignment.php:3 PhanUnreferencedClass Possibly zero references to class \MyClass24 src/024_strict_property_assignment.php:5 PhanWriteOnlyPrivateProperty Possibly zero read references to private property \MyClass24->a src/024_strict_property_assignment.php:8 PhanWriteOnlyProtectedProperty Possibly zero read references to protected property \MyClass24->b src/024_strict_property_assignment.php:11 PhanWriteOnlyPublicProperty Possibly zero read references to public property \MyClass24->c src/024_strict_property_assignment.php:19 PhanPossiblyFalseTypeMismatchProperty Assigning $a of type false|int to property but \MyClass24->a is int (false is incompatible) src/024_strict_property_assignment.php:20 PhanPossiblyNullTypeMismatchProperty Assigning $b of type \stdClass|null to property but \MyClass24->b is \stdClass (null is incompatible) src/024_strict_property_assignment.php:21 PhanPartialTypeMismatchProperty Assigning $c of type \MyClass24|\Traversable to property but \MyClass24->c is \MyClass24 (\Traversable|iterable is incompatible) src/025_strict_param_checks.php:4 PhanPossiblyFalseTypeArgumentInternal Argument 1 ($string) is $maybeFalse of type 's'|false but \strlen() takes string (false is incompatible) src/025_strict_param_checks.php:6 PhanPossiblyNullTypeArgumentInternal Argument 1 ($num1) is $maybeNull of type non-zero-int|null but \intdiv() takes int (null is incompatible) src/025_strict_param_checks.php:8 PhanPartialTypeMismatchArgumentInternal Argument 1 ($num1) is $maybeInvalid of type 'default'|non-zero-int but \intdiv() takes int ('default' is incompatible) src/026_strict_return_checks.php:16 PhanPossiblyNullTypeReturn Returning $param of type int|null but notNull() is declared to return int (null is incompatible) src/026_strict_return_checks.php:22 PhanPluginUseReturnValueNoopVoid The function/method \StrictReturnChecks::expectNull() is declared to return null and it has no side effects src/026_strict_return_checks.php:23 PhanPartialTypeMismatchReturn Returning $param of type int|null but expectNull() is declared to return null (int is incompatible) src/026_strict_return_checks.php:31 PhanPossiblyFalseTypeReturn Returning $param of type false|int but notFalse() is declared to return int (false is incompatible) src/026_strict_return_checks.php:39 PhanPartialTypeMismatchReturn Returning $param of type false|int but expectFalse() is declared to return false (int is incompatible) src/026_strict_return_checks.php:53 PhanPartialTypeMismatchReturn Returning $param of type \StrictReturnChecks|\ast\Node but partiallyValid() is declared to return \ast\Node (\StrictReturnChecks is incompatible) src/026_strict_return_checks.php:56 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \StrictReturnChecks::partiallyValid() defined at src/026_strict_return_checks.php:52 src/027_native_syntax_check.php:2 PhanUnreferencedClass Possibly zero references to class \X src/027_native_syntax_check.php:3 PhanUnreferencedPublicProperty Possibly zero references to public property \X->y src/027_native_syntax_check.php:4 PhanInvalidConstantExpression Constant expression contains invalid operations ($y) src/027_native_syntax_check.php:4 PhanNativePHPSyntaxCheckPlugin Saw error or notice for php --syntax-check: "Fatal error: Constant expression contains invalid operations" src/027_native_syntax_check.php:4 PhanUndeclaredVariable Variable $y is undeclared src/027_native_syntax_check.php:4 PhanUnreferencedPublicProperty Possibly zero references to public property \X->x src/028_parse_failure.php:2 PhanSyntaxError Fallback parser diagnostic error: 'Expression' expected. (at column 5) src/029_other_parse_failure.php:102 PhanUnreferencedClass Possibly zero references to class \MyClass29 src/029_other_parse_failure.php:103 PhanNativePHPSyntaxCheckPlugin Saw error or notice for php --syntax-check: "Fatal error: A class constant must not be called 'class'; it is reserved for class name fetching" src/030_preg_replace_flag.php:4 PhanPluginInvalidPregRegex Call to \preg_replace was passed an invalid regex '/(functionName)(arg)/e': The /e modifier is no longer supported, use preg_replace_callback instead src/031_sleep.php:4 PhanUnreferencedPHPDocProperty Possibly zero references to PHPDoc @property \A31->z src/031_sleep.php:17 PhanTypeMismatchReturn Returning ['_x','z','_z',__CLASS__,2,42.1,new stdClass()] of type array{0:'_x',1:'z',2:'_z',3:'A31',4:2,5:42.1,6:\stdClass} but __sleep() is declared to return string[] src/031_sleep.php:17 SleepCheckerInvalidPropNameType __sleep is returning an array with a value of type 2, expected string src/031_sleep.php:17 SleepCheckerInvalidPropNameType __sleep is returning an array with a value of type 42.1, expected string src/031_sleep.php:17 SleepCheckerInvalidPropNameType __sleep is returning an array with a value of type \stdClass, expected string src/031_sleep.php:17 SleepCheckerInvalidPropName __sleep is returning an array that includes A31, which cannot be found src/031_sleep.php:17 SleepCheckerInvalidPropName __sleep is returning an array that includes _x, which cannot be found src/031_sleep.php:17 SleepCheckerMagicPropName __sleep is returning an array that includes z, which is a magic property src/031_sleep.php:19 SleepCheckerInvalidPropName __sleep is returning an array that includes _Z, which cannot be found src/031_sleep.php:22 PhanUnusedPublicNoOverrideMethodParameter Parameter $x is never used src/031_sleep.php:28 SleepCheckerPropertyMissingTransient Property public $_myProp that is not serialized by __sleep should be annotated with @transient or @phan-transient src/031_sleep.php:35 PhanTypeMismatchReturnProbablyReal Returning 2 of type 2 but __sleep() is declared to return string[] (no real type) (the inferred real return type has nothing in common with the declared phpdoc return type) src/031_sleep.php:35 SleepCheckerInvalidReturnStatement __sleep must return an array of strings. This is definitely not an array. src/031_sleep.php:37 PhanTypeMismatchReturnProbablyReal Returning void of type void but __sleep() is declared to return string[] (no real type) (the inferred real return type has nothing in common with the declared phpdoc return type) src/031_sleep.php:37 SleepCheckerInvalidReturnStatement __sleep must return an array of strings. This is definitely not an array. src/031_sleep.php:39 PhanPluginConstantVariableScalar Variable $x is probably constant with a value of 'unknownProp' src/031_sleep.php:39 SleepCheckerInvalidPropName __sleep is returning an array that includes _myprop, which cannot be found src/031_sleep.php:39 SleepCheckerInvalidPropName __sleep is returning an array that includes x, which cannot be found src/031_sleep.php:44 PhanNoopNewNoSideEffects Unused result of new object creation expression in new A31() (this is likely free of side effects - there is no known non-empty constructor or destructor) src/031_sleep.php:45 PhanNoopNewNoSideEffects Unused result of new object creation expression in new B31() (this is likely free of side effects - there is no known non-empty constructor or destructor) src/032_line_suppression.php:3 PhanInvalidCommentForDeclarationType The phpdoc comment for @property cannot occur on a function src/032_line_suppression.php:5 PhanInvalidCommentForDeclarationType The phpdoc comment for @property cannot occur on a function src/032_line_suppression.php:8 PhanInvalidCommentForDeclarationType The phpdoc comment for @property cannot occur on a function src/032_line_suppression.php:9 UnusedPluginFileSuppression Plugin BuiltinSuppressionPlugin suppresses issue MissingIssueType in this file but this suppression is unused or suppressed elsewhere src/032_line_suppression.php:9 UnusedPluginFileSuppression Plugin BuiltinSuppressionPlugin suppresses issue PhanParamTooMany in this file but this suppression is unused or suppressed elsewhere src/032_line_suppression.php:11 PhanUnreferencedFunction Possibly zero references to function \test_line_suppression() src/032_line_suppression.php:12 PhanTypeSuspiciousEcho Suspicious argument $w of type null= for an echo/print statement src/032_line_suppression.php:13 PhanTypeSuspiciousEcho Suspicious argument $x of type null= for an echo/print statement src/032_line_suppression.php:13 PhanUndeclaredVariable Variable $x is undeclared src/032_line_suppression.php:14 PhanTypeSuspiciousEcho Suspicious argument $y of type null= for an echo/print statement src/032_line_suppression.php:15 PhanTypeSuspiciousEcho Suspicious argument $z of type null= for an echo/print statement src/032_line_suppression.php:15 PhanUndeclaredVariable Variable $z is undeclared src/032_line_suppression.php:18 PhanTypeInvalidRightOperandOfAdd Invalid operator: right operand of + is null= (expected array or number) src/032_line_suppression.php:18 PhanUndeclaredFunction Call to undeclared function \call_undeclared_function_not_suppressed() src/032_line_suppression.php:18 PhanUnusedVariable Unused definition of variable $result src/032_line_suppression.php:20 UnusedPluginSuppression Plugin BuiltinSuppressionPlugin suppresses issue PhanUndeclaredVariable on this line but this suppression is unused or suppressed elsewhere src/032_line_suppression.php:29 UnusedPluginSuppression Plugin BuiltinSuppressionPlugin suppresses issue PhanUndeclaredVariable on this line but this suppression is unused or suppressed elsewhere src/033_loop_usage.php:4 PhanUnusedVariable Unused definition of variable $b src/033_loop_usage.php:9 PhanPluginDuplicateExpressionAssignmentOperation Can simplify this assignment to $a += $x src/033_loop_usage.php:10 PhanUnusedVariable Unused definition of variable $b src/033_loop_usage.php:15 PhanUnusedVariable Unused definition of variable $a src/034_loop_checks.php:6 PhanReadOnlyPublicProperty Possibly zero write references to public property \Example34->other_array src/035_break_unused.php:3 PhanPluginPossiblyStaticClosure Closure() can be static src/035_break_unused.php:7 PhanUnusedVariable Unused definition of variable $myUnusedVar src/035_break_unused.php:8 PhanUnusedVariable Unused definition of variable $myUnusedVar3 src/035_break_unused.php:12 PhanUnusedVariable Unused definition of variable $myUnusedVar3 src/035_break_unused.php:14 PhanPossiblyUndeclaredVariable Variable $myVar is possibly undeclared src/036_switch.php:8 PhanPluginConstantVariableScalar Variable $x is probably constant with a value of 0 src/036_switch.php:12 PhanPluginConstantVariableScalar Variable $x is probably constant with a value of 2 src/036_switch.php:13 PhanPluginConstantVariableScalar Variable $y is probably constant with a value of 'hello' src/036_switch.php:16 PhanPluginConstantVariableScalar Variable $x is probably constant with a value of 2 src/037_unused_return.php:8 PhanUnusedVariable Unused definition of variable $myVar src/037_unused_return.php:9 PhanUnusedVariable Unused definition of variable $myUnusedVar src/037_unused_return.php:13 PhanUnusedVariable Unused definition of variable $myUnusedVar src/037_unused_return.php:17 PhanUnusedVariable Unused definition of variable $myVar src/037_unused_return.php:20 PhanUnusedVariable Unused definition of variable $myVar src/037_unused_return.php:21 PhanUnusedVariable Unused definition of variable $myUnusedVar src/037_unused_return.php:23 PhanUnusedVariable Unused definition of variable $myVar src/037_unused_return.php:24 PhanUnusedVariable Unused definition of variable $myUnusedVar src/037_unused_return.php:25 PhanThrowTypeAbsent \unused_return() can throw new RuntimeException('end') of type \RuntimeException here, but has no '@throws' declarations for that class src/037_unused_return.php:29 PhanPossiblyUndeclaredVariable Variable $myVar is possibly undeclared src/038_unused_loop_var.php:11 PhanDebugAnnotation @phan-debug-var requested for variable $prev_was_element - it has union type true(real=true) src/038_unused_loop_var.php:12 PhanUnusedVariable Unused definition of variable $ast_items src/038_unused_loop_var.php:17 PhanUnusedVariable Unused definition of variable $myUnusedVariable src/039_loop_return.php:3 PhanPluginInconsistentReturnFunction Function \test_loop_var_return has no return type and will inconsistently return or not return src/039_loop_return.php:11 PhanUnusedVariable Unused definition of variable $myUnusedVariable src/039_loop_return.php:15 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \test_loop_var_return() defined at src/039_loop_return.php:3 src/040_if_assign.php:4 PhanThrowTypeAbsent \test_if_assign() can throw new RuntimeException('throw') of type \RuntimeException here, but has no '@throws' declarations for that class src/040_if_assign.php:9 PhanUnusedVariable Unused definition of variable $x src/040_if_assign.php:10 PhanThrowTypeAbsent \test_unused_if_assign() can throw new RuntimeException('throw') of type \RuntimeException here, but has no '@throws' declarations for that class src/041_switch_assign.php:7 PhanUnusedVariable Unused definition of variable $result src/041_switch_assign.php:12 PhanUnusedVariable Unused definition of variable $myUnused src/041_switch_assign.php:16 PhanUnusedVariable Unused definition of variable $myUnused src/041_switch_assign.php:29 PhanUnusedVariable Unused definition of variable $myUnused src/041_switch_assign.php:33 PhanUnusedVariable Unused definition of variable $myUnused src/042_param_default.php:12 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is new stdClass() of type \stdClass but \Example42::test() takes string (no real type) defined at src/042_param_default.php:5 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/043_throws.php:6 PhanPluginNeverReturnFunction Function \throwOutOfBoundsException() never returns and has a return type of void, but phpdoc type never could be used instead src/043_throws.php:14 PhanPluginNeverReturnMethod Method \ExampleThrow43::throwInvalidArgumentException() never returns and has a return type of (empty union type), but phpdoc type never could be used instead src/043_throws.php:20 PhanThrowTypeAbsent \ExampleThrow43::example() can throw throwOutOfBoundsException of type \OutOfBoundsException here, but has no '@throws' declarations for that class src/043_throws.php:22 PhanThrowTypeAbsentForCall \ExampleThrow43::example() can throw \InvalidArgumentException because it calls \ExampleThrow43::throwInvalidArgumentException(), but has no '@throws' declarations for that class src/043_throws.php:30 PhanThrowTypeAbsentForCall \ExampleThrow43::example2() can throw \InvalidArgumentException because it calls \ExampleThrow43::throwInvalidArgumentException(), but has no '@throws' declarations for that class src/044_crash.php:5 PhanSyntaxError Fallback parser diagnostic error: '}' expected. (at column 6) src/045_invalid_const.php:3 PhanSyntaxError Fallback parser diagnostic error: ';' expected. (at column 24) src/046_unused_exception.php:2 PhanPluginPossiblyStaticClosure Closure() can be static src/046_unused_exception.php:3 PhanUnusedVariable Unused definition of variable $e src/046_unused_exception.php:12 PhanUnusedVariableCaughtException Unused definition of variable $e2 as a caught exception src/047_crash.php:6 PhanPluginUseReturnValueNoopVoid The function/method \X47::myMethod() is declared to return (empty union type) and it has no side effects src/047_crash.php:6 PhanUnusedPublicNoOverrideMethodParameter Parameter $arg is never used src/047_crash.php:11 PhanUnreferencedFunction Possibly zero references to function \example() src/047_crash.php:12 PhanTypeMismatchArgumentReal Argument 1 ($arg) is 'my arg' of type 'my arg' but \X47::myMethod() takes int defined at src/047_crash.php:6 src/048_redundant_binary_op.php:5 PhanReadOnlyPublicProperty Possibly zero write references to public property \A48::$prop src/048_redundant_binary_op.php:8 PhanPluginDuplicateExpressionBinaryOp Both sides of the binary operator > are the same: (2 + 2) src/048_redundant_binary_op.php:9 PhanPluginDuplicateExpressionBinaryOp Both sides of the binary operator == are the same: $x->prop src/048_redundant_binary_op.php:10 PhanPluginDuplicateExpressionBinaryOp Both sides of the binary operator != are the same: A48::$prop src/048_redundant_binary_op.php:11 PhanPluginDuplicateExpressionBinaryOp Both sides of the binary operator || are the same: $x src/048_redundant_binary_op.php:11 PhanPluginNonBoolInLogicalArith Non bool value of type \stdClass in logical arithmetic src/049_redundant_null_coalescing.php:3 PhanDeprecatedImplicitNullableParam Implicit nullable parameters (string $a = null) have been deprecated in PHP 8.4 src/049_redundant_null_coalescing.php:4 PhanPluginDuplicateConditionalNullCoalescing "isset(X) ? X : Y" can usually be simplified to "X ?? Y" in PHP 7. The duplicated expression X was $a src/049_redundant_null_coalescing.php:5 PhanPluginDuplicateConditionalNullCoalescing "isset(X) ? X : Y" can usually be simplified to "X ?? Y" in PHP 7. The duplicated expression X was $x->prop src/049_redundant_null_coalescing.php:6 PhanPluginDuplicateExpressionBinaryOp Both sides of the binary operator == are the same: $x->prop src/049_redundant_null_coalescing.php:9 PhanPluginDuplicateConditionalTernaryDuplication "X ? X : Y" can usually be simplified to "X ?: Y". The duplicated expression X was $x->prop src/050_unreachable_code.php:11 PhanPluginUnreachableCode Unreachable statement detected src/050_unreachable_code.php:13 PhanContinueTargetingSwitch "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? src/050_unreachable_code.php:14 PhanPluginUnreachableCode Unreachable statement detected src/050_unreachable_code.php:17 PhanPluginUnreachableCode Unreachable statement detected src/050_unreachable_code.php:20 PhanPluginUnreachableCode Unreachable statement detected src/051_loop_unused_defs.php:33 PhanUnusedVariable Unused definition of variable $b src/051_loop_unused_defs.php:56 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \foo51() defined at src/051_loop_unused_defs.php:3 src/051_loop_unused_defs.php:57 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \foo51b() defined at src/051_loop_unused_defs.php:17 src/052_shadowed_def.php:3 PhanPluginPossiblyStaticClosure Closure() can be static src/052_shadowed_def.php:4 PhanUnusedVariable Unused definition of variable $a src/052_shadowed_def.php:6 PhanPluginRedundantAssignment Assigning true to variable $a which already has that value src/052_shadowed_def.php:7 PhanPluginConstantVariableBool Variable $a is probably constant with a value of true src/052_shadowed_def.php:11 PhanPluginPossiblyStaticClosure Closure() can be static src/052_shadowed_def.php:15 PhanPluginRedundantAssignment Assigning true to variable $a which already has that value src/052_shadowed_def.php:17 PhanPluginConstantVariableBool Variable $a is probably constant with a value of true src/052_shadowed_def.php:21 PhanPluginPossiblyStaticClosure Closure() can be static src/052_shadowed_def.php:22 PhanUnusedVariable Unused definition of variable $a src/052_shadowed_def.php:25 PhanPluginRedundantAssignment Assigning true to variable $a which already has that value src/053_shadowed_loop_def.php:2 PhanPluginPossiblyStaticClosure Closure() can be static src/053_shadowed_loop_def.php:3 PhanUnusedVariable Unused definition of variable $a src/053_shadowed_loop_def.php:4 PhanSideEffectFreeDoWhileBody Saw a do-while loop which probably has no side effects src/053_shadowed_loop_def.php:9 PhanPluginPossiblyStaticClosure Closure() can be static src/053_shadowed_loop_def.php:18 PhanPluginPossiblyStaticClosure Closure(array $data) can be static src/053_shadowed_loop_def.php:31 PhanPluginPossiblyStaticClosure Closure(int $n) can be static src/053_shadowed_loop_def.php:44 PhanPluginPossiblyStaticClosure Closure(int $n) can be static src/054_shadowed_exception.php:6 PhanUnusedVariableCaughtException Unused definition of variable $e as a caught exception src/055_loop_false_positive.php:5 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/055_loop_false_positive.php:14 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/056_while_loop.php:2 PhanPluginPossiblyStaticClosure Closure(int $a) can be static src/056_while_loop.php:4 PhanSideEffectFreeWhileBody Saw a while loop which probably has no side effects src/056_while_loop.php:6 PhanUnusedVariable Unused definition of variable $c src/057_do_while_loop.php:2 PhanPluginPossiblyStaticClosure Closure() can be static src/057_do_while_loop.php:15 PhanPluginPossiblyStaticClosure Closure() can be static src/057_do_while_loop.php:28 PhanPluginPossiblyStaticClosure Closure() can be static src/057_do_while_loop.php:31 PhanSideEffectFreeDoWhileBody Saw a do-while loop which probably has no side effects src/057_do_while_loop.php:39 PhanPluginPossiblyStaticClosure Closure() can be static src/057_do_while_loop.php:40 PhanUnusedVariable Unused definition of variable $a src/057_do_while_loop.php:42 PhanSideEffectFreeDoWhileBody Saw a do-while loop which probably has no side effects src/057_do_while_loop.php:44 PhanUnusedVariable Unused definition of variable $a src/057_do_while_loop.php:52 PhanPluginPossiblyStaticClosure Closure() can be static src/057_do_while_loop.php:54 PhanPluginConstantVariableScalar Variable $a is probably constant with a value of 22 src/058_invalid_regex_replacement.php:5 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '\\1' to pattern '/foo/i' src/058_invalid_regex_replacement.php:6 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '$1' to pattern '/foo/i' src/058_invalid_regex_replacement.php:9 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '$1' to pattern '/foo/i' src/058_invalid_regex_replacement.php:10 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '\\11' to pattern '/foo/i' src/058_invalid_regex_replacement.php:11 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '$11' to pattern '/foo/i' src/058_invalid_regex_replacement.php:12 PhanPluginInvalidPregRegex Call to \preg_replace was passed an invalid regex '/missingenddelimiter': No ending delimiter '/' found src/058_invalid_regex_replacement.php:14 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '$2' to pattern '/(c|h)at/' src/058_invalid_regex_replacement.php:15 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '\\2' to pattern '/(c|h)at/' src/058_invalid_regex_replacement.php:18 PhanPluginConstantVariableScalar Variable $value is probably constant with a value of 'a hat' src/058_invalid_regex_replacement.php:18 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '\\2' to pattern '/(b)at/i' or '/(c|h)at/' src/059_invalid_regex_2.php:7 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '${1}' to pattern '/foo/i' src/059_invalid_regex_2.php:9 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '${01}' to pattern '/foo/i' src/059_invalid_regex_2.php:13 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '${99}' to pattern '/foo/i' src/059_invalid_regex_2.php:16 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '${12}' to pattern '/(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)/i' src/059_invalid_regex_2.php:18 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '$12' to pattern '/(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)/i' src/059_invalid_regex_2.php:20 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '$12' to pattern '/(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)/i' src/059_invalid_regex_2.php:25 PhanPluginInvalidPregRegexReplacement Call to \preg_replace was passed an invalid replacement reference '\\1' to pattern '/foo/i' src/060_strict_method_check.php:12 PhanPossiblyNonClassMethodCall Call to method count on type \ArrayObject|null that could be a non-object src/060_strict_method_check.php:13 PhanPossiblyNonClassMethodCall Call to method count on type \ArrayObject|false that could be a non-object src/060_strict_method_check.php:16 PhanPossiblyNonClassMethodCall Call to method count on type ?\ArrayObject that could be a non-object src/060_strict_method_check.php:18 PhanPossiblyNonClassMethodCall Call to method count on type \ArrayObject|array that could be a non-object src/060_strict_method_check.php:19 PhanNonClassMethodCall Call to method count on non-class type bool src/060_strict_method_check.php:19 PhanPluginUnknownObjectMethodCall Phan could not infer any class/interface types for the object of the method call $e->count() - inferred a type of bool src/061_strict_static_method_check.php:9 PhanUnreferencedFunction Possibly zero references to function \test() src/061_strict_static_method_check.php:11 PhanNonClassMethodCall Call to method someMethod on non-class type ?string src/061_strict_static_method_check.php:12 PhanPossiblyNonClassMethodCall Call to method someMethod on type null|string that could be a non-object src/061_strict_static_method_check.php:13 PhanPossiblyNonClassMethodCall Call to method someMethod on type false|string that could be a non-object src/061_strict_static_method_check.php:14 PhanPossiblyNonClassMethodCall Call to method someMethod on type array|string that could be a non-object src/062_strict_function_checking.php:17 PhanPluginNeverReturnFunction Function \test_strict_function_call() never returns and has a return type of void, but phpdoc type never could be used instead src/062_strict_function_checking.php:31 PhanParamTooFewInternal Call with 0 arg(s) to \strlen(string $string) which requires 1 arg(s) src/062_strict_function_checking.php:31 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \strlen src/062_strict_function_checking.php:33 PhanTypePossiblyInvalidCallable Saw type ?string which is possibly not a callable src/062_strict_function_checking.php:34 PhanTypeInvalidCallable Saw type null which cannot be a callable src/062_strict_function_checking.php:35 PhanTypePossiblyInvalidCallable Saw type callable|false which is possibly not a callable src/062_strict_function_checking.php:36 PhanTypePossiblyInvalidCallable Saw type array<string,mixed>|string which is possibly not a callable src/062_strict_function_checking.php:37 PhanTypeInvalidCallable Saw type array<string,mixed> which cannot be a callable src/062_strict_function_checking.php:38 PhanTypePossiblyInvalidCallable Saw type null|string which is possibly not a callable src/062_strict_function_checking.php:39 PhanTypePossiblyInvalidCallable Saw type int|string which is possibly not a callable src/062_strict_function_checking.php:42 PhanTypeInvalidCallableArraySize In a place where phan was expecting a callable, saw an array of size 1, but callable arrays must be of size 2 src/062_strict_function_checking.php:42 PhanTypeInvalidCallable Saw type array{key:string} which cannot be a callable src/062_strict_function_checking.php:44 PhanTypeInvalidCallable Saw type 2 which cannot be a callable src/062_strict_function_checking.php:45 PhanPluginUnreachableCode Unreachable statement detected src/062_strict_function_checking.php:45 PhanTypeInvalidCallable Saw type 2.3 which cannot be a callable src/063_unused_dynamic_constant.php:8 PhanUnreferencedConstant Possibly zero references to global constant \foo\dynamic2 src/064_callable_class_string.php:12 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $x of type callable-string but \intdiv() takes int src/064_callable_class_string.php:17 PhanUndeclaredFunctionInCallable Call to undeclared function stdClass in callable src/064_callable_class_string.php:18 PhanEmptyFQSENInCallable Possible call to a function '' with an empty FQSEN. src/064_callable_class_string.php:18 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is '' of type '' but \test_callable_string() takes callable-string (no real type) defined at src/064_callable_class_string.php:7 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/064_callable_class_string.php:19 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is (function) of type Closure():void but \test_callable_string() takes callable-string (no real type) defined at src/064_callable_class_string.php:7 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/064_callable_class_string.php:20 PhanInvalidFQSENInClasslike Possible use of a classlike '\invalid class name' with an invalid FQSEN. src/064_callable_class_string.php:20 PhanTypeMismatchArgumentInternalProbablyReal Argument 1 ($objectOrClass) is 'invalid class name' of type 'invalid class name' but \ReflectionClass::__construct() takes class-string|object src/064_callable_class_string.php:21 PhanUndeclaredClassReference Reference to undeclared class \Some\MissingClass src/064_callable_class_string.php:23 PhanEmptyFQSENInClasslike Possible use of a classlike '' with an empty FQSEN. src/064_callable_class_string.php:23 PhanTypeMismatchArgumentInternalProbablyReal Argument 1 ($objectOrClass) is '' of type '' but \ReflectionClass::__construct() takes class-string|object src/064_callable_class_string.php:25 PhanEmptyFQSENInCallable Possible call to a function '' with an empty FQSEN. src/064_callable_class_string.php:25 PhanTypeMismatchArgumentInternalProbablyReal Argument 1 ($function) is '' of type '' but \ReflectionFunction::__construct() takes \Closure|callable-string src/064_callable_class_string.php:27 PhanInvalidFQSENInCallable Possible call to a function 'an invalid function name' with an invalid FQSEN. src/064_callable_class_string.php:27 PhanTypeMismatchArgumentInternalProbablyReal Argument 1 ($function) is 'an invalid function name' of type 'an invalid function name' but \ReflectionFunction::__construct() takes \Closure|callable-string src/064_callable_class_string.php:28 PhanTypeMismatchArgument Argument 1 ($x) is 2 of type 2 but \test_callable_string() takes callable-string defined at src/064_callable_class_string.php:7 src/064_callable_class_string.php:38 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $x of type class-string but \intdiv() takes int src/064_callable_class_string.php:42 PhanUndeclaredClassReference Reference to undeclared class \strlen src/064_callable_class_string.php:44 PhanEmptyFQSENInClasslike Possible use of a classlike '' with an empty FQSEN. src/064_callable_class_string.php:44 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is '' of type '' but \test_class_string() takes class-string (no real type) defined at src/064_callable_class_string.php:34 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/064_callable_class_string.php:45 PhanInvalidFQSENInClasslike Possible use of a classlike '\ ' with an invalid FQSEN. src/064_callable_class_string.php:45 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is ' ' of type ' ' but \test_class_string() takes class-string (no real type) defined at src/064_callable_class_string.php:34 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/064_callable_class_string.php:46 PhanInvalidFQSENInClasslike Possible use of a classlike '\Phan should warn about this' with an invalid FQSEN. src/064_callable_class_string.php:46 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is 'Phan should warn about this' of type 'Phan should warn about this' but \test_class_string() takes class-string (no real type) defined at src/064_callable_class_string.php:34 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/064_callable_class_string.php:48 PhanUnreferencedFunction Possibly zero references to function \testCast() src/065_class_string_create.php:12 PhanTypeMismatchArgumentInternal Argument 1 ($string) is create_class('stdClass') of type \stdClass but \strlen() takes string src/065_class_string_create.php:13 PhanTypeMismatchArgumentInternal Argument 1 ($string) is create_class('invalidclass') of type \invalidclass but \strlen() takes string src/065_class_string_create.php:13 PhanUndeclaredClassReference Reference to undeclared class \invalidclass src/065_class_string_create.php:14 PhanTypeMismatchArgumentInternal Argument 1 ($string) is create_class('int') of type \int but \strlen() takes string src/065_class_string_create.php:14 PhanUndeclaredClassReference Reference to undeclared class \int src/065_class_string_create.php:15 PhanEmptyFQSENInClasslike Possible use of a classlike '' with an empty FQSEN. src/066_class_string_create.php:13 PhanStaticCallToNonStatic Static call to non-static method \C66::create_class() defined at src/066_class_string_create.php:8. This is an Error in PHP 8.0+. src/066_class_string_create.php:14 PhanStaticCallToNonStatic Static call to non-static method \C66::create_class() defined at src/066_class_string_create.php:8. This is an Error in PHP 8.0+. src/066_class_string_create.php:14 PhanTypeMismatchArgumentInternal Argument 1 ($string) is C66::create_class('stdClass') of type \stdClass but \strlen() takes string src/066_class_string_create.php:15 PhanStaticCallToNonStatic Static call to non-static method \C66::create_class() defined at src/066_class_string_create.php:8. This is an Error in PHP 8.0+. src/066_class_string_create.php:15 PhanTypeMismatchArgumentInternal Argument 1 ($string) is C66::create_class('invalidclass') of type \invalidclass but \strlen() takes string src/066_class_string_create.php:15 PhanUndeclaredClassReference Reference to undeclared class \invalidclass src/066_class_string_create.php:16 PhanStaticCallToNonStatic Static call to non-static method \C66::create_class() defined at src/066_class_string_create.php:8. This is an Error in PHP 8.0+. src/066_class_string_create.php:16 PhanTypeMismatchArgumentInternal Argument 1 ($string) is C66::create_class('int') of type \int but \strlen() takes string src/066_class_string_create.php:16 PhanUndeclaredClassReference Reference to undeclared class \int src/066_class_string_create.php:17 PhanEmptyFQSENInClasslike Possible use of a classlike '' with an empty FQSEN. src/066_class_string_create.php:17 PhanStaticCallToNonStatic Static call to non-static method \C66::create_class() defined at src/066_class_string_create.php:8. This is an Error in PHP 8.0+. src/067_throws_template.php:9 PhanTypeInvalidThrowsNonObject @throws annotation of maybe_throw has invalid non-object type T, expected a class src/067_throws_template.php:21 PhanTypeMismatchArgumentInternal Argument 1 ($value) is $result of type \Exception|\Stringable|\Throwable but \count() takes \Countable|\ResourceBundle|\SimpleXMLElement|array src/068_template_typeof.php:8 PhanUndeclaredClosureScope Reference to undeclared class \TTemplateType in @phan-closure-scope src/068_template_typeof.php:9 PhanPluginUnknownObjectMethodCall Phan could not infer any class/interface types for the object of the method call $this->method() - inferred a type of object src/068_template_typeof.php:9 PhanUndeclaredThis Variable $this is undeclared src/068_template_typeof.php:10 PhanNonClassMethodCall Call to method method on non-class type class-string<TTemplateType> src/068_template_typeof.php:10 PhanPluginUnknownObjectMethodCall Phan could not infer any class/interface types for the object of the method call $x->method() - inferred a type of class-string<TTemplateType> src/068_template_typeof.php:11 PhanTypeMismatchReturn Returning $x of type class-string<TTemplateType> but Closure($x) is declared to return TTemplateType src/069_template_var.php:11 PhanUnusedVariable Unused definition of variable $a src/069_template_var.php:12 PhanPluginConstantVariableScalar Variable $a is probably constant with a value of 'x' src/069_template_var.php:12 PhanPluginDollarDollar $$ Variables are not allowed. src/069_template_var.php:13 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $x of type T but \strlen() takes string src/069_template_var.php:15 PhanTypeMismatchReturn Returning [$x] of type array{0:T} but test_var_creation() is declared to return T src/069_template_var.php:24 PhanUnusedGlobalFunctionParameter Parameter $y is never used src/069_template_var.php:27 PhanPluginConstantVariableScalar Variable $a is probably constant with a value of 'y' src/069_template_var.php:27 PhanPluginDollarDollar $$ Variables are not allowed. src/069_template_var.php:28 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $x of type TInner but \strlen() takes string src/069_template_var.php:30 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $x of type TInner but \strlen() takes string src/069_template_var.php:32 PhanTypeMismatchReturn Returning [$x] of type array{0:TInner} but test_inline_var_creation() is declared to return array<string,TInner> src/069_template_var.php:44 PhanTemplateTypeNotUsedInFunctionReturn Template type TOther not used in return value of function/method test_inline_var_creation() src/069_template_var.php:47 PhanPluginConstantVariableScalar Variable $a is probably constant with a value of 'y' src/069_template_var.php:47 PhanPluginDollarDollar $$ Variables are not allowed. src/069_template_var.php:48 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $x of type TInner but \strlen() takes string src/069_template_var.php:50 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $x of type TInner but \strlen() takes string src/069_template_var.php:54 PhanPluginPossiblyStaticClosure Closure($arg) can be static src/069_template_var.php:60 PhanTypeMismatchReturn Returning $z of type TOther but test_inline_var_creation() is declared to return TInner src/069_template_var.php:63 PhanTypeMismatchReturn Returning [$x] of type array{0:TInner} but test_inline_var_creation() is declared to return TInner src/070_suggest_global_constant.php:5 PhanUndeclaredConstant Reference to undeclared constant \test_constant_completion. This will cause a thrown Error in php 8.0+. (Did you mean \test_constant_completion()) src/070_suggest_global_constant.php:5 PhanUnusedVariable Unused definition of variable $myVar src/070_suggest_global_constant.php:6 PhanUndeclaredConstant Reference to undeclared constant \myVar. This will cause a thrown Error in php 8.0+. (Did you mean $myVar) src/070_suggest_global_constant.php:7 PhanUndeclaredConstant Reference to undeclared constant \AST_BINARY_OP. This will cause a thrown Error in php 8.0+. (Did you mean \ast\AST_BINARY_OP) src/070_suggest_global_constant.php:8 PhanUnusedVariable Unused definition of variable $AST_UNARY_OP src/070_suggest_global_constant.php:9 PhanUndeclaredConstant Reference to undeclared constant \AST_UNARY_OP. This will cause a thrown Error in php 8.0+. (Did you mean $AST_UNARY_OP or \ast\AST_UNARY_OP) src/070_suggest_global_constant.php:10 PhanUndeclaredConstant Reference to undeclared constant \other\AST_UNARY_op. This will cause a thrown Error in php 8.0+. (Did you mean \ast\AST_UNARY_OP) src/070_suggest_global_constant.php:16 PhanUnreferencedConstant Possibly zero references to global constant \TestNS\SOME_lowercase_constant src/070_suggest_global_constant.php:19 PhanUnreferencedPublicClassConstant Possibly zero references to public class constant \TestNS\Foo70::SOME_CONSTANT_NAME src/070_suggest_global_constant.php:20 PhanUnreferencedPublicClassConstant Possibly zero references to public class constant \TestNS\Foo70::AST_BINARY_OP src/070_suggest_global_constant.php:21 PhanUnreferencedPublicProperty Possibly zero references to public property \TestNS\Foo70::$AST_BINARY_OP src/070_suggest_global_constant.php:22 PhanUnreferencedPrivateProperty Possibly zero references to private property \TestNS\Foo70->SOME_LOWERCASE_CONSTANT src/070_suggest_global_constant.php:24 PhanUndeclaredConstant Reference to undeclared constant \AST_BINARY_OP. This will cause a thrown Error in php 8.0+. (Did you mean \ast\AST_BINARY_OP or self::$AST_BINARY_OP or self::AST_BINARY_OP) src/070_suggest_global_constant.php:25 PhanUndeclaredConstant Reference to undeclared constant \SOME_LOWERCASE_CONSTANT. This will cause a thrown Error in php 8.0+. (Did you mean \TestNS\SOME_lowercase_constant) src/070_suggest_global_constant.php:26 PhanUndeclaredConstant Reference to undeclared constant \SOME_CONSTANT_NAME. This will cause a thrown Error in php 8.0+. (Did you mean self::SOME_CONSTANT_NAME) src/071_other_callable_methods.php:22 PhanTypeMismatchArgumentInternal Argument 1 ($string) is template_return_test(['InvokableTemplateTest','createArrayObject']) of type \ArrayAccess|\ArrayObject|\Countable|\IteratorAggregate|\Serializable|\Traversable|iterable but \strlen() takes string src/071_other_callable_methods.php:23 PhanUndeclaredStaticMethodInCallable Reference to undeclared static method \InvokableTemplateTest::missingMethod in callable src/071_other_callable_methods.php:24 PhanTypeMismatchArgumentInternal Argument 1 ($string) is template_return_test([$o,'createArrayObject']) of type \ArrayAccess|\ArrayObject|\Countable|\IteratorAggregate|\Serializable|\Traversable|iterable but \strlen() takes string src/071_other_callable_methods.php:25 PhanUndeclaredMethodInCallable Call to undeclared method missingMethod in callable. Possible object type(s) for that method are \InvokableTemplateTest src/071_other_callable_methods.php:26 PhanUndeclaredInvokeInCallable Possible attempt to access missing magic method __invoke of '\ArrayObject' src/071_other_callable_methods.php:28 PhanParamTooFew Call with 0 arg(s) to \InvokableTemplateTest::__invoke($arg) which requires 1 arg(s) defined at src/071_other_callable_methods.php:4 src/071_other_callable_methods.php:29 PhanUndeclaredInvokeInCallable Possible attempt to access missing magic method __invoke of '\stdClass' src/071_other_callable_methods.php:30 PhanTypeInvalidCallableArraySize In a place where phan was expecting a callable, saw an array of size 1, but callable arrays must be of size 2 src/071_other_callable_methods.php:35 PhanUndeclaredStaticMethodInCallable Reference to undeclared static method \InvokableTemplateTest::missingMethod in callable src/071_other_callable_methods.php:37 PhanUndeclaredMethodInCallable Call to undeclared method missingMethod in callable. Possible object type(s) for that method are \InvokableTemplateTest src/071_other_callable_methods.php:38 PhanTypeMismatchArgument Argument 1 ($c) is new ArrayObject() of type \ArrayAccess|\ArrayObject|\Countable|\IteratorAggregate|\Serializable|\Traversable|iterable but \non_template_return_test() takes callable defined at src/071_other_callable_methods.php:31 src/071_other_callable_methods.php:39 PhanTypeMismatchArgumentReal Argument 1 ($c) is $c of type array{0:\InvokableTemplateTest} but \non_template_return_test() takes callable defined at src/071_other_callable_methods.php:31 src/071_other_callable_methods.php:41 PhanUnreferencedFunction Possibly zero references to function \create_from_closure() src/071_other_callable_methods.php:59 PhanUndeclaredInvokeInCallable Possible attempt to access missing magic method __invoke of '\stdClass' src/071_other_callable_methods.php:60 PhanTypeMismatchArgumentInternal Argument 1 ($string) is template_return_test_array(['strlen']) of type int[] but \strlen() takes string src/072_custom_assertions.php:41 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $x of type string but \intdiv() takes int src/072_custom_assertions.php:43 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $y of type \stdClass but \intdiv() takes int src/072_custom_assertions.php:86 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $arg of type false|string but \intdiv() takes int src/072_custom_assertions.php:87 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $obj of type \stdClass but \intdiv() takes int src/072_custom_assertions.php:90 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $arg of type string but \intdiv() takes int src/072_custom_assertions.php:93 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $node of type \ast\Node but \strlen() takes string src/072_custom_assertions.php:118 PhanUndeclaredClassInstanceof Checking instanceof against undeclared class \SomeNS\missingClass src/072_custom_assertions.php:119 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/072_custom_assertions.php:120 PhanTypeMismatchArgumentInternalReal Argument 1 ($string) is $a of type \stdClass but \strlen() takes string src/072_custom_assertions.php:121 PhanTypeSuspiciousEcho Suspicious argument $b of type \SomeNS\missingClass for an echo/print statement src/072_custom_assertions.php:122 PhanPluginConstantVariableScalar Variable $c is probably constant with a value of 5 src/072_custom_assertions.php:122 PhanTypeErrorInInternalCall Saw a call to an internal function strlen() with what would be invalid arguments in strict mode, when trying to infer the return value literal type: strlen(): Argument #1 ($string) must be of type string, int given src/072_custom_assertions.php:122 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $c of type 5 but \strlen() takes string src/073_template_only_in_phpdoc.php:12 PhanPluginPossiblyStaticClosure Closure(\TTemplate1 $x) : \TTemplate1 can be static src/073_template_only_in_phpdoc.php:12 PhanUndeclaredTypeParameter Parameter $x has undeclared type \TTemplate1 src/073_template_only_in_phpdoc.php:12 PhanUndeclaredTypeReturnType Return type of Closure(\TTemplate1 $x) : \TTemplate1 is undeclared type \TTemplate1 src/073_template_only_in_phpdoc.php:15 PhanTypeMismatchArgument Argument 1 ($x) is $a of type TTemplate1 but Closure(\TTemplate1 $x) : \TTemplate1 takes \TTemplate1 defined at src/073_template_only_in_phpdoc.php:12 src/073_template_only_in_phpdoc.php:17 PhanPluginPossiblyStaticClosure Closure(\TTemplate2 $y) : \TTemplate2 can be static src/073_template_only_in_phpdoc.php:17 PhanUndeclaredTypeParameter Parameter $y has undeclared type \TTemplate2 src/073_template_only_in_phpdoc.php:17 PhanUndeclaredTypeReturnType Return type of Closure(\TTemplate2 $y) : \TTemplate2 is undeclared type \TTemplate2 src/073_template_only_in_phpdoc.php:20 PhanTypeMismatchArgument Argument 1 ($y) is $b of type TTemplate2 but Closure(\TTemplate2 $y) : \TTemplate2 takes \TTemplate2 defined at src/073_template_only_in_phpdoc.php:17 src/073_template_only_in_phpdoc.php:26 PhanPluginPossiblyStaticClosure Closure($y) can be static src/073_template_only_in_phpdoc.php:35 PhanUndeclaredTypeParameter Parameter $y has undeclared type \TTemplate2 src/073_template_only_in_phpdoc.php:35 PhanUndeclaredTypeReturnType Return type of Closure($y) is undeclared type \TTemplate2 src/073_template_only_in_phpdoc.php:38 PhanTypeMismatchArgument Argument 1 ($y) is $b of type TTemplate2 but Closure($y) takes \TTemplate2 defined at src/073_template_only_in_phpdoc.php:35 src/073_template_only_in_phpdoc.php:40 PhanUndeclaredClassMethod Call to method __construct from undeclared class \TTemplate1 src/074_unused_function_suppression.php:8 PhanPluginWhitespaceTab The first occurrence of a tab was seen here. Running "expand" can fix that. src/074_unused_function_suppression.php:13 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \function_suppression_test_fn() defined at src/074_unused_function_suppression.php:7 src/075_variable_suggestions.php:4 PhanUnusedVariable Unused definition of variable $unrelatedValuename (Did you mean $unrelatedValueName) src/075_variable_suggestions.php:8 PhanUnusedVariable Unused definition of variable $value2 (Did you mean $value1 or $value3) src/075_variable_suggestions.php:10 PhanPossiblyUndeclaredVariable Variable $value1 is possibly undeclared src/075_variable_suggestions.php:11 PhanPluginConstantVariableScalar Variable $value3 is probably constant with a value of 33 src/075_variable_suggestions.php:12 PhanTypeSuspiciousEcho Suspicious argument $unrelatedValueName of type null= for an echo/print statement src/075_variable_suggestions.php:12 PhanUndeclaredVariable Variable $unrelatedValueName is undeclared (Did you mean $unrelatedValuename) src/076_array_map_multiple.php:10 PhanPluginPossiblyStaticClosure Closure(\stdClass $x, string $y) : array can be static src/076_array_map_multiple.php:10 PhanTypeMismatchReturn Returning array_map((function), $a, $b) of type list<array> but array_map_multiple_test() is declared to return array<string,int> src/076_array_map_multiple.php:12 PhanTypeMismatchArgument Argument 1 ($x) is $a of type string but Closure(\stdClass $x, string $y) : array takes \stdClass defined at src/076_array_map_multiple.php:10 src/076_array_map_multiple.php:12 PhanTypeMismatchArgument Argument 2 ($y) is $b of type \stdClass but Closure(\stdClass $x, string $y) : array takes string defined at src/076_array_map_multiple.php:10 src/076_array_map_multiple.php:14 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \array_map_multiple_test() defined at src/076_array_map_multiple.php:8 src/077_both_literals.php:3 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 2 <=> 3 (result is -1) src/077_both_literals.php:4 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: null == 9 (result is false) src/077_both_literals.php:5 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: null === 9 (result is false) src/077_both_literals.php:5 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/077_both_literals.php:6 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 1 !== 9 (result is true) src/077_both_literals.php:6 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/077_both_literals.php:7 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 1 != 9 (result is true) src/077_both_literals.php:8 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 1 != 9 (result is true) src/077_both_literals.php:8 PhanPluginDuplicateAdjacentStatement Statement var_export(($x ?? (1 != 9))) is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/077_both_literals.php:9 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 2 < 3 (result is true) src/077_both_literals.php:10 PhanPluginDuplicateExpressionBinaryOp Both sides of the binary operator <= are the same: 2 src/077_both_literals.php:11 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 2 <= '700' (result is true) src/077_both_literals.php:12 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 3 > 2 (result is true) src/077_both_literals.php:13 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: 3 >= 4 (result is false) src/077_both_literals.php:14 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: true && false (result is false) src/077_both_literals.php:15 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: true && 'aString' (result is true) src/077_both_literals.php:15 PhanPluginNonBoolInLogicalArith Non bool value of type 'aString' in logical arithmetic src/077_both_literals.php:16 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: true || false (result is true) src/077_both_literals.php:17 PhanPluginBothLiteralsBinaryOp Suspicious usage of a binary operator where both operands are literals. Expression: true xor false (result is true) src/078_merge_bool_and.php:3 PhanPossiblyFalseTypeArgumentInternal Argument 1 ($string) is $x of type '10'|false but \strlen() takes string (false is incompatible) src/078_merge_bool_and.php:4 PhanNoopBinaryOperator Unused result of a binary '&&' operator src/078_merge_bool_and.php:4 PhanPluginNonBoolInLogicalArith Non bool value of type '10'|false in logical arithmetic src/078_merge_bool_and.php:5 PhanPossiblyFalseTypeArgumentInternal Argument 1 ($string) is $x of type '10'|false but \strlen() takes string (false is incompatible) src/079_both_booleans.php:5 PhanNoopBinaryOperator Unused result of a binary '&&' operator src/079_both_booleans.php:6 PhanNoopBinaryOperator Unused result of a binary '||' operator src/080_duplicate_key_expression.php:7 PhanPluginDuplicateArrayKeyExpression Duplicate dynamic array key expression ($x) detected in array - the earlier entry at line 6 will be ignored if the expression had the same value. src/080_duplicate_key_expression.php:9 PhanPluginDuplicateArrayKeyExpression Duplicate dynamic array key expression (('prefix' . $x)) detected in array - the earlier entry at line 5 will be ignored if the expression had the same value. src/080_duplicate_key_expression.php:10 PhanPluginDuplicateArrayKeyExpression Duplicate dynamic array key expression ($a->count()) detected in array - the earlier entry at line 4 will be ignored if the expression had the same value. src/081_use_return_value.php:2 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \sprintf src/081_use_return_value.php:3 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \count src/081_use_return_value.php:4 PhanNoopUnaryOperator Unused result of a unary '-' operator src/081_use_return_value.php:4 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \count src/081_use_return_value.php:5 PhanPluginEmptyStatementTryBody Empty statement list detected for the try statement's body src/081_use_return_value.php:9 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \Exception::getMessage src/081_use_return_value.php:11 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \Exception::getCode src/081_use_return_value.php:12 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \Exception::getCode src/081_use_return_value.php:13 PhanUndeclaredMethod Call to undeclared method \Exception::getMissing src/081_use_return_value.php:17 PhanNoopUnaryOperator Unused result of a unary '-' operator src/081_use_return_value.php:17 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \Exception::getCode src/081_use_return_value.php:18 PhanPluginEmptyStatementTryFinally Empty statement list detected for the try's finally body src/081_use_return_value.php:25 PhanPluginEmptyStatementTryFinally Empty statement list detected for the try's finally body src/082_unused_parameter.php:4 PhanUnusedPublicFinalMethodParameter Parameter $a is never used src/082_unused_parameter.php:7 PhanUnusedProtectedFinalMethodParameter Parameter $a is never used src/082_unused_parameter.php:10 PhanPrivateFinalMethod PHP warns about private method \C82::h() being final starting in php 8.0 src/082_unused_parameter.php:10 PhanUnusedPrivateFinalMethodParameter Parameter $a is never used src/083_unreferenced_class_element.php:4 PhanUnreferencedPrivateClassConstant Possibly zero references to private class constant \CUnref::X src/083_unreferenced_class_element.php:5 PhanUnreferencedProtectedClassConstant Possibly zero references to protected class constant \CUnref::Y src/083_unreferenced_class_element.php:6 PhanUnreferencedProtectedProperty Possibly zero references to protected property \CUnref::$protectedProp src/083_unreferenced_class_element.php:7 PhanPluginUseReturnValueNoopVoid The function/method \CUnref::privateMethod() is declared to return void and it has no side effects src/083_unreferenced_class_element.php:7 PhanUnreferencedPrivateMethod Possibly zero references to private method \CUnref::privateMethod() src/084_read_only_property.php:4 PhanReadOnlyPrivateProperty Possibly zero write references to private property \X84->arr src/084_read_only_property.php:5 PhanReadOnlyProtectedProperty Possibly zero write references to protected property \X84->count src/084_read_only_property.php:10 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \X84::main() defined at src/084_read_only_property.php:6 src/085_throw_type_mismatch.php:17 PhanThrowTypeMismatch \NS626\C::main() throws new RuntimeException('odd') of type \RuntimeException here, but it only has declarations of '@throws \InvalidArgumentException' src/085_throw_type_mismatch.php:19 PhanThrowTypeMismatch \NS626\C::main() throws null of type null here, but it only has declarations of '@throws \InvalidArgumentException' src/085_throw_type_mismatch.php:19 PhanTypeInvalidThrowStatementNonThrowable \NS626\C::main() can throw null of type null here which can't cast to \Throwable src/085_throw_type_mismatch.php:21 PhanThrowTypeMismatch \NS626\C::main() throws new FinalClass85() of type \NS626\FinalClass85 here, but it only has declarations of '@throws \InvalidArgumentException' src/085_throw_type_mismatch.php:21 PhanTypeInvalidThrowStatementNonThrowable \NS626\C::main() can throw new FinalClass85() of type \NS626\FinalClass85 here which can't cast to \Throwable src/085_throw_type_mismatch.php:23 PhanThrowTypeMismatchForCall \NS626\C::main() throws \TypeError because it calls \NS626\C::throw(), but it only has declarations of '@throws \InvalidArgumentException' src/085_throw_type_mismatch.php:29 PhanPluginNeverReturnMethod Method \NS626\C::throw() never returns and has a return type of (empty union type), but phpdoc type never could be used instead src/086_comment_param_assertions.php:3 PhanCommentParamOnEmptyParamList Saw an @param annotation for $args, but the param list of function no_params(); is empty src/086_comment_param_assertions.php:14 PhanCommentParamAssertionWithoutRealParam Saw an @phan-assert annotation for $second, but it was not found in the param list of assert_wrong_param() src/087_sprintf_on_literals.php:6 PhanPluginPrintfIncompatibleArgumentType Format string "Foo %s %d" refers to argument #2 as %d, so type int is expected, but sprintf was passed incompatible type '2nd bad arg' src/087_sprintf_on_literals.php:6 PhanTypeMismatchArgument Argument 1 ($a) is sprintf('Foo %s %d', 'arg', '2nd bad arg') of type 'Foo arg 2' but \expects_int() takes int defined at src/087_sprintf_on_literals.php:3 src/087_sprintf_on_literals.php:7 PhanPluginPrintfNoArguments No format string arguments are given for "Foo %s", consider using echo instead src/087_sprintf_on_literals.php:7 PhanPluginPrintfNonexistentArgument Format string "Foo %s" refers to nonexistent argument #1 in "%s". This will be an ArgumentCountError in PHP 8. src/087_sprintf_on_literals.php:7 PhanTypeMismatchArgument Argument 1 ($a) is sprintf('Foo %s') of type false but \expects_int() takes int defined at src/087_sprintf_on_literals.php:3 src/087_sprintf_on_literals.php:8 PhanPluginPrintfUnusedArgument Format string "Foo %s" does not use provided argument #2 src/087_sprintf_on_literals.php:8 PhanTypeMismatchArgument Argument 1 ($a) is sprintf('Foo %s', 'arg', 'extra arg') of type 'Foo arg' but \expects_int() takes int defined at src/087_sprintf_on_literals.php:3 src/087_sprintf_on_literals.php:9 PhanTypeMismatchArgument Argument 1 ($a) is sprintf('Foo %d', (2 + 3)) of type 'Foo 5' but \expects_int() takes int defined at src/087_sprintf_on_literals.php:3 src/088_possibly_invalid_argument.php:6 PhanPossiblyFalseTypeArgument Argument 1 ($x) is $o1 of type \stdClass|false but \expect_stdclass() takes \stdClass (false is incompatible) defined at src/088_possibly_invalid_argument.php:2 src/088_possibly_invalid_argument.php:8 PhanPossiblyNullTypeArgument Argument 1 ($x) is $o2 of type \stdClass|null but \expect_stdclass() takes \stdClass (null is incompatible) defined at src/088_possibly_invalid_argument.php:2 src/088_possibly_invalid_argument.php:10 PhanPartialTypeMismatchArgument Argument 1 ($x) is $o3 of type \ArrayObject|\stdClass but \expect_stdclass() takes \stdClass (\ArrayAccess|\ArrayObject|\Countable|\IteratorAggregate|\Serializable|\Traversable|iterable is incompatible) defined at src/088_possibly_invalid_argument.php:2 src/089_invalid_callable_key.php:3 PhanTypeInvalidCallableArrayKey In a place where phan was expecting a callable, saw an array with an unexpected key for element #1 (expected [$class_or_expr, $method_name]) src/089_invalid_callable_key.php:3 PhanTypeInvalidCallable Saw type array{0:string,2:string} which cannot be a callable src/089_invalid_callable_key.php:3 PhanTypeMismatchArgumentInternalReal Argument 1 ($callback) is [0=>$class,2=>$method] of type array{0:string,2:string} but \call_user_func() takes callable src/090_var_export_use_value.php:4 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \var_export src/090_var_export_use_value.php:7 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \print_r src/091_redeclare_constant.php:2 PhanNativePHPSyntaxCheckPlugin Saw error or notice for php --syntax-check: "Fatal error: Cannot redeclare constant 'true'" src/091_redeclare_constant.php:2 PhanReservedConstantName 'true' has a reserved keyword in the constant name src/091_redeclare_constant.php:3 PhanReservedConstantName 'foo\false' has a reserved keyword in the constant name src/091_redeclare_constant.php:4 PhanReservedConstantName 'NULL' has a reserved keyword in the constant name src/091_redeclare_constant.php:6 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value(1) detected in array - the earlier entry true at line 6 will be ignored. src/091_redeclare_constant.php:6 PhanTypeInvalidArrayKeyLiteral Saw array key true with key value true but expected a value that could cast to int|string src/092_isset_plugin_hang.php:4 PhanUnreferencedClass Possibly zero references to class \TestPhan src/092_isset_plugin_hang.php:7 PhanUnreferencedPublicMethod Possibly zero references to public method \TestPhan::test() src/093_multiple_format_strings.php:11 PhanTypeMismatchArgument Argument 1 ($x) is sprintf((rand(0, 2) ? '%sa' : '%sb'), 'x') of type 'xa'|'xb' but \expect_ab() takes 'ax'|'bx' defined at src/093_multiple_format_strings.php:6 src/093_multiple_format_strings.php:15 PhanPluginPrintfUnusedArgument Format string "The argument is %s" does not use provided argument #2 src/094_combination_regex.php:4 PhanTypeInvalidDimOffset Invalid offset 2 of $matches of array type array{0:string,1:string} src/094_combination_regex.php:4 PhanTypeSuspiciousEcho Suspicious argument $matches[2] of type null for an echo/print statement src/094_combination_regex.php:6 PhanTypeInvalidDimOffset Invalid offset 2 of $matches of array type array{0:string,1:string} src/094_combination_regex.php:6 PhanTypeSuspiciousEcho Suspicious argument $matches[2] of type null for an echo/print statement src/094_combination_regex.php:8 PhanTypeInvalidDimOffset Invalid offset 3 of $matches of array type array{0:string,1:string,2:string} src/094_combination_regex.php:8 PhanTypeSuspiciousEcho Suspicious argument $matches[3] of type null for an echo/print statement src/094_shutdown_function.php:3 PhanUndeclaredFunctionInCallable Call to undeclared function notafunction in callable src/094_shutdown_function.php:4 PhanUndeclaredClassInCallable Reference to undeclared class \MissingClass in callable \MissingClass::notafunction src/094_shutdown_function.php:6 PhanUndeclaredStaticMethodInCallable Reference to undeclared static method \stdClass::notafunction2 in callable src/095_suppress_next_next_line.php:3 PhanUndeclaredFunction Call to undeclared function \missing_func1() src/095_suppress_next_next_line.php:5 PhanUndeclaredFunction Call to undeclared function \missing_func3() src/095_suppress_next_next_line.php:11 PhanUndeclaredFunction Call to undeclared function \missing_func5() src/095_suppress_next_next_line.php:13 PhanPluginDuplicateAdjacentStatement Statement missing_func6() is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/095_suppress_next_next_line.php:13 PhanUndeclaredFunction Call to undeclared function \missing_func6() src/095_suppress_next_next_line.php:20 UnusedPluginSuppression Plugin BuiltinSuppressionPlugin suppresses issue PhanTypeMismatchArgument on this line but this suppression is unused or suppressed elsewhere src/095_suppress_next_next_line.php:21 PhanTypeMismatchArgument Argument 1 ($x) is new stdClass() of type \stdClass but \test_missing_class() takes \MissingClass defined at src/095_suppress_next_next_line.php:17 src/096_suspicious_name_order.php:12 PhanUnreferencedFunction Possibly zero references to function \test_caller() src/096_suspicious_name_order.php:13 PhanPluginSuspiciousParamOrder Suspicious order for arguments named second and first - These are being passed to parameters #1 ($first) and #2 ($second) of \test_order($first, $second, $third) defined at src/096_suspicious_name_order.php:3 src/096_suspicious_name_order.php:14 PhanPluginSuspiciousParamOrder Suspicious order for arguments named second and third and first - These are being passed to parameters #1 ($first) and #2 ($second) and #3 ($third) of \test_order($first, $second, $third) defined at src/096_suspicious_name_order.php:3 src/096_suspicious_name_order.php:15 PhanPluginSuspiciousParamOrder Suspicious order for arguments named second and first - These are being passed to parameters #1 ($first) and #2 ($second) of \test_order($first, $second, $third) defined at src/096_suspicious_name_order.php:3 src/096_suspicious_name_order.php:16 PhanPluginSuspiciousParamOrder Suspicious order for arguments named getThird and getFirst - These are being passed to parameters #1 ($first) and #3 ($third) of \test_order($first, $second, $third) defined at src/096_suspicious_name_order.php:3 src/096_suspicious_name_order.php:16 PhanPluginUnknownObjectMethodCall Phan could not infer any class/interface types for the object of the method call $o->getFirst() - inferred a type of object src/096_suspicious_name_order.php:16 PhanPluginUnknownObjectMethodCall Phan could not infer any class/interface types for the object of the method call $o->getSecond() - inferred a type of object src/096_suspicious_name_order.php:16 PhanPluginUnknownObjectMethodCall Phan could not infer any class/interface types for the object of the method call $o->getThird() - inferred a type of object src/096_suspicious_name_order.php:26 PhanUnreferencedFunction Possibly zero references to function \test_no_false_positive() src/096_suspicious_name_order.php:31 PhanPluginConstantVariableBool Variable $secondValue is probably constant with a value of false src/096_suspicious_name_order.php:31 PhanPluginSuspiciousParamOrder Suspicious order for arguments named secondValue and objFirst - These are being passed to parameters #1 (\stdClass $first) and #2 (bool $second) of \some_check(\stdClass $first, bool $second) defined at src/096_suspicious_name_order.php:19 src/096_suspicious_name_order.php:31 PhanTypeMismatchArgumentReal Argument 1 ($first) is $secondValue of type false but \some_check() takes \stdClass defined at src/096_suspicious_name_order.php:19 src/096_suspicious_name_order.php:31 PhanTypeMismatchArgumentReal Argument 2 ($second) is $objFirst of type \stdClass but \some_check() takes bool defined at src/096_suspicious_name_order.php:19 src/096_suspicious_name_order.php:32 PhanPluginConstantVariableBool Variable $secondValue is probably constant with a value of false src/096_suspicious_name_order.php:32 PhanPluginConstantVariableScalar Variable $third is probably constant with a value of 1 src/096_suspicious_name_order.php:32 PhanPluginSuspiciousParamOrder Suspicious order for arguments named secondValue and third and objFirst - These are being passed to parameters #1 (\stdClass $first) and #2 (bool $second) and #3 (int $third) of \some_check_chain(\stdClass $first, bool $second, int $third) defined at src/096_suspicious_name_order.php:22 src/096_suspicious_name_order.php:32 PhanTypeMismatchArgumentReal Argument 1 ($first) is $secondValue of type false but \some_check_chain() takes \stdClass defined at src/096_suspicious_name_order.php:22 src/096_suspicious_name_order.php:32 PhanTypeMismatchArgumentReal Argument 3 ($third) is $objFirst of type \stdClass but \some_check_chain() takes int defined at src/096_suspicious_name_order.php:22 src/096_suspicious_name_order.php:32 PhanTypeMismatchArgument Argument 2 ($second) is $third of type 1 but \some_check_chain() takes bool defined at src/096_suspicious_name_order.php:22 src/096_suspicious_name_order.php:36 PhanPluginRedundantAssignment Assigning 1 to variable $third which already has that value src/096_suspicious_name_order.php:38 PhanPluginConstantVariableBool Variable $objFirst is probably constant with a value of false src/096_suspicious_name_order.php:39 PhanPluginConstantVariableBool Variable $objFirst is probably constant with a value of false src/096_suspicious_name_order.php:39 PhanPluginConstantVariableScalar Variable $third is probably constant with a value of 1 src/096_suspicious_name_order.php:39 PhanPluginSuspiciousParamPosition Suspicious order for argument third - This is getting passed to parameter #3 (int $third) of \some_check_chain(\stdClass $first, bool $second, int $third) defined at src/096_suspicious_name_order.php:22 src/096_suspicious_name_order.php:39 PhanTypeMismatchArgument Argument 2 ($second) is $third of type 1 but \some_check_chain() takes bool defined at src/096_suspicious_name_order.php:22 src/096_suspicious_name_order.php:39 PhanTypeMismatchArgument Argument 3 ($third) is $objFirst of type false but \some_check_chain() takes int defined at src/096_suspicious_name_order.php:22 src/096_suspicious_name_order.php:44 PhanPluginSuspiciousParamOrderInternal Suspicious order for arguments named needle and haystack - These are being passed to parameters #1 (string $haystack) and #2 (int|string $needle) of \strpos(string $haystack, int|string $needle, int $offset = 0) src/096_suspicious_name_order.php:54 PhanReadOnlyPublicProperty Possibly zero write references to public property \Test96::$third src/096_suspicious_name_order.php:56 PhanReadOnlyPublicProperty Possibly zero write references to public property \Test96->SECOND src/096_suspicious_name_order.php:60 PhanPluginSuspiciousParamPosition Suspicious order for argument second - This is getting passed to parameter #2 (bool $second) of \has_optional($first = false, bool $second = true, $third = false) defined at src/096_suspicious_name_order.php:48 src/096_suspicious_name_order.php:61 PhanPluginSuspiciousParamPosition Suspicious order for argument third - This is getting passed to parameter #3 (mixed $third) of \has_optional($first = false, bool $second = true, $third = false) defined at src/096_suspicious_name_order.php:48 src/096_suspicious_name_order.php:62 PhanPluginSuspiciousParamPosition Suspicious order for argument third - This is getting passed to parameter #3 (mixed $third) of \has_optional($first = false, bool $second = true, $third = false) defined at src/096_suspicious_name_order.php:48 src/096_suspicious_name_order.php:63 PhanPluginSuspiciousParamPosition Suspicious order for argument first - This is getting passed to parameter #1 (mixed $first) of \has_optional($first = false, bool $second = true, $third = false) defined at src/096_suspicious_name_order.php:48 src/096_suspicious_name_order.php:63 PhanPluginSuspiciousParamPosition Suspicious order for argument third - This is getting passed to parameter #3 (mixed $third) of \has_optional($first = false, bool $second = true, $third = false) defined at src/096_suspicious_name_order.php:48 src/096_suspicious_name_order.php:64 PhanPluginSuspiciousParamPosition Suspicious order for argument SECOND - This is getting passed to parameter #2 (bool $second) of \has_optional($first = false, bool $second = true, $third = false) defined at src/096_suspicious_name_order.php:48 src/096_suspicious_name_order.php:64 PhanPluginSuspiciousParamPosition Suspicious order for argument third - This is getting passed to parameter #3 (mixed $third) of \has_optional($first = false, bool $second = true, $third = false) defined at src/096_suspicious_name_order.php:48 src/097_template_nullable.php:31 PhanTypeMismatchReturn Returning false of type false but getX() is declared to return ?T src/097_template_nullable.php:34 PhanTypeSuspiciousEcho Suspicious argument new NullableTemplate(new stdClass())->getX() of type ?\stdClass for an echo/print statement src/098_trailing_whitespace.php:4 PhanPluginWhitespaceTrailing The first occurrence of trailing whitespace was seen here. src/098_trailing_whitespace.php:6 PhanPluginWhitespaceTab The first occurrence of a tab was seen here. Running "expand" can fix that. src/099_dos_newline.php:1 PhanPluginWhitespaceCarriageReturn The first occurrence of a carriage return ("\r") was seen here. Running "dos2unix" can fix that. src/100_invalid_dim_offset.php:3 PhanUnreferencedClass Possibly zero references to class \AbuseFilterHooks src/100_invalid_dim_offset.php:9 PhanUnusedPrivateMethodParameter Parameter $enabled is never used src/100_invalid_dim_offset.php:18 PhanUnreferencedFunction Possibly zero references to function \example_inner() src/100_invalid_dim_offset.php:24 PhanPluginPossiblyStaticClosure Closure() can be static src/100_invalid_dim_offset.php:24 PhanUnreferencedClosure Possibly zero references to Closure() src/100_invalid_dim_offset.php:36 PhanUnreferencedPublicMethod Possibly zero references to public method \AbuseFilterHooks::onListDefinedTags() src/101_extended_return_inferences.php:11 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is json_decode('2') of type 2 but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:12 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is json_decode('{}', true) of type array{} but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:13 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is json_decode('[2]', true) of type array{0:2} but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:14 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is json_decode('{}', false) of type \stdClass but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:15 PhanTypeMismatchArgument Argument 1 ($x) is implode(',', [1]) of type '1' but \expect_zero() takes 0 defined at src/101_extended_return_inferences.php:8 src/101_extended_return_inferences.php:16 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is implode(',', [1,2]) of type '1\x2c2' but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:17 PhanTypeMismatchArgument Argument 1 ($x) is implode([1,2]) of type '12' but \expect_zero() takes 0 defined at src/101_extended_return_inferences.php:8 src/101_extended_return_inferences.php:18 PhanTypeMismatchArgument Argument 1 ($x) is json_encode(0) of type '0' but \expect_zero() takes 0 defined at src/101_extended_return_inferences.php:8 src/101_extended_return_inferences.php:19 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is strrev('test') of type 'tset' but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:20 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is strpos('test', 's') of type 2 but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:21 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is strripos('test', 'ES') of type 1 but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:22 PhanTypeErrorInInternalCall Saw a call to an internal function strlen() with what would be invalid arguments in strict mode, when trying to infer the return value literal type: strlen(): Argument #1 ($string) must be of type string, int given src/101_extended_return_inferences.php:22 PhanTypeMismatchArgumentInternal Argument 1 ($string) is 11 of type 11 but \strlen() takes string src/101_extended_return_inferences.php:23 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is strlen('test') of type 4 but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:24 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is ord('x') of type 120 but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:25 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is strtoupper('Test') of type 'TEST' but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:26 PhanTypeMismatchArgumentProbablyReal Argument 1 ($x) is strtolower('Test') of type 'test' but \expect_zero() takes 0 (no real type) defined at src/101_extended_return_inferences.php:8 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/101_extended_return_inferences.php:29 PhanTypeMismatchArgumentInternal Argument 1 ($stream) is json_decode($x, true) of type array|bool|float|int|null|string but \fwrite() takes resource src/101_extended_return_inferences.php:30 PhanTypeMismatchArgumentInternal Argument 1 ($stream) is json_decode($x, false) of type \stdClass|bool|float|int|list<mixed>|null|string but \fwrite() takes resource src/102_dead_code_detection_references.php:9 PhanWriteOnlyPublicProperty Possibly zero read references to public property \Test102->z src/103_suppress_unused_suppress.php:13 UnusedSuppression Element \test103b suppresses issue Unused-Issue-Not-In-Config but does not use it src/104_array_map.php:3 PhanTypeMismatchArgumentInternal Argument 1 ($value) is $results[0] of type string but \count() takes \Countable|\ResourceBundle|\SimpleXMLElement|array src/105_duplicate_array_key_newline.php:13 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case("help\n") detected in switch statement - the later entry will be ignored in favor of case "help\n" at line 7. src/105_duplicate_array_key_newline.php:24 PhanPluginDuplicateArrayKey Duplicate/Equivalent array key value("a\nb") detected in array - the earlier entry "a\nb" at line 23 will be ignored. src/107_ambiguous_switch.php:12 PhanPluginDuplicateSwitchCaseLooseEquality Switch case(1) is loosely equivalent (==) to an earlier case ('1e0') in switch statement - the earlier entry may be chosen instead. src/107_ambiguous_switch.php:24 PhanPluginDuplicateSwitchCaseLooseEquality Switch case('foo') is loosely equivalent (==) to an earlier case (0) in switch statement - the earlier entry may be chosen instead. src/107_ambiguous_switch.php:33 PhanPluginDuplicateSwitchCaseLooseEquality Switch case(1) is loosely equivalent (==) to an earlier case ('1bar') in switch statement - the earlier entry may be chosen instead. src/107_ambiguous_switch.php:36 PhanPluginDuplicateSwitchCaseLooseEquality Switch case('1e0') is loosely equivalent (==) to an earlier case (1) in switch statement - the earlier entry may be chosen instead. src/108_magic_property_unreferenced.php:5 PhanUnreferencedPHPDocProperty Possibly zero references to PHPDoc @property \Magic->bar src/108_magic_property_unreferenced.php:7 PhanUnreferencedPHPDocProperty Possibly zero references to PHPDoc @property \Magic->writeB src/108_magic_property_unreferenced.php:8 PhanWriteOnlyPHPDocProperty Possibly zero read references to PHPDoc @property \Magic->both1 src/108_magic_property_unreferenced.php:9 PhanReadOnlyPHPDocProperty Possibly zero write references to PHPDoc @property \Magic->both2 src/108_magic_property_unreferenced.php:11 PhanUnreferencedPHPDocProperty Possibly zero references to PHPDoc @property \Magic->both4 src/108_magic_property_unreferenced.php:14 PhanUnreferencedPublicProperty Possibly zero references to public property \Magic->realProp src/108_magic_property_unreferenced.php:26 PhanTypeMismatchProperty Assigning 2 of type 2 to property but \Magic->writeA is string src/109_unused_suppression_comment.php:13 PhanUnextractableAnnotation Saw unextractable annotation for comment '* @var int' src/109_unused_suppression_comment.php:17 UnusedSuppression Element \NS650\example2 suppresses issue PhanParamTooMany but does not use it src/110_duplicate_assignment.php:3 PhanPluginDuplicateExpressionAssignment Both sides of the assignment = are the same: $x src/110_duplicate_assignment.php:4 PhanPluginDuplicateExpressionAssignment Both sides of the assignment =& are the same: $y[0] src/113_possibly_static_method_with_static_closure.php:5 PhanPluginPossiblyStaticPublicMethod Public method \PSMClazz113::examplePublic() can be static src/113_possibly_static_method_with_static_closure.php:11 PhanPluginPossiblyStaticProtectedMethod Protected method \PSMClazz113::exampleProtected() can be static src/113_possibly_static_method_with_static_closure.php:17 PhanPluginPossiblyStaticPrivateMethod Private method \PSMClazz113::examplePrivate() can be static src/115_possibly_static_method_with_closure_without_this.php:4 PhanPluginPossiblyStaticPublicMethod Public method \PSMClazz115::examplePublic() can be static src/115_possibly_static_method_with_closure_without_this.php:5 PhanPluginPossiblyStaticClosure Closure() can be static src/115_possibly_static_method_with_closure_without_this.php:8 PhanPluginPossiblyStaticProtectedMethod Protected method \PSMClazz115::exampleProtected() can be static src/115_possibly_static_method_with_closure_without_this.php:9 PhanPluginPossiblyStaticClosure Closure() can be static src/115_possibly_static_method_with_closure_without_this.php:12 PhanPluginPossiblyStaticPrivateMethod Private method \PSMClazz115::examplePrivate() can be static src/115_possibly_static_method_with_closure_without_this.php:13 PhanPluginPossiblyStaticClosure Closure() can be static src/116_possibly_static_method_with_function.php:3 PhanPluginPossiblyStaticPublicMethod Public method \PSMClazz116::main() can be static src/116_possibly_static_method_with_function.php:5 PhanUndeclaredThis Variable $this is undeclared src/117_possibly_static_edge_case.php:21 PhanPluginPossiblyStaticPublicMethod Public method \PSMSubclass117::f2() can be static src/117_possibly_static_edge_case.php:31 PhanPluginPossiblyStaticPublicMethod Public method \PSMSubclass117::f4() can be static src/117_possibly_static_edge_case.php:36 PhanPluginPossiblyStaticPublicMethod Public method \PSMSubclass117::f4b() can be static src/117_possibly_static_edge_case.php:52 PhanPluginPossiblyStaticClosure Closure($x) can be static src/118_more_isset_checks.php:2 PhanUnreferencedFunction Possibly zero references to function \example118() src/118_more_isset_checks.php:3 PhanPluginDuplicateConditionalNullCoalescing "isset(X) ? X : Y" can usually be simplified to "X ?? Y" in PHP 7. The duplicated expression X was $arg src/118_more_isset_checks.php:4 PhanPluginDuplicateConditionalNullCoalescing "!is_null(X) ? X : Y" can usually be simplified to "X ?? Y" in PHP 7. The duplicated expression X was $arg src/118_more_isset_checks.php:5 PhanPluginDuplicateConditionalNullCoalescing "X !== null ? X : Y" can usually be simplified to "X ?? Y" in PHP 7. The duplicated expression X was $arg src/118_more_isset_checks.php:6 PhanPluginDuplicateConditionalNullCoalescing "null !== X ? X : Y" can usually be simplified to "X ?? Y" in PHP 7. The duplicated expression X was $arg src/119_increment_decrement_unused.php:4 PhanPluginDuplicateAdjacentStatement Statement --$y is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/119_increment_decrement_unused.php:4 PhanUnusedVariable Unused definition of variable $y src/119_increment_decrement_unused.php:5 PhanUnusedVariable Unused definition of variable $x src/119_increment_decrement_unused.php:6 PhanNoopVariable Unused variable src/119_increment_decrement_unused.php:6 PhanUnusedVariable Unused definition of variable $z src/119_increment_decrement_unused.php:8 PhanPluginConstantVariableScalar Variable $z is probably constant with a value of 2 src/119_increment_decrement_unused.php:13 PhanPossiblyInfiniteLoop The loop condition ($other < $n) does not seem to change within the loop and nothing seems to exit the loop src/119_increment_decrement_unused.php:15 PhanUnusedVariable Unused definition of variable $i src/119_increment_decrement_unused.php:15 PhanUnusedVariable Unused definition of variable $j src/119_increment_decrement_unused.php:21 PhanPluginUseReturnValueNoopVoid The function/method \test_loop119b() is declared to return void and it has no side effects src/119_increment_decrement_unused.php:21 PhanUnreferencedFunction Possibly zero references to function \test_loop119b() src/119_increment_decrement_unused.php:22 PhanSideEffectFreeForBody Saw a for loop which probably has no side effects src/119_increment_decrement_unused.php:23 PhanUnusedVariable Unused definition of variable $j src/121_unused_reference.php:3 PhanUnusedVariableReference Unused definition of variable $b as a reference src/121_unused_reference.php:5 PhanPluginConstantVariableScalar Variable $a is probably constant with a value of 2 src/121_unused_reference.php:9 PhanTypeSuspiciousStringExpression Suspicious type null= of a variable or expression $staticVar used to build a string. (Expected type to be able to cast to a string) src/121_unused_reference.php:9 PhanUndeclaredVariable Variable $staticVar is undeclared src/121_unused_reference.php:10 PhanUnusedVariableStatic Unreferenced definition of variable $staticVar as a static variable src/121_unused_reference.php:11 PhanUnusedVariableStatic Unreferenced definition of variable $staticUnreferencedVar as a static variable src/121_unused_reference.php:26 PhanUnusedVariableGlobal Unreferenced definition of variable $global121b as a global variable src/121_unused_reference.php:39 PhanPluginPossiblyStaticClosure Closure() can be static src/121_unused_reference.php:39 PhanUnusedVariableReference Unused definition of variable $dir_path as a reference src/121_unused_reference.php:40 PhanPluginConstantVariableScalar Variable $other is probably constant with a value of 'xyz' src/122_closure_reference.php:4 PhanPluginPossiblyStaticClosure Closure() can be static src/122_closure_reference.php:12 PhanPluginPossiblyStaticClosure Closure() can be static src/122_closure_reference.php:21 PhanPluginPossiblyStaticClosure Closure() can be static src/122_closure_reference.php:21 PhanUnusedVariableReference Unused definition of variable $was_called as a reference src/123_throw_static.php:2 PhanUnreferencedClass Possibly zero references to class \ThrowingException688 src/123_throw_static.php:6 PhanPluginNeverReturnMethod Method \ThrowingException688::throw() never returns and has a return type of (empty union type), but phpdoc type never could be used instead src/123_throw_static.php:6 PhanUnreferencedPublicMethod Possibly zero references to public method \ThrowingException688::throw() src/123_throw_static.php:13 PhanPluginNeverReturnMethod Method \ThrowingException688::throwOther() never returns and has a return type of (empty union type), but phpdoc type never could be used instead src/123_throw_static.php:13 PhanUnreferencedPublicMethod Possibly zero references to public method \ThrowingException688::throwOther() src/123_throw_static.php:14 PhanThrowTypeMismatch \ThrowingException688::throwOther() throws new RuntimeException('unexpected') of type \RuntimeException here, but it only has declarations of '@throws static' src/123_throw_static.php:20 PhanPluginNeverReturnMethod Method \ThrowingException688::throwStatic() never returns and has a return type of (empty union type), but phpdoc type never could be used instead src/123_throw_static.php:20 PhanUnreferencedPublicMethod Possibly zero references to public method \ThrowingException688::throwStatic() src/123_throw_static.php:21 PhanThrowTypeMismatch \ThrowingException688::throwStatic() throws new static('unexpected') of type static here, but it only has declarations of '@throws \RuntimeException' src/124_trailing_whitespace.php:7 PhanPluginInlineHTMLTrailing Saw inline HTML at the end of the file: "\n" src/125_trailing_html.php:7 PhanPluginInlineHTMLTrailing Saw inline HTML at the end of the file: "// This is inline HT..." src/126_inline_tag.php:5 PhanPluginInlineHTML Saw inline HTML between the first and last token: "<div>test</div>" src/127_leading_html.php:1 PhanPluginInlineHTMLLeading Saw inline HTML at the start of the file: "\n" src/128_leading_and_trailing.php:1 PhanPluginInlineHTMLLeading Saw inline HTML at the start of the file: "\n" src/128_leading_and_trailing.php:7 PhanPluginInlineHTMLTrailing Saw inline HTML at the end of the file: "\n" src/129_no_php.php:1 PhanPluginInlineHTMLLeading Saw inline HTML at the start of the file: "<php\n// this is not ..." src/130_duplicate_ternary.php:3 PhanPluginDuplicateConditionalUnnecessary "X ? Y : Y" results in the same expression Y no matter what X evaluates to. Y was $x src/131_duplicate_condition.php:6 PhanPluginDuplicateIfCondition Saw the same condition ($a == 1) in an earlier if/elseif statement src/131_duplicate_condition.php:14 PhanPluginDuplicateIfCondition Saw the same condition ($a == 2) in an earlier if/elseif statement src/131_duplicate_condition.php:26 PhanPluginDuplicateIfCondition Saw the same condition ($a == 2) in an earlier if/elseif statement src/132_compact.php:2 PhanUnusedGlobalFunctionParameter Parameter $myUnusedVar is never used src/132_compact.php:4 PhanPluginConstantVariableScalar Variable $nameToReturn is probably constant with a value of 'myOtherVar' src/132_use_return_value_in_loop.php:2 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \is_int src/132_use_return_value_in_loop.php:3 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \sprintf src/132_use_return_value_in_loop.php:5 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \intdiv src/133_throw_in_to_string.php:6 PhanPluginNeverReturnMethod Method \X133::__toString() never returns and has a return type of (empty union type), but phpdoc type never could be used instead src/133_throw_in_to_string.php:6 PhanThrowCommentInToString \X133::__toString() documents that it throws \RuntimeException, but throwing in __toString() is a fatal error prior to PHP 7.4 src/133_throw_in_to_string.php:7 PhanThrowStatementInToString \X133::__toString() throws \RuntimeException here, but throwing in __toString() is a fatal error prior to PHP 7.4 src/134_class_reference.php:4 PhanUnreferencedClass Possibly zero references to class \X\Y\Z\Other src/135_empty_statement_list.php:3 PhanPluginEmptyStatementForLoop Empty statement list detected for the for loop src/135_empty_statement_list.php:5 PhanPluginDuplicateAdjacentStatement Statement (for loop) is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/135_empty_statement_list.php:5 PhanPluginEmptyStatementForLoop Empty statement list detected for the for loop src/135_empty_statement_list.php:5 PhanPluginRedundantAssignmentInGlobalScope Assigning 0 to variable $i which already has that value src/135_empty_statement_list.php:8 PhanPluginEmptyStatementWhileLoop Empty statement list detected for the while loop src/135_empty_statement_list.php:9 PhanPluginEmptyStatementDoWhileLoop Empty statement list detected for the do-while loop src/135_empty_statement_list.php:13 PhanPluginEmptyStatementIf Empty statement list detected for the last if/elseif statement src/135_empty_statement_list.php:15 PhanEmptyForeachBody Saw a foreach statement with empty body over array of type array{0:2} (iterating has no side effects) src/135_empty_statement_list.php:15 PhanPluginEmptyStatementForeachLoop Empty statement list detected for the foreach loop src/136_unexpected_bracket.php:2 PhanSyntaxError Fallback parser diagnostic error: Unexpected ')' (at column 1) src/137_negated_empty_if_statement.php:2 PhanPluginNonBoolBranch Non bool value of type int evaluated in if clause src/138_suspicious_object_comparison.php:8 PhanPluginComparisonObjectEqualityNotStrict Saw a weak equality check on possible object types \C138 and \C138 in ($c1 == $c2) src/138_suspicious_object_comparison.php:8 PhanPluginNumericalComparison non numerical values compared by the operators '==' or '!=' src/138_suspicious_object_comparison.php:9 PhanPluginComparisonObjectEqualityNotStrict Saw a weak equality check on possible object types \C138 and \C138 in ($c1 != $c2) src/138_suspicious_object_comparison.php:9 PhanPluginNumericalComparison non numerical values compared by the operators '==' or '!=' src/138_suspicious_object_comparison.php:10 PhanPluginComparisonObjectOrdering Using comparison operator on possible object types \C138 and \C138 in ($c1 <= $c2) src/138_suspicious_object_comparison.php:11 PhanPluginComparisonObjectOrdering Using comparison operator on possible object types \C138 and \C138 in ($c1 >= $c2) src/138_suspicious_object_comparison.php:12 PhanPluginComparisonObjectOrdering Using comparison operator on possible object types \C138 and \C138 in ($c1 < $c2) src/138_suspicious_object_comparison.php:13 PhanPluginComparisonObjectOrdering Using comparison operator on possible object types \C138 and \C138 in ($c1 > $c2) src/138_suspicious_object_comparison.php:14 PhanPluginComparisonObjectOrdering Using comparison operator on possible object types \C138 and \C138 in ($c1 <=> $c2) src/138_suspicious_object_comparison.php:15 PhanTypeInvalidBitwiseBinaryOperator Invalid non-int/non-string operand provided to operator '|' between types \C138 and \C138 src/138_suspicious_object_comparison.php:15 PhanTypeInvalidLeftOperandOfBitwiseOp Invalid operator: left operand of | is \C138 (expected int|string) src/138_suspicious_object_comparison.php:15 PhanTypeInvalidRightOperandOfBitwiseOp Invalid operator: right operand of | is \C138 (expected int|string) src/139_suppress_empty_statement_warning.php:4 PhanPluginEmptyStatementTryFinally Empty statement list detected for the try's finally body src/139_suppress_empty_statement_warning.php:8 PhanPluginEmptyStatementPossiblyNonThrowingTryBody Found a try block that looks like it might not throw. Note that this check is a heuristic prone to false positives, especially because error handlers, signal handlers, destructors, and other things may all lead to throwing. src/139_suppress_empty_statement_warning.php:18 PhanPluginDuplicateAdjacentStatement Statement (if statement) is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/139_suppress_empty_statement_warning.php:18 PhanPluginEmptyStatementIf Empty statement list detected for the last if/elseif statement src/139_suppress_empty_statement_warning.php:26 PhanPluginDuplicateAdjacentStatement Statement (while loop) is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/139_suppress_empty_statement_warning.php:26 PhanPluginEmptyStatementWhileLoop Empty statement list detected for the while loop src/139_suppress_empty_statement_warning.php:30 PhanEmptyForeachBody Saw a foreach statement with empty body over array of type array{0:2} (iterating has no side effects) src/139_suppress_empty_statement_warning.php:34 PhanEmptyForeachBody Saw a foreach statement with empty body over array of type array{0:2} (iterating has no side effects) src/139_suppress_empty_statement_warning.php:34 PhanPluginDuplicateAdjacentStatement Statement (foreach loop) is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/139_suppress_empty_statement_warning.php:34 PhanPluginEmptyStatementForeachLoop Empty statement list detected for the foreach loop src/139_suppress_empty_statement_warning.php:41 PhanPluginDuplicateAdjacentStatement Statement (for loop) is a duplicate of the statement on the above line. Suppress this issue instance if there's a good reason for this. src/139_suppress_empty_statement_warning.php:41 PhanPluginEmptyStatementForLoop Empty statement list detected for the for loop src/140_use_return_value_misc.php:3 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \preg_match src/140_use_return_value_misc.php:10 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \class_exists src/140_use_return_value_misc.php:12 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \interface_exists src/140_use_return_value_misc.php:14 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \trait_exists src/140_use_return_value_misc.php:16 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \call_user_func src/140_use_return_value_misc.php:17 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \call_user_func_array src/140_use_return_value_misc.php:19 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \call_user_func src/140_use_return_value_misc.php:20 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \call_user_func_array src/140_use_return_value_misc.php:29 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \preg_match_all src/140_use_return_value_misc.php:32 PhanTypeMismatchArgumentInternal Argument 2 ($return) is 0 of type 0 but \var_export() takes bool src/140_use_return_value_misc.php:33 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \var_export src/140_use_return_value_misc.php:33 PhanTypeMismatchArgumentInternal Argument 2 ($return) is 1 of type 1 but \var_export() takes bool src/141_empty_statement_switch.php:4 PhanNoopSwitchCases This switch statement only has the default case src/141_empty_statement_switch.php:4 PhanPluginEmptyStatementSwitch No side effects seen for any cases of this switch statement src/141_empty_statement_switch.php:6 PhanNoopSwitchCases This switch statement only has the default case src/141_empty_statement_switch.php:6 PhanPluginEmptyStatementSwitch No side effects seen for any cases of this switch statement src/141_empty_statement_switch.php:10 PhanPluginEmptyStatementSwitch No side effects seen for any cases of this switch statement src/141_empty_statement_switch.php:11 PhanNoopStringLiteral Unused result of a string literal "not a statement" near this line src/141_empty_statement_switch.php:16 PhanPluginEmptyStatementSwitch No side effects seen for any cases of this switch statement src/141_empty_statement_switch.php:18 PhanContinueTargetingSwitch "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? src/142_phan_ignore_reference.php:19 PhanPluginConstantVariableScalar Variable $fmt is probably constant with a value of 'Hello\x2c %s!' src/142_phan_ignore_reference.php:19 PhanPluginConstantVariableScalar Variable $fmt2 is probably constant with a value of 'Bye\x2c %s!' src/142_phan_ignore_reference.php:20 PhanPluginPrintfVariableFormatString Code $fmt has a dynamic format string that could not be inferred by Phan src/142_phan_ignore_reference.php:21 PhanPluginPrintfVariableFormatString Code $fmt2 has a dynamic format string that could not be inferred by Phan src/142_phan_ignore_reference.php:23 PhanTypeMismatchArgumentReal Argument 1 ($fmt) is null of type null but \prepend_format_string() takes string defined at src/142_phan_ignore_reference.php:10 src/142_phan_ignore_reference.php:23 PhanTypeMismatchArgumentReal Argument 2 ($fmt2) is null of type null but \prepend_format_string() takes string defined at src/142_phan_ignore_reference.php:10 src/142_phan_ignore_reference.php:23 PhanTypeNonVarPassByRef Only variables can be passed by reference at argument 1 of \prepend_format_string(string &$fmt, string &$fmt2) src/142_phan_ignore_reference.php:23 PhanTypeNonVarPassByRef Only variables can be passed by reference at argument 2 of \prepend_format_string(string &$fmt, string &$fmt2) src/143_invalid_variable_isset_nonvar.php:4 PhanReadOnlyPublicProperty Possibly zero write references to public property \X143::$queryCache src/143_invalid_variable_isset_nonvar.php:10 PhanPluginUndeclaredVariableIsset undeclared variable $self in isset() src/143_invalid_variable_isset_nonvar.php:10 PhanTypeExpectedObjectStaticPropAccess Expected an object instance or a class name when accessing a static property, but saw an expression $self with type null= src/143_invalid_variable_isset_nonvar.php:10 PhanUndeclaredVariable Variable $self is undeclared src/143_invalid_variable_isset_nonvar.php:11 PhanTypeExpectedObjectStaticPropAccess Expected an object instance or a class name when accessing a static property, but saw an expression $self with type null= src/143_invalid_variable_isset_nonvar.php:11 PhanUndeclaredVariable Variable $self is undeclared src/143_invalid_variable_isset_nonvar.php:13 PhanPluginInvalidVariableIsset Unexpected expression in isset() src/143_invalid_variable_isset_nonvar.php:13 PhanTypeExpectedObjectPropAccess Expected an object instance when accessing an instance property, but saw an expression 'bar' with type string src/144_bad_clone.php:5 PhanUnreferencedFunction Possibly zero references to function \test_clone_return_type() src/144_bad_clone.php:6 PhanTypeInvalidCloneNotObject Expected an object to be passed to clone() but got string src/144_bad_clone.php:10 PhanTypeMismatchReturnReal Returning $x of type object but test_clone_return_type() is declared to return string src/144_bad_clone.php:13 PhanUnreferencedFunction Possibly zero references to function \test_clone_return_type2() src/144_bad_clone.php:14 PhanTypeMismatchReturnReal Returning (clone($x)) of type \stdClass but test_clone_return_type2() is declared to return \ArrayObject src/144_bad_clone.php:14 PhanTypePossiblyInvalidCloneNotObject Expected an object to be passed to clone() but got possible non-object ?\stdClass src/145_fibonacci_use_return_value.php:10 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \fibonacci145() defined at src/145_fibonacci_use_return_value.php:3 src/145_fibonacci_use_return_value.php:27 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \X145::f() defined at src/145_fibonacci_use_return_value.php:12 src/145_fibonacci_use_return_value.php:28 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \X145::f() defined at src/145_fibonacci_use_return_value.php:12 src/145_fibonacci_use_return_value.php:29 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \X145::g() defined at src/145_fibonacci_use_return_value.php:19 src/146_dependent_args_pure.php:14 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \f146c() defined at src/146_dependent_args_pure.php:9 src/147_use_return_value.php:4 PhanPluginPossiblyStaticClosure Closure(int $v) can be static src/147_use_return_value.php:8 PhanPluginPossiblyStaticClosure Closure(int $v) can be static src/147_use_return_value.php:12 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method Closure(int $v) defined at src/147_use_return_value.php:4 src/148_use_return_value_recursive.php:14 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \f148() defined at src/148_use_return_value_recursive.php:11 src/148_use_return_value_recursive.php:15 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \g148() defined at src/148_use_return_value_recursive.php:3 src/148_use_return_value_recursive.php:16 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \square148() defined at src/148_use_return_value_recursive.php:7 src/149_use_return_value_functional.php:12 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \odds149() defined at src/149_use_return_value_functional.php:6 src/150_use_constructor.php:17 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \MyClass150::makeInstance() defined at src/150_use_constructor.php:10 src/150_use_constructor.php:18 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \make_myclass() defined at src/150_use_constructor.php:14 src/150_use_constructor.php:21 PhanPluginUseReturnValueNoopVoid The function/method \my_void150() is declared to return void and it has no side effects src/150_use_constructor.php:22 PhanNoopNew Unused result of new object creation expression in new MyClass150($x) (this may be called for the side effects of the non-empty constructor or destructor) src/151_unreferenced_method_line.php:5 PhanUnreferencedPublicMethod Possibly zero references to public method \HasUnusedMethod::foo() src/151_unreferenced_method_line.php:10 PhanPluginPossiblyStaticClosure Closure() can be static src/152_phan_pure_annotation.php:30 PhanPartialTypeMismatchReturn Returning (debug_trace_nonpure((string)($x)) * 3) of type float|int but triple1() is declared to return int (float is incompatible) src/152_phan_pure_annotation.php:30 PhanTypeInvalidLeftOperandOfNumericOp Invalid operator: left operand of * is string (expected number) src/152_phan_pure_annotation.php:37 PhanPartialTypeMismatchReturn Returning (debug_trace_nonpure((string)($x)) * 3) of type float|int but triple2() is declared to return int (float is incompatible) src/152_phan_pure_annotation.php:37 PhanTypeInvalidLeftOperandOfNumericOp Invalid operator: left operand of * is string (expected number) src/152_phan_pure_annotation.php:45 PhanPluginNonBoolBranch Non bool value of type false|string evaluated in if clause src/152_phan_pure_annotation.php:52 PhanPluginNonBoolBranch Non bool value of type false|string evaluated in if clause src/152_phan_pure_annotation.php:58 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \NS152\debug_trace() defined at src/152_phan_pure_annotation.php:44 src/152_phan_pure_annotation.php:62 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \NS152\Debug::double1() defined at src/152_phan_pure_annotation.php:12 src/152_phan_pure_annotation.php:64 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \NS152\Debug::triple1() defined at src/152_phan_pure_annotation.php:29 src/152_phan_pure_annotation.php:67 PhanPluginPossiblyStaticClosure Closure($o) can be static src/152_phan_pure_annotation.php:77 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method Closure($o) defined at src/152_phan_pure_annotation.php:72 src/153_phan_pure_inherit.php:31 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \NS153\X::mul1() defined at src/153_phan_pure_inherit.php:7 src/153_phan_pure_inherit.php:34 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \NS153\Tripler::mul1() defined at src/153_phan_pure_inherit.php:19 src/153_phan_pure_inherit.php:38 PhanInvalidCommentForDeclarationType The phpdoc comment for @phan-side-effect-free cannot occur on a property src/153_phan_pure_inherit.php:39 PhanUnreferencedPublicProperty Possibly zero references to public property \NS153\Invalid->x src/153_phan_pure_inherit.php:64 PhanAccessReadOnlyProperty Cannot modify read-only property \NS153\PureClassExample->prop defined at src/153_phan_pure_inherit.php:47 src/153_phan_pure_inherit.php:66 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \NS153\PureClassExample::getSortedProp() defined at src/153_phan_pure_inherit.php:53 src/154_phan_pure_magic.php:25 PhanUnusedPublicNoOverrideMethodParameter Parameter $name is never used src/154_phan_pure_magic.php:25 PhanUnusedPublicNoOverrideMethodParameter Parameter $value is never used src/154_phan_pure_magic.php:33 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \Magic154::__get() defined at src/154_phan_pure_magic.php:28 src/154_phan_pure_magic.php:34 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \Magic154::__call() defined at src/154_phan_pure_magic.php:15 src/154_phan_pure_magic.php:36 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \Magic154::instance_fn() defined at src/154_phan_pure_magic.php:5 src/154_phan_pure_magic.php:38 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \Magic154::__call() defined at src/154_phan_pure_magic.php:15 src/154_phan_pure_magic.php:39 PhanAccessReadOnlyProperty Cannot modify read-only property \Magic154->values defined at src/154_phan_pure_magic.php:9 src/155_use_return_value_check_defining.php:2 PhanUnreferencedFunction Possibly zero references to function \show_runtime_exception() src/155_use_return_value_check_defining.php:3 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \Exception::getCode src/156_parent_type.php_crash:8 PhanUnusedPublicNoOverrideMethodParameter Parameter $args is never used src/156_parent_type.php_crash:8 PhanUnusedPublicNoOverrideMethodParameter Parameter $method is never used src/156_parent_type.php_crash:24 PhanPluginPossiblyStaticClosure Closure() can be static src/156_parent_type.php_crash:27 PhanUndeclaredProperty Reference to undeclared property \A156->prop src/156_parent_type.php_crash:33 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $c->declared of type int but \strlen() takes string src/156_parent_type.php_crash:36 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $d->declared of type int but \strlen() takes string src/156_parent_type.php_crash:38 PhanTypeMismatchArgumentReal Argument 1 ($arg) is $b of type \B156 but \accepts_A156() takes \A156 defined at src/156_parent_type.php_crash:21 src/156_parent_type.php_crash:39 PhanTypeMismatchArgumentReal Argument 1 ($arg) is $c of type \C156|\D156 but \accepts_A156() takes \A156 defined at src/156_parent_type.php_crash:21 src/156_parent_type.php_crash:40 PhanTypeMismatchArgumentReal Argument 1 ($arg) is $d of type \C156|\D156 but \accepts_A156() takes \A156 defined at src/156_parent_type.php_crash:21 src/157_polyfill_compilation_warning.php:3 PhanNativePHPSyntaxCheckPlugin Saw error or notice for php --syntax-check: "Parse error: Unterminated comment starting line 3" src/158_loop_variable_reuse.php:5 PhanPluginLoopVariableReuse Variable $elem used in loop was also used in an outer loop on line 3 src/158_loop_variable_reuse.php:5 PhanPluginLoopVariableReuse Variable $i used in loop was also used in an outer loop on line 3 src/158_loop_variable_reuse.php:12 PhanPluginLoopVariableReuse Variable $j used in loop was also used in an outer loop on line 10 src/158_loop_variable_reuse.php:20 PhanPluginLoopVariableReuse Variable $j used in loop was also used in an outer loop on line 17 src/159_array_unshift_convert_to_list.php:9 PhanTypeMismatchReturn Returning $values of type non-empty-list<string> but test_unshift_converts_assoc_int_to_list() is declared to return associative-array<int,string> src/159_array_unshift_convert_to_list.php:18 PhanPartialTypeMismatchReturn Returning $values of type non-empty-array<string,string>|non-empty-list<string> but test_unshift_doesnt_convert_assoc_string() is declared to return list<string> (non-empty-array<string,string> is incompatible) src/160_useless_return.php:7 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/160_useless_return.php:12 PhanUnusedReturnBranchWithoutSideEffects Possibly useless branch in a function where the return value must be used - all branches return values equivalent to true (previous return is at line 8) src/160_useless_return.php:18 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/160_useless_return.php:23 PhanUnusedReturnBranchWithoutSideEffects Possibly useless branch in a function where the return value must be used - all branches return values equivalent to true (previous return is at line 19) src/160_useless_return.php:26 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \NS160\Test::is_even() defined at src/160_useless_return.php:16 src/160_useless_return.php:28 PhanUnreferencedClass Possibly zero references to class \NS160\TestItem src/160_useless_return.php:37 PhanUnreferencedPublicMethod Possibly zero references to public method \NS160\TestItem::fn() src/160_useless_return.php:41 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/160_useless_return.php:45 PhanUnusedReturnBranchWithoutSideEffects Possibly useless branch in a function where the return value must be used - all branches return values equivalent to true (previous return is at line 42) src/160_useless_return.php:62 PhanUnusedReturnBranchWithoutSideEffects Possibly useless branch in a function where the return value must be used - all branches return values equivalent to false (previous return is at line 60) src/160_useless_return.php:72 PhanUnusedReturnBranchWithoutSideEffects Possibly useless branch in a function where the return value must be used - all branches return values equivalent to (3 - 1) (previous return is at line 70) src/160_useless_return.php:89 PhanPluginPossiblyStaticClosure Closure($arg) : bool can be static src/160_useless_return.php:94 PhanPluginDuplicateIfStatements The statements of the else duplicate the statements of the previous if/elseif statement with condition is_int($arg) src/160_useless_return.php:95 PhanUnusedReturnBranchWithoutSideEffects Possibly useless branch in a function where the return value must be used - all branches return values equivalent to false (previous return is at line 93) src/160_useless_return.php:99 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method Closure($arg) : bool defined at src/160_useless_return.php:89 src/160_useless_return.php:100 PhanPluginPossiblyStaticClosure Closure($arg) can be static src/160_useless_return.php:106 PhanUnusedReturnBranchWithoutSideEffects Possibly useless branch in a function where the return value must be used - all branches return values equivalent to Null (previous return is at line 104) src/160_useless_return.php:119 PhanUnusedReturnBranchWithoutSideEffects Possibly useless branch in a function where the return value must be used - all branches return values equivalent to [PHP_VERSION] (previous return is at line 115) src/160_useless_return.php:125 PhanPluginNonBoolBranch Non bool value of type mixed evaluated in if clause src/160_useless_return.php:127 PhanPluginDuplicateIfStatements The statements of the else duplicate the statements of the previous if/elseif statement with condition $arg src/161_top_level_noop.php:7 PhanNoopTernary Unused result of a ternary expression where the true/false results don't seem to have side effects src/161_top_level_noop.php:7 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \json_encode src/161_top_level_noop.php:7 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \strlen src/161_top_level_noop.php:8 PhanNoopTernary Unused result of a ternary expression where the true/false results don't seem to have side effects src/161_top_level_noop.php:8 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \json_encode src/161_top_level_noop.php:10 PhanNoopBinaryOperator Unused result of a binary '&&' operator src/161_top_level_noop.php:10 PhanPluginNonBoolInLogicalArith Non bool value of type false|string in logical arithmetic src/161_top_level_noop.php:10 PhanPluginNonBoolInLogicalArith Non bool value of type int in logical arithmetic src/161_top_level_noop.php:10 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \strlen src/161_top_level_noop.php:11 PhanNoopBinaryOperator Unused result of a binary '||' operator src/161_top_level_noop.php:11 PhanPluginNonBoolInLogicalArith Non bool value of type false|string in logical arithmetic src/161_top_level_noop.php:11 PhanPluginNonBoolInLogicalArith Non bool value of type string in logical arithmetic src/161_top_level_noop.php:11 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \var_export src/161_top_level_noop.php:13 PhanNoopBinaryOperator Unused result of a binary '??' operator src/161_top_level_noop.php:13 PhanPluginUseReturnValueInternalKnown Expected to use the return value of the internal function/method \strlen src/162_redundant_assignment.php:5 PhanPluginRedundantAssignment Assigning false to variable $x which already has that value src/162_redundant_assignment.php:9 PhanPluginRedundantAssignment Assigning true to variable $y which already has that value src/162_redundant_assignment.php:13 PhanPluginRedundantAssignment Assigning null to variable $z which already has that value src/162_redundant_assignment.php:17 PhanPluginRedundantAssignment Assigning array{0:'first',1:'second'} to variable $a which already has that value src/162_redundant_assignment.php:19 PhanPluginConstantVariableBool Variable $x is probably constant with a value of false src/162_redundant_assignment.php:19 PhanPluginConstantVariableBool Variable $y is probably constant with a value of true src/162_redundant_assignment.php:19 PhanPluginConstantVariableNull Variable $z is probably constant with a value of null src/162_redundant_assignment.php:21 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \test_redundant_assignments() defined at src/162_redundant_assignment.php:2 src/162_redundant_assignment.php:22 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \test_redundant_assignments() defined at src/162_redundant_assignment.php:2 src/163_in_array_impossible.php:8 PhanPluginPossiblyStaticClosure Closure($result) : void can be static src/163_in_array_impossible.php:15 PhanImpossibleTypeComparison Impossible attempt to check if null of type null is identical to elements of [0] of type 0 src/163_in_array_impossible.php:16 PhanImpossibleTypeComparison Impossible attempt to check if 0.0 of type 0.0 is identical to elements of [0] of type 0 src/163_in_array_impossible.php:19 PhanPluginPossiblyStaticClosure Closure(\stdClass $o1, \stdClass $o2, int $i, int ...$other) can be static src/163_in_array_impossible.php:22 PhanImpossibleTypeComparison Impossible attempt to check if $o2 of type \stdClass is identical to elements of $other of type int src/163_in_array_impossible.php:23 PhanImpossibleTypeComparison Impossible attempt to check if 2.3 of type 2.3 is identical to elements of $other of type int src/163_in_array_impossible.php:24 PhanSuspiciousWeakTypeComparison Suspicious attempt to compare $o2 of type \stdClass to elements of $other of type int src/163_in_array_impossible.php:26 PhanSuspiciousWeakTypeComparison Suspicious attempt to compare $o2 of type \stdClass to elements of [] of type (no types in empty array) src/163_in_array_impossible.php:27 PhanSuspiciousWeakTypeComparison Suspicious attempt to compare $o2 of type \stdClass to elements of [$i] of type int src/163_in_array_impossible.php:28 PhanSuspiciousWeakTypeComparison Suspicious attempt to compare $o1 of type \stdClass to elements of [null] of type null src/163_in_array_impossible.php:31 PhanImpossibleTypeComparison Impossible attempt to check if false of type false is identical to elements of [$i,$o1,$o2] of type \stdClass|int src/163_in_array_impossible.php:34 PhanImpossibleTypeComparison Impossible attempt to check if $o2 of type \stdClass is identical to elements of [] of type (no types in empty array) src/164_array_values_redundant.php:5 PhanRedundantArrayValuesCall Attempting to convert list<int> to a list using \array_values() (it is already a list) src/164_array_values_redundant.php:5 PhanRedundantArrayValuesCall Attempting to convert list<mixed> to a list using \array_values() (it is already a list) src/165_dont_warn_unknown.php:2 PhanUnreferencedFunction Possibly zero references to function \test165() src/165_dont_warn_unknown.php:4 PhanPluginUnknownObjectMethodCall Phan could not infer any class/interface types for the object of the method call $x->count() - inferred a type of (empty union type) src/166_printf_array.php:2 PhanPluginPrintfNoArguments No format string arguments are given for (unknown), consider using echo instead src/166_printf_array.php:2 PhanPluginPrintfVariableFormatString Code ['Test'] has a dynamic format string that could not be inferred by Phan src/166_printf_array.php:2 PhanTypeMismatchArgumentInternalReal Argument 1 ($format) is ['Test'] of type array{0:'Test'} but \printf() takes string src/166_printf_array.php:3 PhanPluginPrintfNoArguments No format string arguments are given for (unknown), consider using fwrite instead src/166_printf_array.php:3 PhanPluginPrintfVariableFormatString Code ['Test'] has a dynamic format string that could not be inferred by Phan src/166_printf_array.php:3 PhanTypeMismatchArgumentInternalReal Argument 2 ($format) is ['Test'] of type array{0:'Test'} but \fprintf() takes string src/166_printf_array.php:4 PhanPluginPrintfNoArguments No format string arguments are given for (unknown), consider using fwrite instead src/166_printf_array.php:4 PhanPluginPrintfVariableFormatString Code ['Test'] has a dynamic format string that could not be inferred by Phan src/166_printf_array.php:4 PhanTypeMismatchArgumentInternalReal Argument 2 ($format) is ['Test'] of type array{0:'Test'} but \vfprintf() takes string src/167_trait_crash.php:6 PhanRedefineFunction Function diff defined at src/167_trait_crash.php:6 was previously defined at src/167_trait_crash.php:9 src/167_trait_crash.php:6 PhanUnreferencedPublicMethod Possibly zero references to public method \TraitCrash\BaseTrait::diff() src/167_trait_crash.php:9 PhanRedefineFunction Function diff defined at src/167_trait_crash.php:9 was previously defined at src/167_trait_crash.php:6 src/167_trait_crash.php:9 PhanUnreferencedPublicMethod Possibly zero references to public method \TraitCrash\BaseTrait::diff,1() src/167_trait_crash.php:9 PhanUnusedPublicNoOverrideMethodParameter Parameter $date is never used src/167_trait_crash.php:14 PhanUnreferencedClass Possibly zero references to trait \TraitCrash\Other src/168_pure_new.php:12 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \f168() defined at src/168_pure_new.php:3 src/168_pure_new.php:14 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \h168() defined at src/168_pure_new.php:9 src/169_include_repr.php:5 PhanUnreferencedFunction Possibly zero references to function \test169() src/169_include_repr.php:7 PhanTypeMismatchArgumentInternalReal Argument 1 ($string) is [require((__DIR__ . '/000_plugins.php')),require_once((__DIR__ . '/000_plugins.php')),include((__DIR__ . '/000_plugins.php')),include_once((__DIR__ . '/000_plugins.php')),eval('echo "test";')] of type array{0:mixed,1:mixed,2:mixed,3:mixed,4:mixed} but \strlen() takes string src/169_include_repr.php:11 PhanPluginUnsafeEval eval() is often unsafe and may have better alternatives such as closures and is unanalyzable. Suppress this issue if you are confident that input is properly escaped for this use case and there is no better way to do this. src/169_include_repr.php:13 PhanTypeMismatchArgumentInternalReal Argument 1 ($num1) is "{$i}2{$j}" of type string but \intdiv() takes int src/170_stub_file.php:2 PhanTypeMismatchArgumentInternalReal Argument 1 ($x) is null of type null but \fakephanstub_function() takes int src/170_stub_file.php:5 PhanTypeMismatchArgumentInternalReal Argument 1 ($x) is null of type null but \FakePhanStub::__construct() takes string src/171_unreferenced_private.php:6 PhanUnreferencedPrivateMethod Possibly zero references to private method \NS171\Subclass::testStatic() src/171_unreferenced_private.php:9 PhanUnreferencedPrivateMethod Possibly zero references to private method \NS171\Subclass::testInstance() src/172_infer_pure_useless_loop.php:13 PhanSideEffectFreeForBody Saw a for loop which probably has no side effects src/172_infer_pure_useless_loop.php:19 PhanSideEffectFreeWhileBody Saw a while loop which probably has no side effects src/172_infer_pure_useless_loop.php:24 PhanSideEffectFreeDoWhileBody Saw a do-while loop which probably has no side effects src/172_infer_pure_useless_loop.php:33 PhanSideEffectFreeForeachBody Saw a foreach loop which probably has no side effects src/173_duplicate_catch.php:7 PhanPluginDuplicateCatchStatementBody The implementation of catch(RuntimeException) and catch(Error) are identical, and can be combined if the application only needs to supports php 7.1 and newer src/173_duplicate_catch.php:12 PhanPluginInconsistentReturnFunction Function \test_unserialize has no return type and will inconsistently return or not return src/173_duplicate_catch.php:16 PhanPluginDuplicateCatchStatementBody The implementation of catch(RuntimeException|InvalidArgumentException) and catch(ArgumentCountError) are identical, and can be combined if the application only needs to supports php 7.1 and newer src/173_duplicate_catch.php:18 PhanPluginDuplicateCatchStatementBody The implementation of catch(TypeError) and catch(Error) are identical, and can be combined if the application only needs to supports php 7.1 and newer src/174_duplicate_constants.php:3 PhanUnreferencedConstant Possibly zero references to global constant \S174 src/174_duplicate_constants.php:4 PhanUnreferencedConstant Possibly zero references to global constant \T174 src/174_duplicate_constants.php:5 PhanUnreferencedConstant Possibly zero references to global constant \U174 src/174_duplicate_constants.php:5 PhanUnreferencedConstant Possibly zero references to global constant \V174 src/174_duplicate_constants.php:6 PhanPluginDuplicateConstant Constant S174 was previously declared at line 3 - the previous declaration will be used instead src/174_duplicate_constants.php:7 PhanPluginDuplicateConstant Constant T174 was previously declared at line 4 - the previous declaration will be used instead src/174_duplicate_constants.php:8 PhanPluginDuplicateConstant Constant V174 was previously declared at line 5 - the previous declaration will be used instead src/175_self_reference_func.php:2 PhanUnreferencedFunction Possibly zero references to function \fib() src/175_self_reference_func.php:6 PhanUnreferencedPublicMethod Possibly zero references to public method \MyFib::fib() src/176_assign.php:2 PhanUnusedGlobalFunctionParameter Parameter $x is never used src/176_assign.php:3 PhanPluginNonBoolBranch Non bool value of type null evaluated in if clause src/177_switch.php:8 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(1) detected in switch statement - the later entry will be ignored in favor of case 1 at line 6. src/177_switch.php:10 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(true) detected in switch statement - the later entry will be ignored in favor of case true at line 4. src/177_switch.php:14 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case([]) detected in switch statement - the later entry will be ignored in favor of case [] at line 12. src/177_switch.php:20 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case(null) detected in switch statement - the later entry will be ignored in favor of case null at line 18. src/177_switch.php:23 PhanPluginDuplicateSwitchCase Duplicate/Equivalent switch case($y) detected in switch statement - the later entry will be ignored in favor of case $y at line 22. src/178_dependent_array_map.php:5 PhanTypeMismatchReturn Returning $result of type non-empty-array<int,string> but test178() is declared to return array<string,mixed> src/179_long_array_warning.php:2 PhanPluginShortArray Should use [] instead of array() src/179_long_array_warning.php:3 PhanPluginShortArrayList Should use [] instead of list() src/180_simplify_expression.php:3 PhanPluginSimplifyExpressionBool (($x === 'a') ? true : false) can probably be simplified to ($x === 'a') src/180_simplify_expression.php:6 PhanPluginSimplifyExpressionBool (($x > 0) ? false : true) can probably be simplified to !(($x > 0)) src/180_simplify_expression.php:9 PhanPluginSimplifyExpressionBool (($x > 0) ?: false) can probably be simplified to ($x > 0) src/180_simplify_expression.php:12 PhanPluginNonBoolInLogicalArith Non bool value of type in logical arithmetic src/180_simplify_expression.php:12 PhanPluginNonBoolInLogicalArith Non bool value of type int in logical arithmetic src/180_simplify_expression.php:12 PhanPluginNumericalComparison non numerical values compared by the operators '==' or '!=' src/180_simplify_expression.php:12 PhanPluginSimplifyExpressionBool (!$x xor false) can probably be simplified to !$x src/180_simplify_expression.php:12 PhanPluginSimplifyExpressionBool (empty($x) !== false) can probably be simplified to empty($x) src/180_simplify_expression.php:12 PhanPluginSimplifyExpressionBool (isset($x) == true) can probably be simplified to isset($x) src/181_provide_unused_param.php:2 PhanParamNameIndicatingUnused Saw a parameter named $unused. If this was used to indicate that a parameter is unused to Phan, consider using @unused-param after a param comment or suppressing unused parameter warnings instead. PHP 8.0 introduces support for named parameters, so changing names to suppress unused parameter warnings is no longer recommended. src/181_provide_unused_param.php:5 PhanProvidingUnusedParameter Providing an unused optional parameter $unused to \test181($unused = false) defined at src/181_provide_unused_param.php:2 src/181_provide_unused_param.php:7 PhanParamNameIndicatingUnusedInClosure Saw a parameter named $unusedParam2. If this was used to indicate that a parameter is unused to Phan, consider using @unused-param after a param comment or suppressing unused parameter warnings instead. PHP 8.0 introduces support for named parameters, so changing names to suppress unused parameter warnings is no longer recommended. src/181_provide_unused_param.php:7 PhanPluginPossiblyStaticClosure Closure($param1, $unusedParam2 = 'default') can be static src/181_provide_unused_param.php:9 PhanProvidingUnusedParameterOfClosure Providing an unused optional parameter $unusedParam2 to Closure($param1, $unusedParam2 = 'default') defined at src/181_provide_unused_param.php:7 src/181_provide_unused_param.php:9 PhanTypeMismatchArgument Argument 2 ($unusedParam2) is 2 of type 2 but Closure($param1, $unusedParam2 = 'default') takes string defined at src/181_provide_unused_param.php:7 src/181_provide_unused_param.php:11 PhanParamNameIndicatingUnused Saw a parameter named $unusedVar. If this was used to indicate that a parameter is unused to Phan, consider using @unused-param after a param comment or suppressing unused parameter warnings instead. PHP 8.0 introduces support for named parameters, so changing names to suppress unused parameter warnings is no longer recommended. src/181_provide_unused_param.php:14 PhanDeprecatedImplicitNullableParam Implicit nullable parameters (int $x = null) have been deprecated in PHP 8.4 src/181_provide_unused_param.php:14 PhanParamNameIndicatingUnused Saw a parameter named $_. If this was used to indicate that a parameter is unused to Phan, consider using @unused-param after a param comment or suppressing unused parameter warnings instead. PHP 8.0 introduces support for named parameters, so changing names to suppress unused parameter warnings is no longer recommended. src/181_provide_unused_param.php:14 PhanParamReqAfterOpt Required parameter (string $required) follows optional (?int $x = null) src/181_provide_unused_param.php:17 PhanParamNameIndicatingUnused Saw a parameter named $unusedParam. If this was used to indicate that a parameter is unused to Phan, consider using @unused-param after a param comment or suppressing unused parameter warnings instead. PHP 8.0 introduces support for named parameters, so changing names to suppress unused parameter warnings is no longer recommended. src/181_provide_unused_param.php:20 PhanUnreferencedClass Possibly zero references to class \Override181 src/181_provide_unused_param.php:25 PhanProvidingUnusedParameter Providing an unused optional parameter $unusedVar to \Example181::__construct(int $unusedVar = 0) defined at src/181_provide_unused_param.php:11 src/181_provide_unused_param.php:26 PhanProvidingUnusedParameter Providing an unused optional parameter $_ to \Example181::dump(?int $x = null, string $required, int $_ = 2) defined at src/181_provide_unused_param.php:14 src/182_provide_mandatory_param.php:10 PhanParamTooFewInPHPDoc Call with 0 arg(s) to \test182(bool $foo = false, string $bar = '') which has phpdoc indicating it requires 2 arg(s) ($bar is mandatory) defined at src/182_provide_mandatory_param.php:7 src/182_provide_mandatory_param.php:11 PhanParamTooFewInPHPDoc Call with 1 arg(s) to \test182(bool $foo = false, string $bar = '') which has phpdoc indicating it requires 2 arg(s) ($bar is mandatory) defined at src/182_provide_mandatory_param.php:7 src/182_provide_mandatory_param.php:20 PhanCommentParamOutOfOrder Expected @param annotation for $field to be before the @param annotation for $secondField src/182_provide_mandatory_param.php:28 PhanParamTooFewInPHPDoc Call with 0 arg(s) to \Other182::process(string $field = null, string $secondField = null) which has phpdoc indicating it requires 2 arg(s) ($secondField is mandatory) defined at src/182_provide_mandatory_param.php:23 src/183_encaps_list.php:3 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is "\t\v{$x}\r\n" of type string but \intdiv() takes int src/184_shell_exec.php:4 PhanPluginUnsafeShellExecDynamic This syntax for shell_exec() (`echo {$hello},`) is easily confused for a string and does not allow proper exit code/stderr handling, and is used with a non-constant. Consider proc_open() instead. src/184_shell_exec.php:4 PhanPluginUnsafeShellExec This syntax for shell_exec() (`echo "world"`) is easily confused for a string and does not allow proper exit code/stderr handling. Consider proc_open() instead. src/185_sizeof.php:3 PhanDeprecatedFunctionInternal Call to deprecated function \sizeof() (Deprecated because: DeprecateAliasPlugin marked this as an alias of count()) src/186_phpdoc_in_wrong_comment.php:2 PhanPluginPHPDocInWrongComment Saw possible phpdoc annotation in ordinary block comment "/*\n * @param string $value\n */". PHPDoc comments should start with "/**" (followed by whitespace), not "/*" src/187_unused_param.php:9 PhanUnusedGlobalFunctionParameter Parameter $fourth is never used src/187_unused_param.php:9 PhanUnusedGlobalFunctionParameter Parameter $second is never used src/188_param.php:27 PhanTypeMismatchArgumentProbablyReal Argument 3 ($partialMatch) is null of type null but \PHPDocParamTest\B::compareProperty() takes bool|false (no real type) defined at src/188_param.php:22 (the inferred real argument type has nothing in common with the parameter's phpdoc type) src/189_class_constant_badtype.php:5 PhanCommentObjectInClassConstantType Impossible phpdoc declaration that a class constant \C189::MY_CONST has a type \MY_CONST containing objects. This type is ignored during analysis. src/189_class_constant_badtype.php:5 PhanUndeclaredTypeClassConstant Class constant \C189::MY_CONST has undeclared class type \MY_CONST src/189_class_constant_badtype.php:9 PhanCommentObjectInClassConstantType Impossible phpdoc declaration that a class constant \C189::INVALID_ITERABLE_CONST has a type iterable<T> containing objects. This type is ignored during analysis. src/189_class_constant_badtype.php:9 PhanTemplateTypeConstant constant \C189::INVALID_ITERABLE_CONST may not have a template type src/189_class_constant_badtype.php:13 PhanCommentObjectInClassConstantType Impossible phpdoc declaration that a class constant \C189::INVALID_TRAVERSABLE_CONST has a type iterable<\Traversable> containing objects. This type is ignored during analysis. src/190_repeated_silence.php:2 PhanNoopRepeatedSilenceOperator Saw a repeated silence operator in @(@$y) src/191_hashes.php:4 PhanPluginPHPDocHashComment Saw comment starting with # in "#This is a comment" - consider using // instead to avoid confusion with php 8.0 #[ attributes src/191_hashes.php:8 PhanPluginPHPDocHashComment Saw comment starting with # in "#" - consider using // instead to avoid confusion with php 8.0 #[ attributes src/191_infinite_loops.php:4 PhanPossiblyInfiniteLoop The loop condition B191 does not seem to change within the loop and nothing seems to exit the loop src/191_infinite_loops.php:5 PhanPossiblyInfiniteLoop The loop condition !B191 does not seem to change within the loop and nothing seems to exit the loop src/192_loop.php:8 PhanPluginConstantVariableBool Variable $loop is probably constant with a value of false src/192_unused_param.php:5 PhanUnextractableAnnotation Saw unextractable annotation for comment '* @unused-param' src/192_unused_param.php:8 PhanPluginUseReturnValueNoopVoid The function/method \test_unused_192() is declared to return void and it has no side effects src/192_unused_param.php:8 PhanUnreferencedFunction Possibly zero references to function \test_unused_192() src/192_unused_param.php:8 PhanUnusedGlobalFunctionParameter Parameter $x is never used src/192_unused_param.php:8 PhanUnusedGlobalFunctionParameter Parameter $y is never used src/193_loop.php:2 PhanPluginUseReturnValueNoopVoid The function/method \test193() is declared to return void and it has no side effects src/193_loop.php:4 PhanNoopVariable Unused variable src/193_loop.php:4 PhanSideEffectFreeForBody Saw a for loop which probably has no side effects src/193_loop.php:4 PhanUndeclaredVariable Variable $placeholder is undeclared src/193_loop.php:4 PhanUnusedVariable Unused definition of variable $placeholder src/193_loop.php:8 PhanPluginUseReturnValueNoopVoid The function/method \test193b() is declared to return void and it has no side effects src/193_loop.php:10 PhanSideEffectFreeForBody Saw a for loop which probably has no side effects src/194_construct.php:7 PhanCompatibleTypedProperty Cannot use typed properties before php 7.4. This property group has type int src/194_construct.php:7 PhanWriteOnlyPublicProperty Possibly zero read references to public property \N194\SubOption->subSubOption src/194_construct.php:12 PhanCompatibleTypedProperty Cannot use typed properties before php 7.4. This property group has type \N194\SubOption src/194_construct.php:26 PhanCompatibleTypedProperty Cannot use typed properties before php 7.4. This property group has type \N194\Options src/194_construct.php:34 PhanUnreferencedClass Possibly zero references to class \N194\C src/195_generator.php:7 PhanPluginUseReturnValueGenerator Expected to use the return value of the function/method \test195() returning a generator of type \Generator<int> src/195_generator.php:12 PhanUnreferencedFunction Possibly zero references to function \testmethod195() src/195_generator.php:13 PhanPluginUseReturnValueGenerator Expected to use the return value of the function/method \Base195::test() returning a generator of type \Generator src/196_test_loop.php:2 PhanUnreferencedFunction Possibly zero references to function \test_loop1() src/196_test_loop.php:5 PhanUndeclaredVariable Variable $previousVal is undeclared src/196_test_loop.php:11 PhanUnreferencedFunction Possibly zero references to function \test_loop2() src/196_test_loop.php:14 PhanUndeclaredVariable Variable $previousVal is undeclared src/196_test_loop.php:16 PhanUnusedVariable Unused definition of variable $previousVal src/198_static_variable_suspicious.php:6 PhanStaticClassAccessWithStaticVariable Saw access to potentially inherited class element with static in a function that also uses static variables. The behavior of static variables will change to consistently use one set of static variables per method declaration in php 8.1 and the same method may end up write different values to static variables or do different things after reading static variables in different inherited classes. (This is a simple heuristic, suppress the issue if this is a false positive) src/198_static_variable_suspicious.php:14 PhanStaticClassAccessWithStaticVariable Saw access to potentially inherited class element with $this in a function that also uses static variables. The behavior of static variables will change to consistently use one set of static variables per method declaration in php 8.1 and the same method may end up write different values to static variables or do different things after reading static variables in different inherited classes. (This is a simple heuristic, suppress the issue if this is a false positive) src/199_never_type_and_plugins.php:3 PhanUnreferencedFunction Possibly zero references to function \exitMisuse() src/199_never_type_and_plugins.php:5 PhanPluginNonBoolInLogicalArith Non bool value of type never in logical arithmetic src/199_never_type_and_plugins.php:6 PhanPluginConstantVariableBool Variable $z is probably constant with a value of true src/199_never_type_and_plugins.php:6 PhanUnusedVariable Unused definition of variable $y src/199_never_type_and_plugins.php:7 PhanDebugAnnotation @phan-debug-var requested for variable $x1 - it has union type non-zero-int(real=non-zero-int) src/199_never_type_and_plugins.php:7 PhanDebugAnnotation @phan-debug-var requested for variable $y - it has union type true(real=true) src/199_never_type_and_plugins.php:7 PhanDebugAnnotation @phan-debug-var requested for variable $y3 - it has union type 0|int(real=0|int) src/199_never_type_and_plugins.php:7 PhanDebugAnnotation @phan-debug-var requested for variable $z2 - it has union type bool(real=bool) src/199_never_type_and_plugins.php:9 PhanTypeInvalidRightOperandOfAdd Invalid operator: right operand of + is never (expected array or number) src/199_never_type_and_plugins.php:9 PhanUseReturnValueOfNever Saw use of value of expression exit('fail') which likely uses the exit statement with a return type of 'never' - this will not return normally src/199_never_type_and_plugins.php:13 PhanCompatibleNeverType Return type 'never' means that a function will not return normally starting in PHP 8.1. In PHP 8.0, 'never' refers to a class/interface with the name 'never' src/199_never_type_and_plugins.php:13 PhanPluginAlwaysReturnFunction Function \up has a return type of never, but may fail to return a value src/199_never_type_and_plugins.php:13 PhanTypeMissingReturnReal Method \up is declared to return never in its real type signature but has no return value src/199_never_type_and_plugins.php:14 PhanUnusedVariable Unused definition of variable $x src/199_never_type_and_plugins.php:14 PhanUseReturnValueOfNever Saw use of value of expression exit($message) which likely uses the exit statement with a return type of 'never' - this will not return normally src/199_never_type_and_plugins.php:16 PhanUseReturnValueOfNever Saw use of value of expression up('goodbye') which likely uses the function \up(string $message) with a return type of 'never' - this will not return normally src/200_never_control_flow.php:13 PhanPluginUnreachableCode Unreachable statement detected src/200_never_control_flow.php:15 PhanTypeMismatchReturnReal Returning $x of type int but test200() is declared to return string src/202_never_return.php:7 PhanUnusedProtectedMethodParameter Parameter $x is never used src/204_redundant_assignment.php:3 PhanUnreferencedClass Possibly zero references to class \TestClass src/204_redundant_assignment.php:4 PhanUnreferencedPrivateMethod Possibly zero references to private method \TestClass::task() src/205_non_throwing_try_block.php:3 PhanPluginEmptyStatementPossiblyNonThrowingTryBody Found a try block that looks like it might not throw. Note that this check is a heuristic prone to false positives, especially because error handlers, signal handlers, destructors, and other things may all lead to throwing. src/205_non_throwing_try_block.php:9 PhanPluginEmptyStatementPossiblyNonThrowingTryBody Found a try block that looks like it might not throw. Note that this check is a heuristic prone to false positives, especially because error handlers, signal handlers, destructors, and other things may all lead to throwing. src/205_non_throwing_try_block.php:15 PhanPluginEmptyStatementPossiblyNonThrowingTryBody Found a try block that looks like it might not throw. Note that this check is a heuristic prone to false positives, especially because error handlers, signal handlers, destructors, and other things may all lead to throwing. src/206_write_op_unused.php:8 PhanWriteOnlyPrivateProperty Possibly zero read references to private property \X206::$prop3 src/207_invalid_offset.php:5 PhanTypeInvalidDimOffset Invalid offset true of $arr of array type array{string:'z',:'x',0:array{}} src/207_invalid_offset.php:5 PhanTypeMismatchArgumentReal Argument 1 ($x) is $arr[true] of type null but \expect_string() takes string defined at src/207_invalid_offset.php:4 src/207_invalid_offset.php:6 PhanTypeInvalidDimOffset Invalid offset 3.5 of $arr of array type array{string:'z',:'x',0:array{}} src/207_invalid_offset.php:6 PhanTypeMismatchArgumentReal Argument 1 ($x) is $arr[3.5] of type null but \expect_string() takes string defined at src/207_invalid_offset.php:4 src/207_invalid_offset.php:7 PhanPartialTypeMismatchArgument Argument 1 ($x) is $arr[STDIN] of type 'x'|'z'|array{} but \expect_string() takes string (array{} is incompatible) defined at src/207_invalid_offset.php:4 src/207_invalid_offset.php:7 PhanTypeMismatchDimFetch When fetching an array index from a value of type array{string:'z',:'x',0:array{}}, found an array index of type resource, but expected the index to be of type int|string src/207_invalid_offset.php:8 PhanPartialTypeMismatchArgument Argument 1 ($x) is $arr[[]] of type 'x'|'z'|array{} but \expect_string() takes string (array{} is incompatible) defined at src/207_invalid_offset.php:4 src/207_invalid_offset.php:8 PhanTypeMismatchDimFetch When fetching an array index from a value of type array{string:'z',:'x',0:array{}}, found an array index of type array{}, but expected the index to be of type int|string src/207_invalid_offset.php:10 PhanTypeMismatchArgumentReal Argument 1 ($x) is $arr[false] of type array{} but \expect_string() takes string defined at src/207_invalid_offset.php:4 src/207_invalid_offset.php:11 PhanTypeInvalidDimOffset Invalid offset true of $arr of array type array{string:'z',:'x',0:array{}} src/207_invalid_offset.php:11 PhanTypeMismatchArgumentReal Argument 1 ($x) is $arr[true] of type null but \expect_string() takes string defined at src/207_invalid_offset.php:4 src/208_redundant.php:2 PhanUnreferencedFunction Possibly zero references to function \check_assign_redundant() src/208_redundant.php:3 PhanPluginNonBoolBranch Non bool value of type 'a' evaluated in if clause src/208_redundant.php:3 PhanRedundantCondition Redundant attempt to cast $x[0] of type 'a' to truthy src/208_redundant.php:6 PhanImpossibleCondition Impossible attempt to cast $x[1] of type false to truthy src/208_redundant.php:6 PhanUnusedVariable Unused definition of variable $x src/209_return_explicit.php:3 PhanPluginInconsistentReturnFunction Function \f209 has no return type and will inconsistently return or not return src/209_return_explicit.php:8 PhanPluginInconsistentReturnFunction Function \g209 has no return type and will inconsistently return or not return src/209_return_explicit.php:9 PhanPluginEmptyStatementTryBody Empty statement list detected for the try statement's body src/209_return_explicit.php:14 PhanPluginUseReturnValueKnown Expected to use the return value of the user-defined function/method \f209() defined at src/209_return_explicit.php:3 src/210_duplicate_array_key.php:5 PhanUnreferencedFunction Possibly zero references to function \check_switch() src/210_duplicate_array_key.php:10 PhanPluginDuplicateSwitchCaseLooseEquality Switch case('0.5') is loosely equivalent (==) to an earlier case (0.5) in switch statement - the earlier entry may be chosen instead. src/210_duplicate_array_key.php:13 PhanPluginDuplicateSwitchCaseLooseEquality Switch case('0.50') is loosely equivalent (==) to an earlier case ('0.5') in switch statement - the earlier entry may be chosen instead. src/210_duplicate_array_key.php:22 PhanPluginDuplicateSwitchCaseLooseEquality Switch case('00') is loosely equivalent (==) to an earlier case (0) in switch statement - the earlier entry may be chosen instead. src/210_duplicate_array_key.php:28 PhanPluginDuplicateSwitchCaseLooseEquality Switch case('foo') is loosely equivalent (==) to an earlier case (0) in switch statement - the earlier entry may be chosen instead. Comparing the output: Files expected/all_output.expected and output all_output.actual are identical Running test suite: __FakeRealTypesTest Generating test cases Running phan in '/src/repo/phan-tests/real_types_test' ... src/001_array_key_exists.php:2 PhanImpossibleCondition Impossible attempt to cast true of type true to int src/001_array_key_exists.php:5 PhanImpossibleCondition Impossible attempt to cast true of type true to array src/001_array_key_exists.php:8 PhanImpossibleCondition Impossible attempt to cast [] of type array{} to object src/001_array_key_exists.php:13 PhanImpossibleCondition Impossible attempt to cast array_key_exists('foo', []) of type ?bool to array src/001_array_key_exists.php:13 PhanImpossibleTypeComparison Impossible attempt to check if 'foo' of type 'foo' is identical to keys of [] of type (no types in empty array) src/001_array_key_exists.php:16 PhanPluginUnknownFunctionParamType Function test1() has no declared or inferred parameter type for $x (Types inferred after analysis: array) src/001_array_key_exists.php:16 PhanPluginUnknownFunctionReturnType Function \test1() has no declared or inferred return type (Types inferred after analysis: array) src/001_array_key_exists.php:17 PhanImpossibleCondition Impossible attempt to cast key($x) of type int|null|string to array src/002_unknown_return_type.php:3 PhanPluginUnknownFunctionReturnType Function \test2() has no declared or inferred return type (Types inferred after analysis: list<\stdClass>) src/002_unknown_return_type.php:8 PhanPluginUnknownMethodReturnType Method \MyClass2::test() has no declared or inferred return type (Types inferred after analysis: list<array>) src/003_unknown_property_type.php:4 PhanPluginUnknownPropertyType Property \Test003::$prop has an initial type that cannot be inferred (Types inferred after analysis: bool) src/003_unknown_property_type.php:5 PhanPluginUnknownMethodParamType Method \Test003::f has no declared or inferred parameter type for $obj (Types inferred after analysis: ?string) src/003_unknown_property_type.php:15 PhanPluginUnknownClosureParamType Closure Closure($x) has no declared or inferred parameter type for $x (Types inferred after analysis: int) src/003_unknown_property_type.php:15 PhanPluginUnknownClosureReturnType Closure Closure($x) has no declared or inferred return type (Types inferred after analysis: float|int) src/003_unknown_property_type.php:19 PhanPluginUnknownFunctionParamType Function fetch_value() has no declared or inferred parameter type for $x (Types inferred after analysis: int) src/004_array_real_key.php:8 PhanDebugAnnotation @phan-debug-var requested for variable $values - it has union type int|list<mixed>(real=?int|?list<mixed>) src/004_array_real_key.php:10 PhanTypeMismatchArgumentInternalReal Argument 1 ($string) is $i of type int but \strlen() takes string src/004_array_real_key.php:15 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $i of type string but \intdiv() takes int src/004_array_real_key.php:19 PhanTypeMismatchArgumentReal Argument 1 ($s) is $i of type int but \accepts_string() takes string defined at src/004_array_real_key.php:3 src/004_array_real_key.php:23 PhanPluginUnknownArrayFunctionReturnType Function \create_array() has a return type of array, but does not specify key or value types src/004_array_real_key.php:23 PhanUnreferencedFunction Possibly zero references to function \create_array() src/004_array_real_key.php:27 PhanTypeMismatchArgumentInternal Argument 1 ($num1) is $i of type string but \intdiv() takes int src/004_array_real_key.php:28 PhanDebugAnnotation @phan-debug-var requested for variable $value - it has union type array{0:'value'}(real=array{0:'value'}) src/004_array_real_key.php:28 PhanTypeErrorInInternalCall Saw a call to an internal function strlen() with what would be invalid arguments in strict mode, when trying to infer the return value literal type: strlen(): Argument #1 ($string) must be of type string, array given src/004_array_real_key.php:28 PhanTypeMismatchArgumentInternalReal Argument 1 ($string) is $value of type array{0:'value'} but \strlen() takes string src/005_preg_match_impossible.php:3 PhanSuspiciousValueComparison Suspicious attempt to compare preg_match('/si/', $str) of type ?0|?1|?false to 1 of type 1 with operator '>' src/006_type_check_undeclared_function.php:6 PhanParamTooManyInternal Call with 1 arg(s) to \xdebug_get_stack_depth() which only takes 0 arg(s). This is an ArgumentCountError for internal functions in PHP 8.0+. src/006_type_check_undeclared_function.php:6 PhanTypeMismatchArgumentInternal Argument 1 ($object) is xdebug_get_stack_depth('stack') of type int but \spl_object_hash() takes object src/006_type_check_undeclared_function.php:6 PhanUndeclaredFunction Call to undeclared function \xdebug_get_stack_depth() src/006_type_check_undeclared_function.php:9 PhanParamTooManyInternal Call with 1 arg(s) to \xdebug_get_stack_depth() which only takes 0 arg(s). This is an ArgumentCountError for internal functions in PHP 8.0+. src/006_type_check_undeclared_function.php:9 PhanTypeMismatchArgumentInternal Argument 1 ($object) is xdebug_get_stack_depth('stack') of type int but \spl_object_hash() takes object src/006_type_check_undeclared_function.php:9 PhanUndeclaredFunction Call to undeclared function \xdebug_get_stack_depth() src/007_avoidable_getter.php:18 PhanPluginAvoidableGetter Can replace $this->getProp() with $this->prop src/007_avoidable_getter.php:24 PhanPluginAvoidableGetter Can replace $this->getProp() with $this->prop src/008_substr.php:2 PhanPluginUnknownFunctionParamType Function test188() has no declared or inferred parameter type for $x (Types inferred after analysis: array) src/008_substr.php:2 PhanPluginUnknownFunctionParamType Function test188() has no declared or inferred parameter type for $y (Types inferred after analysis: array) src/008_substr.php:2 PhanPluginUnknownFunctionReturnType Function \test188() has no declared or inferred return type (Types inferred after analysis: bool) src/008_substr.php:3 PhanImpossibleTypeComparison Impossible attempt to check if substr($x, $y) of type false|string is identical to null of type null src/008_substr.php:3 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $x of type array but \substr() takes string src/008_substr.php:3 PhanTypeMismatchArgumentInternal Argument 2 ($offset) is $y of type array but \substr() takes int src/009_impossible_cast.php:27 PhanDebugAnnotation @phan-debug-var requested for variable $a - it has union type false|string(real=?false|?string) src/009_impossible_cast.php:27 PhanDebugAnnotation @phan-debug-var requested for variable $b - it has union type int(real=int|string) src/009_impossible_cast.php:30 PhanPluginNumericalComparison numerical values compared by the operators '===' or '!==' src/010_possibly_undefined_property.php:11 PhanPossiblyUndeclaredProperty Reference to possibly undeclared property prop of expression of type \C10|false (false does not declare that property) src/010_possibly_undefined_property.php:12 PhanPossiblyUndeclaredPropertyOfClass Reference to possibly undeclared property prop of expression of type \ArrayObject|\C10 (instances of \ArrayObject do not declare that property) src/010_possibly_undefined_property.php:13 PhanPossiblyUndeclaredProperty Reference to possibly undeclared property prop of expression of type \C10|false (false does not declare that property) src/010_possibly_undefined_property.php:13 PhanTypeMismatchPropertyProbablyReal Assigning 0 of type 0 to property but \C10->prop is array (no real type) (the inferred real assigned type has nothing in common with the declared phpdoc property type) src/010_possibly_undefined_property.php:14 PhanPossiblyUndeclaredPropertyOfClass Reference to possibly undeclared property prop of expression of type \ArrayObject|\C10 (instances of \ArrayObject do not declare that property) Comparing the output: Files expected/all_output.expected and output all_output.actual are identical Running test suite: __FakeFallbackTest PHP_VERSION_ID=80220 Running phan in '/src/repo/phan-tests/misc/fallback_test' ... src/000_missing_semicolon_check.php:5 PhanSyntaxError syntax error, unexpected token "return" (at column 5) src/000_missing_semicolon_check.php:5 PhanTypeMismatchArgumentInternalReal Argument 1 ($string) is $x of type array{} but \strlen() takes string src/000_missing_semicolon_check.php:5 PhanTypeMismatchReturn Returning strlen($x) of type int but test_missing_semicolon() is declared to return string src/001_missing_variable_check.php:3 PhanTypeMismatchArgumentInternal Argument 1 ($string) is rand(0, 2) of type int but \strlen() takes string src/001_missing_variable_check.php:4 PhanSyntaxError syntax error, unexpected token ";" (at column 10) src/001_missing_variable_check.php:5 PhanTypeConversionFromArray array to string conversion src/001_missing_variable_check.php:5 PhanTypeMismatchArgumentInternalReal Argument 1 ($array) is $a of type int but \array_values() takes array src/002_missing_property_check.php:3 PhanUnusedGlobalFunctionParameter Parameter $a is never used src/002_missing_property_check.php:5 PhanSyntaxError syntax error, unexpected token ";", expecting identifier or variable or "{" or "$" (at column 17) src/002_missing_property_check.php:6 PhanTypeMismatchReturnReal Returning $prop of type array{0:'x'} but missing_property() is declared to return int src/003_misc_noise.php:4 PhanTypeConversionFromArray array to string conversion src/003_misc_noise.php:5 PhanSyntaxError syntax error, unexpected token "|" (at column 5) src/004_partial_arithmetic.php:4 PhanSyntaxError syntax error, unexpected token "}" (at column 1) src/004_partial_arithmetic.php:7 PhanTypeInvalidRightOperand Invalid operator: left operand is array and right is not src/005_new_ref.php:8 PhanSyntaxError syntax error, unexpected token "new" src/005_new_ref.php:9 PhanTypeMismatchReturn Returning $x->prop of type int but test5() is declared to return string src/006_crash.php:6 PhanNoopVariable Unused variable src/006_crash.php:6 PhanSyntaxError syntax error, unexpected token "," (at column 19) src/007_class_base_clause_2.php:3 PhanSyntaxError syntax error, unexpected token "{" (at column 17) src/008_declare_statement_12.php:3 PhanSyntaxError syntax error, unexpected token ")", expecting identifier (at column 10) src/009_declare_statement_7.php:3 PhanSyntaxError syntax error, unexpected token ")" (at column 23) src/010_functions8.php:2 PhanSyntaxError syntax error, unexpected token "{" (at column 29) src/010_functions8.php:2 PhanUnusedGlobalFunctionParameter Parameter $a is never used src/010_functions8.php:2 PhanUnusedGlobalFunctionParameter Parameter $b is never used src/011_isset_intrinsic_expression5.php:2 PhanNoopIsset Unused result of an isset(null) check src/011_isset_intrinsic_expression5.php:2 PhanSyntaxError syntax error, unexpected token "isset", expecting "(" (at column 7) src/012_namespace_use_declaration10.php:3 PhanNoopConstant Unused constant src/012_namespace_use_declaration10.php:3 PhanSyntaxError syntax error, unexpected token "as" (at column 6) src/012_namespace_use_declaration10.php:3 PhanUndeclaredConstant Reference to undeclared constant \c. This will cause a thrown Error in php 8.0+. src/013_traits12.php:3 PhanSyntaxError syntax error, unexpected token "insteadof", expecting "::" src/013_traits12.php:3 PhanUndeclaredAliasedMethodOfTrait Alias \A13::D was defined for a method \A13::C which does not exist in trait A13 src/014_try_statement10.php:5 PhanCompatibleNonCapturingCatch Catching exceptions without a variable is not supported before PHP 8.0 in catch () src/014_try_statement10.php:5 PhanSyntaxError syntax error, unexpected token ")" (at column 9) src/015_class_const_declaration9.php:3 PhanInvalidConstantExpression Constant expression contains invalid operations ((b = 'hello')) src/015_class_const_declaration9.php:3 PhanSyntaxError syntax error, unexpected token "=", expecting "," or ";" src/015_class_const_declaration9.php:3 PhanUnanalyzable Expression is unanalyzable or feature is unimplemented. Please create an issue at https://github.com/phan/phan/issues/new. src/015_class_const_declaration9.php:3 PhanUndeclaredConstant Reference to undeclared constant \b. This will cause a thrown Error in php 8.0+. src/015_class_const_declaration9.php:6 PhanUndeclaredConstantOfClass Reference to undeclared class constant \A15::b src/016_program_structure_30.php:7 PhanSyntaxError syntax error, unexpected end of file, expecting "elseif" or "else" or "endif" src/020_issue.php:2 PhanRedefineClass Class \anonymous_class_a5a5da87 defined at src/020_issue.php:2 was previously defined as Class \anonymous_class_a5a5da87 at src/020_issue.php:2 src/020_issue.php:2 PhanSyntaxError syntax error, unexpected token "{", expecting identifier (at column 7) src/021_binary_op.php:2 PhanSyntaxError syntax error, unexpected token ")" (at column 32) src/021_binary_op.php:2 PhanTypeConversionFromArray array to string conversion src/021_binary_op.php:2 PhanTypeMismatchArgumentInternalReal Argument 1 ($array) is 'example ' of type 'example ' but \array_values() takes array src/022_double_backslash.php:2 PhanNoopConstant Unused constant src/022_double_backslash.php:2 PhanSyntaxError syntax error, unexpected token "\" (at column 3) src/022_double_backslash.php:2 PhanUndeclaredConstant Reference to undeclared constant \A. This will cause a thrown Error in php 8.0+. src/022_double_backslash.php:2 PhanUndeclaredConstant Reference to undeclared constant \B. This will cause a thrown Error in php 8.0+. src/023_empty_name.php:3 PhanSyntaxError syntax error, unexpected token "\" src/024_crash.php:5 PhanInvalidConstantExpression Constant expression contains invalid operations ((function)) src/024_crash.php:5 PhanSyntaxError syntax error, unexpected variable "$notAFunction" (at column 22) src/025_invalid_const.php:3 PhanInvalidConstantExpression Constant expression contains invalid operations ((function)) src/025_invalid_const.php:4 PhanUndeclaredConstant Reference to undeclared constant \X25. This will cause a thrown Error in php 8.0+. src/025_invalid_const.php:8 PhanInvalidConstantExpression Constant expression contains invalid operations ((function)) src/026_invalid_assign.php:2 PhanInvalidNode Expected left side of assignment to be a variable src/026_invalid_assign.php:2 PhanSyntaxError syntax error, unexpected token "=" (at column 5) src/027_invalid_new.php:2 PhanInvalidFQSENInClasslike Possible use of a classlike '\invalid name' with an invalid FQSEN. src/027_invalid_new.php:2 PhanInvalidNode Invalid ClassName for new ClassName() src/027_invalid_new.php:2 PhanSyntaxError syntax error, unexpected single-quoted string "invalid name" src/028_array_missing_element.php:2 PhanSyntaxError Cannot use empty array elements in arrays src/029_crash_return_analysis.php:6 PhanSyntaxError Cannot use empty array elements in arrays src/029_crash_return_analysis.php:6 PhanTypeMismatchReturn Returning [,'value',[2]] of type array{0:'value',1:array{0:2}} but testarrayreturn() is declared to return int[] src/030_crash_extract_type.php:3 PhanSyntaxError Cannot use empty array elements in arrays src/031_not_magic_constant.php:3 PhanSyntaxError Unmatched ')' (at column 35) src/031_not_magic_constant.php:3 PhanTypeMismatchArgumentInternal Argument 2 ($return) is 50 of type 50 but \var_export() takes bool src/031_not_magic_constant.php:3 PhanUndeclaredConstant Reference to undeclared constant \parse_file__FILE__. This will cause a thrown Error in php 8.0+. src/032_declare_directive.php:2 PhanSyntaxError syntax error, unexpected token "class" src/032_declare_directive.php:5 PhanTypeMismatchArgumentInternalReal Argument 1 ($string) is new C89() of type \C89 but \strlen() takes string src/033_closure_crash.php:2 PhanParamTooFewCallable Call with 1 arg(s) to \intdiv(int $num1, int $num2) (as a provided callable) which requires 2 arg(s) defined at internal:0 src/033_closure_crash.php:2 PhanSyntaxError Cannot use empty array elements in arrays src/033_closure_crash.php:2 PhanTypeMismatchArgumentInternalReal Argument 1 ($num1) is new SimpleXMLElement('<a></a>') of type \Countable|\Iterator|\RecursiveIterator|\SimpleXMLElement|\Stringable|\Traversable|iterable but \intdiv() takes int src/033_closure_crash.php:2 PhanTypeMismatchArgumentInternal Argument 1 ($string) is call_user_func_array('intdiv', [,new SimpleXMLElement('<a></a>')]) of type int but \strlen() takes string src/034_function_return_self.php:3 PhanContextNotObjectUsingSelf Cannot use self as type when not in object context in \h34 src/035_bad_switch_statement.php:1 PhanNoopNumericLiteral Unused result of a numeric literal 5 near this line src/035_bad_switch_statement.php:3 PhanSyntaxError syntax error, unexpected token ")" (at column 9) src/036_namespace_name.php:3 PhanSyntaxError syntax error, unexpected token ";", expecting identifier or namespaced name (at column 21) src/037_assign_op.php:3 PhanSyntaxError syntax error, unexpected token "+=" (at column 11) src/037_assign_op.php:3 PhanUnusedVariable Unused definition of variable $y src/038_assign_op2.php:3 PhanSyntaxError syntax error, unexpected token "+=" src/038_assign_op2.php:3 PhanUnusedVariable Unused definition of variable $y src/039_invalid_call_target.php:2 PhanNonClassMethodCall Call to method callMethod on non-class type 'a_string_literal' src/039_invalid_call_target.php:2 PhanSyntaxError syntax error, unexpected token ";", expecting "]" (at column 39) src/040_invalid_string_escape.php:3 PhanSyntaxError syntax error, unexpected token ";" (at column 11) src/041_invalid_extend.php:3 PhanSyntaxError Unmatched '}' (at column 46) src/042_invalid_namespace_use.php:3 PhanSyntaxError syntax error, unexpected token ",", expecting "{" (at column 21) src/043_unexpected_static.php:2 PhanContextNotObject Cannot access static when not in object context src/043_unexpected_static.php:2 PhanSyntaxError syntax error, unexpected token ";", expecting "::" (at column 12) src/043_unexpected_static.php:2 PhanUndeclaredConstant Reference to undeclared constant \static. This will cause a thrown Error in php 8.0+. (Did you mean \T_STATIC) src/044_keys_in_lists.php:2 PhanSyntaxError syntax error, unexpected single-quoted string "kMissing" (at column 13) src/044_keys_in_lists.php:2 PhanUndeclaredGlobalVariable Global variable $v1 is undeclared src/045_invalid_assign_in_condition.php:3 PhanInvalidNode Expected left side of assignment to be a variable src/045_invalid_assign_in_condition.php:3 PhanSyntaxError syntax error, unexpected token "=" (at column 8) src/046_invalid_extract.php:6 PhanTypeMismatchArgumentInternalReal Argument 2 ($flags) is $e of type 'E' but \extract() takes int src/046_invalid_extract.php:7 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $x of type array{} but \strlen() takes string src/046_invalid_extract.php:8 PhanTypeMismatchArgumentInternal Argument 1 ($string) is $y of type array{} but \strlen() takes string src/047_invalid_define.php:3 PhanNoopConstant Unused constant src/047_invalid_define.php:3 PhanNoopStringLiteral Unused result of a string literal ");\nconst CON2 = " near this line src/047_invalid_define.php:3 PhanParamTooFewInternal Call with 1 arg(s) to \define(string $constant_name, $value, bool $case_insensitive = false) which requires 2 arg(s) src/047_invalid_define.php:3 PhanSyntaxError syntax error, unexpected identifier "a", expecting ")" (at column 12) src/047_invalid_define.php:3 PhanUndeclaredConstant Reference to undeclared constant \a. This will cause a thrown Error in php 8.0+. src/047_valid_define.php:2 PhanInvalidConstantFQSEN ',,' is an invalid FQSEN for a constant src/047_valid_define.php:3 PhanInvalidConstantFQSEN '&&' is an invalid FQSEN for a constant src/048_invalid_class.php:3 PhanUndeclaredClassMethod Call to method __construct from undeclared class \A48 src/048_invalid_class.php:4 PhanSyntaxError syntax error, unexpected integer "0" src/049_invalid_binary_condition.php:2 PhanInvalidNode Expected left side of assignment to be a variable src/049_invalid_binary_condition.php:2 PhanSyntaxError syntax error, unexpected token "=" (at column 8) src/049_invalid_binary_condition.php:3 PhanTypeConversionFromArray array to string conversion src/050_instanceof.php:3 PhanSyntaxError syntax error, unexpected integer "0" src/051_invalid_function_node.php:2 PhanCompatibleDimAlternativeSyntax Array and string offset access syntax with curly braces is deprecated in PHP 7.4. Use square brackets instead. Seen for stdClass{} src/051_invalid_function_node.php:2 PhanNoopArrayAccess Unused array offset fetch src/051_invalid_function_node.php:2 PhanSyntaxError syntax error, unexpected token "(" (at column 10) src/051_invalid_function_node.php:2 PhanTypeInvalidCallable Saw type 0 which cannot be a callable src/051_invalid_function_node.php:2 PhanUndeclaredConstant Reference to undeclared constant \stdClass. This will cause a thrown Error in php 8.0+. (Did you mean \T_CLASS) src/051_invalid_function_node.php:3 PhanNoopStringLiteral Unused result of a string literal "notanint" near this line src/052_invalid_assign_ref.php:3 PhanInvalidNode Expected left side of assignment to be a variable src/052_invalid_assign_ref.php:3 PhanSyntaxError syntax error, unexpected token "=", expecting ")" (at column 18) src/052_invalid_assign_ref.php:4 PhanInvalidNode Expected left side of assignment to be a variable src/053_empty_fqsen.php:3 PhanEmptyFQSENInClasslike Possible use of a classlike '\' with an empty FQSEN. src/055_trait_use.php:11 PhanInvalidTraitUse Invalid trait use: Expected original method name of a trait use to be a string src/055_trait_use.php:11 PhanSyntaxError syntax error, unexpected token "$" (at column 19) src/056_trait_use.php:11 PhanInvalidTraitUse Invalid trait use: Expected the insteadof method's name to be a string src/056_trait_use.php:11 PhanSyntaxError syntax error, unexpected token "$" (at column 19) src/057_invalid_prop.php:8 PhanUndeclaredStaticProperty Static property '0' on \C57 is undeclared src/058_var_name_not_found.php:5 PhanUndeclaredGlobalVariable Global variable $ is undeclared src/059_backtick_crash.php:3 PhanSyntaxError syntax error, unexpected token "`" (at column 7) src/060_empty_string.php:8 PhanSyntaxError syntax error, unexpected string content "unmatched" (at column 6) src/061_cast_crash.php:7 PhanParamTooFewCallable Call with 0 arg(s) to Closure($x) (as a provided callable) which requires 1 arg(s) defined at src/061_cast_crash.php:9 src/061_cast_crash.php:12 PhanSyntaxError syntax error, unexpected token ")", expecting "(" (at column 13) src/061_cast_crash.php:12 PhanTypeMismatchArgumentReal Argument 1 ($x) is (array)($x) of type array but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/061_cast_crash.php:18 PhanTypeMismatchArgument Argument 1 ($x) is (bool)($x) of type bool but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/061_cast_crash.php:21 PhanTypeMismatchArgument Argument 1 ($x) is (bool)($x) of type bool but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/061_cast_crash.php:24 PhanTypeMismatchArgument Argument 1 ($x) is (float)($x) of type float but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/061_cast_crash.php:27 PhanTypeMismatchArgument Argument 1 ($x) is (int)($x) of type int but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/061_cast_crash.php:30 PhanTypeMismatchArgument Argument 1 ($x) is (int)($x) of type int but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/061_cast_crash.php:33 PhanTypeMismatchArgument Argument 1 ($x) is (float)($x) of type float but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/061_cast_crash.php:36 PhanTypeMismatchArgumentReal Argument 1 ($x) is (object)($x) of type object but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/061_cast_crash.php:45 PhanCompatibleUnsetCast The unset cast (in (unset)($x)) was deprecated in PHP 7.2 and is a fatal error in PHP 8.0+. src/061_cast_crash.php:45 PhanTypeMismatchArgumentReal Argument 1 ($x) is (unset)($x) of type null but \accepts_cast_argument() takes string defined at src/061_cast_crash.php:3 src/062_test.php:2 PhanCompatibleDimAlternativeSyntax Array and string offset access syntax with curly braces is deprecated in PHP 7.4. Use square brackets instead. Seen for 'if'{} src/062_test.php:2 PhanNoopArrayAccess Unused array offset fetch src/062_test.php:3 PhanSyntaxError syntax error, unexpected token "}" (at column 1) src/063_invalid_fqsen.php:2 PhanEmptyFQSENInCallable Possible call to a function '' with an empty FQSEN. src/063_invalid_fqsen.php:3 PhanEmptyFQSENInCallable Possible call to a function '\' with an empty FQSEN. src/063_invalid_fqsen.php:4 PhanEmptyFQSENInCallable Possible call to a function '\' with an empty FQSEN. src/063_invalid_fqsen.php:5 PhanEmptyFQSENInCallable Possible call to a function '\' with an empty FQSEN. src/063_invalid_fqsen.php:6 PhanEmptyFQSENInClasslike Possible use of a classlike '\' with an empty FQSEN. src/063_invalid_fqsen.php:7 PhanInvalidFQSENInClasslike Possible use of a classlike '\??' with an invalid FQSEN. src/063_invalid_fqsen.php:8 PhanInvalidFQSENInClasslike Possible use of a classlike '\,,' with an invalid FQSEN. src/063_invalid_fqsen.php:9 PhanEmptyFQSENInClasslike Possible use of a classlike '\' with an empty FQSEN. src/063_invalid_fqsen.php:10 PhanEmptyFQSENInClasslike Possible use of a classlike '\' with an empty FQSEN. src/063_invalid_fqsen.php:11 PhanInvalidFQSENInClasslike Possible use of a classlike '\a\\b' with an invalid FQSEN. src/063_invalid_fqsen.php:12 PhanInvalidFQSENInClasslike Possible use of a classlike '\a\\' with an invalid FQSEN. src/063_invalid_fqsen.php:13 PhanNonClassMethodCall Call to method foo on non-class type 1 src/063_invalid_fqsen.php:14 PhanNonClassMethodCall Call to method foo on non-class type 0 src/063_invalid_fqsen.php:15 PhanInvalidFQSENInCallable Possible call to a function 'aaa\\b' with an invalid FQSEN. src/063_invalid_fqsen.php:16 PhanEmptyFQSENInCallable Possible call to a function 'aaa\' with an empty FQSEN. src/064_invalid_constant_expression.php:2 PhanInvalidConstantExpression Constant expression contains invalid operations ((function)) src/066_dim_alternative_syntax.php:3 PhanCompatibleDimAlternativeSyntax Array and string offset access syntax with curly braces is deprecated in PHP 7.4. Use square brackets instead. Seen for $y{'dim'} src/066_dim_alternative_syntax.php:4 PhanCompatibleDimAlternativeSyntax Array and string offset access syntax with curly braces is deprecated in PHP 7.4. Use square brackets instead. Seen for $x{0} src/066_dim_alternative_syntax.php:9 PhanSyntaxError syntax error, unexpected token "<", expecting end of file (at column 1) src/067_ambiguous_ternary.php:6 PhanCompatibleUnparenthesizedTernary Unparenthesized 'a ? b : c ? d : e' is deprecated. Use either '(a ? b : c) ? d : e' or 'a ? b : (c ? d : e)' src/067_ambiguous_ternary.php:7 PhanCompatibleUnparenthesizedTernary Unparenthesized 'a ? b : c ? d : e' is deprecated. Use either '(a ? b : c) ? d : e' or 'a ? b : (c ? d : e)' src/067_ambiguous_ternary.php:8 PhanCompatibleUnparenthesizedTernary Unparenthesized 'a ? b : c ?: d' is deprecated. Use either '(a ? b : c) ?: d' or 'a ? b : (c ?: d)' src/067_ambiguous_ternary.php:9 PhanCompatibleUnparenthesizedTernary Unparenthesized 'a ? b : c ?: d' is deprecated. Use either '(a ? b : c) ?: d' or 'a ? b : (c ?: d)' src/067_ambiguous_ternary.php:10 PhanCompatibleUnparenthesizedTernary Unparenthesized 'a ?: b ? c : d' is deprecated. Use either '(a ?: b) ? c : d' or 'a ?: (b ? c : d)' src/067_ambiguous_ternary.php:10 PhanUndeclaredVariable Variable $undefined is undeclared src/067_ambiguous_ternary.php:11 PhanCompatibleUnparenthesizedTernary Unparenthesized 'a ?: b ? c : d' is deprecated. Use either '(a ?: b) ? c : d' or 'a ?: (b ? c : d)' src/067_ambiguous_ternary.php:20 PhanUndeclaredVariable Variable $undefined is undeclared src/067_ambiguous_ternary.php:24 PhanSyntaxError syntax error, unexpected token "<", expecting end of file (at column 1) src/068_binary_literal.php:3 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 10 of type 10 but \spl_object_hash() takes object src/068_binary_literal.php:4 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 31 of type 31 but \spl_object_hash() takes object src/068_binary_literal.php:5 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 2.9514790517935283E+20 of type 2.9514790517935283E+20 but \spl_object_hash() takes object src/068_binary_literal.php:6 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 1.9676527011956854E+20 of type 1.9676527011956854E+20 but \spl_object_hash() takes object src/068_binary_literal.php:7 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 2.906089001023216E+32 of type 2.906089001023216E+32 but \spl_object_hash() takes object src/068_binary_literal.php:8 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 1.0 of type 1.0 but \spl_object_hash() takes object src/068_binary_literal.php:9 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 10.0 of type 10.0 but \spl_object_hash() takes object src/068_binary_literal.php:10 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 300.0 of type 300.0 but \spl_object_hash() takes object src/068_binary_literal.php:11 PhanTypeMismatchArgumentInternalReal Argument 1 ($object) is 300.0 of type 300.0 but \spl_object_hash() takes object src/068_binary_literal.php:13 PhanSyntaxError Unclosed '{' on line 12 src/069_invalid_coalesce_assign.php:2 PhanInvalidNode Invalid left hand side for ??= src/069_invalid_coalesce_assign.php:2 PhanSyntaxError syntax error, unexpected token "??=" src/070_nullable_param.php:2 PhanSyntaxError syntax error, unexpected variable "$x" (at column 19) src/071_isset.php:4 PhanSyntaxError syntax error, unexpected token "?", expecting "(" (at column 18) src/072_assign.php:1 PhanNoopNumericLiteral Unused result of a numeric literal 2 near this line src/072_assign.php:2 PhanSyntaxError syntax error, unexpected token "=", expecting variable or "{" or "$" (at column 3) src/073_trailing_commas.php:4 PhanCompatibleTrailingCommaArgumentList Cannot use trailing commas in argument lists before php 7.3 in ([2]). NOTE: THIS ISSUE CAN ONLY DETECTED BY THE POLYFILL. src/073_trailing_commas.php:8 PhanCompatibleTrailingCommaParameterList Cannot use trailing commas in parameter or closure use lists before php 8.0 in declaration of (function). NOTE: THIS ISSUE CAN ONLY DETECTED BY THE POLYFILL. src/073_trailing_commas.php:10 PhanCompatibleTrailingCommaParameterList Cannot use trailing commas in parameter or closure use lists before php 8.0 in declaration of (function). NOTE: THIS ISSUE CAN ONLY DETECTED BY THE POLYFILL. src/073_trailing_commas.php:15 PhanCompatibleTrailingCommaArgumentList Cannot use trailing commas in argument lists before php 7.3 in ($param1, $param2, $x). NOTE: THIS ISSUE CAN ONLY DETECTED BY THE POLYFILL. src/074_attributes.php:2 PhanSyntaxError syntax error, unexpected token "#[", expecting identifier (at column 7) src/074_invalid_closure_use.php:3 PhanCompatibleDimAlternativeSyntax Array and string offset access syntax with curly braces is deprecated in PHP 7.4. Use square brackets instead. Seen for ${0}{} src/074_invalid_closure_use.php:3 PhanNoopArrayAccess Unused array offset fetch src/074_invalid_closure_use.php:3 PhanSyntaxError syntax error, unexpected token "$", expecting "(" (at column 27) src/075_attributes.php:3 PhanSyntaxError syntax error, unexpected token "]" (at column 7) src/075_attributes.php:3 PhanUnusedPublicNoOverrideMethodParameter Parameter $ is never used src/075_invalid_name.php:2 PhanInvalidFQSENInClasslike Possible use of a classlike '\??' with an invalid FQSEN. src/076_pipe.php:3 PhanNoopConstant Unused constant src/076_pipe.php:3 PhanNoopVariable Unused variable src/076_pipe.php:3 PhanSyntaxError syntax error, unexpected token "|", expecting variable (at column 12) src/076_pipe.php:3 PhanUndeclaredConstant Reference to undeclared constant \string. This will cause a thrown Error in php 8.0+. (Did you mean \STDIN or \T_STRING) src/077_invalid_attribute.php:3 PhanSyntaxError syntax error, unexpected identifier "missing_method" (at column 1) src/077_invalid_attribute.php:3 PhanUndeclaredFunction Call to undeclared function \missing_method() src/078_octal.php:2 PhanUnusedGlobalFunctionParameter Parameter $x is never used src/078_octal.php:3 PhanTypeMismatchArgument Argument 1 ($x) is 15 of type 15 but \expect_string() takes string defined at src/078_octal.php:2 src/078_octal.php:4 PhanSyntaxError syntax error, unexpected end of file src/079_dnf.php:2 PhanCompatibleUnionType Cannot use union types (string|Countable) before php 8.0 src/079_dnf.php:2 PhanSyntaxError syntax error, unexpected token ")" src/079_dnf.php:2 PhanUnusedGlobalFunctionParameter Parameter $x is never used src/079_dnf.php:4 PhanTypeMismatchArgumentReal Argument 1 ($x) is null of type null but \foo79() takes \Countable|string defined at src/079_dnf.php:2 Comparing the output: Files expected/all_output.expected and output all_output.actual are identical Running test suite: __FakeConfigOverrideTest Running phan in '/src/repo/phan-tests/misc/config_override_test' ... src/000_ignore_undeclared_global_variables.php:16: [W999] PhanPluginNonBoolBranch: Non bool value of type string evaluated in if clause src/000_ignore_undeclared_global_variables.php:19: [W10004] PhanTypeMismatchArgumentInternal: Argument 1 ($num1) is $myVar->b of type string but \intdiv() takes int src/000_ignore_undeclared_global_variables.php:21: [W999] PhanPluginNonBoolBranch: Non bool value of type string evaluated in if clause Comparing the output: Files expected/all_output.expected and output all_output.actual are identical Running test suite: __FakeInferMissingTypesTest Generating test cases Running phan in '/src/repo/phan-tests/infer_missing_types_test' ... src/001_vaguer_comment_return.php:10 PhanPluginMoreSpecificActualReturnTypeContainsFQSEN Phan inferred that \NS1\test1() documented to have return type mixed (without an FQSEN) returns the more specific type \ArrayObject(real=\ArrayObject) (with an FQSEN) src/001_vaguer_comment_return.php:10 PhanUnreferencedFunction Possibly zero references to function \NS1\test1() src/001_vaguer_comment_return.php:13 PhanPluginMoreSpecificActualReturnTypeContainsFQSEN Phan inferred that \NS1\test2() documented to have return type object (without an FQSEN) returns the more specific type \ArrayObject(real=\ArrayObject) (with an FQSEN) src/001_vaguer_comment_return.php:13 PhanUnreferencedFunction Possibly zero references to function \NS1\test2() src/001_vaguer_comment_return.php:20 PhanPluginMoreSpecificActualReturnType Phan inferred that \NS1\test3() documented to have return type \ArrayAccess returns the more specific type \ArrayObject(real=\ArrayObject) src/001_vaguer_comment_return.php:20 PhanUnreferencedFunction Possibly zero references to function \NS1\test3() src/001_vaguer_comment_return.php:29 PhanPluginMoreSpecificActualReturnType Phan inferred that \NS1\test4() documented to have return type mixed returns the more specific type object src/001_vaguer_comment_return.php:29 PhanUnreferencedFunction Possibly zero references to function \NS1\test4() src/001_vaguer_comment_return.php:34 PhanUnreferencedClass Possibly zero references to class \NS1\Methods src/001_vaguer_comment_return.php:40 PhanPluginMoreSpecificActualReturnTypeContainsFQSEN Phan inferred that \NS1\Methods::test5() documented to have return type array (without an FQSEN) returns the more specific type array<int,\stdClass>(real=array<int,\stdClass>) (with an FQSEN) src/001_vaguer_comment_return.php:40 PhanPluginUnknownArrayMethodReturnType Method \NS1\Methods::test5() has a return type of array, but does not specify any key types or value types src/001_vaguer_comment_return.php:40 PhanUnreferencedPublicMethod Possibly zero references to public method \NS1\Methods::test5() src/001_vaguer_comment_return.php:48 PhanPluginMoreSpecificActualReturnTypeContainsFQSEN Phan inferred that \NS1\Methods::test6() documented to have return type object[] (without an FQSEN) returns the more specific type array<int,\stdClass>(real=array<int,\stdClass>) (with an FQSEN) src/001_vaguer_comment_return.php:48 PhanUnreferencedPublicMethod Possibly zero references to public method \NS1\Methods::test6() src/001_vaguer_comment_return.php:55 PhanPluginMoreSpecificActualReturnTypeContainsFQSEN Phan inferred that \NS1\Methods::test7() documented to have return type iterable<object> (without an FQSEN) returns the more specific type array<int,\NS1\Methods>(real=array<int,\NS1\Methods>) (with an FQSEN) src/001_vaguer_comment_return.php:55 PhanUnreferencedPublicMethod Possibly zero references to public method \NS1\Methods::test7() src/002_analyze_twice.php:3 PhanUnreferencedClass Possibly zero references to class \A2 src/002_analyze_twice.php:4 PhanPluginUnknownPropertyType Property \A2->x has an initial type that cannot be inferred src/002_analyze_twice.php:6 PhanPluginUnknownMethodParamType Method \A2::setX has no declared or inferred parameter type for $obj src/002_analyze_twice.php:6 PhanPluginUnknownMethodReturnType Method \A2::setX() has no declared or inferred return type src/002_analyze_twice.php:6 PhanUnreferencedPublicMethod Possibly zero references to public method \A2::setX() src/002_analyze_twice.php:10 PhanPluginUnknownMethodReturnType Method \A2::test() has no declared or inferred return type src/002_analyze_twice.php:10 PhanUnreferencedPublicMethod Possibly zero references to public method \A2::test() src/002_analyze_twice.php:15 PhanPluginUnknownObjectMethodCall Phan could not infer any class/interface types for the object of the method call $this->x->missingMethod() - inferred a type of (empty union type) src/002_analyze_twice.php:18 PhanPluginUnknownMethodReturnType Method \A2::register() has no declared or inferred return type src/002_analyze_twice.php:18 PhanUndeclaredTypeParameter Parameter $a has undeclared type \A (Did you mean class \A2 or array or interface \ArrayAccess) src/002_analyze_twice.php:18 PhanUnreferencedPublicMethod Possibly zero references to public method \A2::register() src/002_analyze_twice.php:19 PhanUndeclaredClassMethod Call to method setX from undeclared class \A (Did you mean class \A2 or interface \ArrayAccess) src/003_inherit_property.php:10 PhanUnreferencedClass Possibly zero references to class \NS3\Z src/003_inherit_property.php:11 PhanPluginUnknownMethodReturnType Method \NS3\Z::test() has no declared or inferred return type src/003_inherit_property.php:11 PhanUnreferencedPublicMethod Possibly zero references to public method \NS3\Z::test() src/003_inherit_property.php:14 PhanUndeclaredMethod Call to undeclared method \ArrayObject::missingMethod src/003_inherit_property.php:18 PhanPluginUnknownPropertyType Property \NS3\X->val has an initial type that cannot be inferred (Types inferred after analysis: \ArrayObject) src/004_infer_return_type.php:6 PhanPluginMoreSpecificActualReturnTypeContainsFQSEN Phan inferred that \returns_object4() documented to have return type object (without an FQSEN) returns the more specific type \stdClass(real=\stdClass) (with an FQSEN) src/004_infer_return_type.php:9 PhanUndeclaredMethod Call to undeclared method \stdClass::missingMethod src/005_more_specific.php:3 PhanReadOnlyPublicProperty Possibly zero write references to public property \TestSpecific->m Comparing the output: Files expected/all_output.expected and output all_output.actual are identical Running test suite: __FakeOverrideReturnTypesTest Generating test cases Running phan in '/src/repo/phan-tests/override_return_types_test' ... src/001_override_return_types.php:24 PhanTypeMismatchReturnProbablyReal Returning new Cat() of type \Cat but getAnimal2() is declared to return \Vegetable (no real type) (the inferred real return type has nothing in common with the declared phpdoc return type) src/001_override_return_types.php:29 PhanTypeMismatchArgumentReal Argument 1 ($v) is $this->getAnimal() of type \Animal|\Cat|\Dog but \OverrideReturnTypesTest::plant() takes \Vegetable defined at src/001_override_return_types.php:33 src/001_override_return_types.php:30 PhanPartialTypeMismatchArgument Argument 1 ($v) is $this->getAnimal2() of type \Cat|\Vegetable but \OverrideReturnTypesTest::plant() takes \Vegetable (\Animal|\Cat is incompatible) defined at src/001_override_return_types.php:33 Comparing the output: Files expected/all_output.expected and output all_output.actual are identical Running test suite: __FakeEmptyMethodsPluginTest Running phan in '/src/repo/phan-tests/misc/empty_methods_plugin_test' ... src/0000_empty_methods_functions.php:6 PhanEmptyPublicMethod Empty public method \ClassWithEmptyMethods756::two() src/0000_empty_methods_functions.php:8 PhanEmptyProtectedMethod Empty protected method \ClassWithEmptyMethods756::three() src/0000_empty_methods_functions.php:10 PhanEmptyPrivateMethod Empty private method \ClassWithEmptyMethods756::four() src/0000_empty_methods_functions.php:20 PhanEmptyFunction Empty function \emptyFunction756() src/0000_empty_methods_functions.php:25 PhanEmptyClosure Empty closure Closure() Comparing the output: Files expected/all_output.expected and output all_output.actual are identical All tests and checks passed! Generating autoload files Generated autoload files --- end --- build: Updating mediawiki/mediawiki-codesniffer to 45.0.0 $ git add . --- stdout --- --- end --- $ git commit -F /tmp/tmp1wrcohy6 --- stdout --- [master 10ad0d2] build: Updating mediawiki/mediawiki-codesniffer to 45.0.0 1 file changed, 1 insertion(+), 1 deletion(-) --- end --- $ git format-patch HEAD~1 --stdout --- stdout --- From 10ad0d23c18038ca612869567af1627578a08eb8 Mon Sep 17 00:00:00 2001 From: libraryupgrader <tools.libraryupgrader@tools.wmflabs.org> Date: Sat, 2 Nov 2024 06:12:12 +0000 Subject: [PATCH] build: Updating mediawiki/mediawiki-codesniffer to 45.0.0 Change-Id: I9552ab159970c5da16d65b762eba77cc67dabd06 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 036773b..9e75e90 100644 --- a/composer.json +++ b/composer.json @@ -38,7 +38,7 @@ }, "require-dev": { "ext-pdo": "*", - "mediawiki/mediawiki-codesniffer": "44.0.0", + "mediawiki/mediawiki-codesniffer": "45.0.0", "mediawiki/minus-x": "1.1.3", "php-parallel-lint/php-console-highlighter": "1.0.0", "php-parallel-lint/php-parallel-lint": "1.4.0", -- 2.39.2 --- end ---