Skip to content

Improve StrSplit returnType #21477

Improve StrSplit returnType

Improve StrSplit returnType #21477

Triggered via pull request June 12, 2025 23:05
Status Failure
Total duration 3m 51s
Artifacts

static-analysis.yml

on: pull_request
Generate baseline
1m 36s
Generate baseline
Generate PHP baseline
1m 44s
Generate PHP baseline
Matrix: PHPStan with result cache
Matrix: PHPStan
Fit to window
Zoom out
Zoom in

Annotations

203 errors
PHPStan (8.4, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.4, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.4, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan (8.4, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.4, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (8.4, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path /home/runner/work/phpstan-src/phpstan-src/src/Type/Php/StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
Generate baseline
Process completed with exit code 1.
PHPStan with result cache (8.2): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan with result cache (8.2): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan with result cache (8.2): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan with result cache (8.2): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan with result cache (8.2): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path /home/runner/work/phpstan-src/phpstan-src/src/Type/Php/StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
PHPStan with result cache (8.4): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan with result cache (8.4): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan with result cache (8.4): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan with result cache (8.4): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan with result cache (8.4): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path /home/runner/work/phpstan-src/phpstan-src/src/Type/Php/StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
PHPStan with result cache (8.1): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan with result cache (8.1): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan with result cache (8.1): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (8.2, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.2, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.2, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan (8.2, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.2, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (8.2, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path /home/runner/work/phpstan-src/phpstan-src/src/Type/Php/StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
PHPStan (8.1, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.1, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.1, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.1, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan with result cache (8.3): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan with result cache (8.3): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan with result cache (8.3): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan with result cache (8.3): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan with result cache (8.3): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path /home/runner/work/phpstan-src/phpstan-src/src/Type/Php/StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
PHPStan (8.3, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.3, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.3, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan (8.3, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.3, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (8.3, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path /home/runner/work/phpstan-src/phpstan-src/src/Type/Php/StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
Generate PHP baseline
Process completed with exit code 2.
Generate PHP baseline: src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Warning\: Undefined variable \$encoding$# in path /home/runner/work/phpstan-src/phpstan-src/src/Type/Php/StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
PHPStan (8.0, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.0, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.0, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.0, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (7.4, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Parameter #2 $split_length of function str_split expects int<1, max>, int given.
PHPStan (7.3, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L109
Parameter #2 $split_length of function str_split expects int<1, max>, int given.
PHPStan (7.2, ubuntu-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L109
Parameter #2 $split_length of function str_split expects int<1, max>, int given.
PHPStan (8.1, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.1, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.1, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.1, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (8.4, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.4, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.4, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan (8.4, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.4, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (8.4, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path D:\a\phpstan-src\phpstan-src\src\Type\Php\StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
PHPStan (8.2, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.2, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.2, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan (8.2, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.2, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (8.2, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path D:\a\phpstan-src\phpstan-src\src\Type\Php\StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
PHPStan (8.3, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.3, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.3, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Strict comparison using === between list<non-empty-string> and false will always evaluate to false.
PHPStan (8.3, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.3, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (8.3, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L0
Ignored error pattern #^Strict comparison using \=\=\= between non-empty-list<string> and false will always evaluate to false\.$# in path D:\a\phpstan-src\phpstan-src\src\Type\Php\StrSplitFunctionReturnTypeExtension.php was not matched in reported errors.
PHPStan (8.0, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Variable $encoding might not be defined.
PHPStan (8.0, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L135
Strict comparison using === between string and null will always evaluate to false.
PHPStan (8.0, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L103
Parameter #2 $length of function mb_str_split expects int<1, max>, int given.
PHPStan (8.0, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L102
Parameter #2 $length of function str_split expects int<1, max>, int given.
PHPStan (7.3, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L109
Parameter #2 $split_length of function str_split expects int<1, max>, int given.
PHPStan (7.4, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L104
Parameter #2 $split_length of function str_split expects int<1, max>, int given.
PHPStan (7.2, windows-latest): src/Type/Php/StrSplitFunctionReturnTypeExtension.php#L109
Parameter #2 $split_length of function str_split expects int<1, max>, int given.