From befbc564f4d0eaf78e67be9bd433fae4f1d47f9b Mon Sep 17 00:00:00 2001 From: oleibman <10341515+oleibman@users.noreply.github.com> Date: Wed, 12 Oct 2022 23:28:08 -0700 Subject: [PATCH] Fix Remainder of Calculation vs. Phpstan Issues (#3108) * Fix Remainder of Calculation vs. Phpstan Issues I had tried to include these changes as part of an earlier effort, but something about them broke Phpstan. I removed them until I could determine the actual cause, which is ... The array `$phpSpreadsheetFunctions` is a very large and very complicated array, typehinted as `array`. It is declared as private static; however, its content never changes (at least not now - there are some outstanding proposals that might change that). I have had some success with changing unmodifiable private static to private const. However, such a change here causes Phpstan to perform a lot more processing and eventually time out. So, leave it as static. Having identified the cause of the problem, none of the other changes were problematic, so this PR applies the rest of them. * Scrutinizer One problem. * Scrutinizer False Positives Without Suggested Annotation See if minor code changes can make these go away. * Scrutinizer Still Experimenting Trying again. --- phpstan-baseline.neon | 587 ------------------ .../Calculation/Calculation.php | 152 +++-- .../Calculation/TextData/Format.php | 2 +- .../Calculation/TextData/Text.php | 4 +- .../Wizard/CellValue.php | 4 +- .../Wizard/TextValue.php | 4 +- 6 files changed, 101 insertions(+), 652 deletions(-) diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index 583ad66ed9..118880ce89 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -1,1335 +1,1017 @@ parameters: ignoreErrors: - - - message: "#^Argument of an invalid type array\\\\|false supplied for foreach, only iterables are supported\\.$#" - count: 3 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Cannot call method cellExists\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" - count: 4 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Cannot call method getCell\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" - count: 6 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Cannot call method getHighestColumn\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" - count: 1 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Cannot call method getHighestRow\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" - count: 1 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Offset 'value' does not exist on array\\|null\\.$#" - count: 5 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Parameter \\#1 \\$haystack of function stripos expects string, float\\|int\\|string given\\.$#" - count: 1 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Parameter \\#1 \\$haystack of function strpos expects string, float\\|int\\|string given\\.$#" - count: 1 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Parameter \\#2 \\$worksheet of static method PhpOffice\\\\PhpSpreadsheet\\\\DefinedName\\:\\:resolveName\\(\\) expects PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet, PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null given\\.$#" - count: 1 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Calculation\\:\\:\\$spreadsheet \\(PhpOffice\\\\PhpSpreadsheet\\\\Spreadsheet\\) does not accept PhpOffice\\\\PhpSpreadsheet\\\\Spreadsheet\\|null\\.$#" - count: 1 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Static property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Calculation\\:\\:\\$instance \\(PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Calculation\\) in isset\\(\\) is not nullable\\.$#" - count: 1 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Strict comparison using \\=\\=\\= between array and '\\(' will always evaluate to false\\.$#" - count: 1 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - - - message: "#^Strict comparison using \\=\\=\\= between non\\-empty\\-array and null will always evaluate to false\\.$#" - count: 2 - path: src/PhpSpreadsheet/Calculation/Calculation.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\:\\:DMAX\\(\\) should return float but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\:\\:DMIN\\(\\) should return float but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\:\\:DPRODUCT\\(\\) should return float\\|string but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\:\\:DSTDEV\\(\\) should return float\\|string but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\:\\:DSTDEVP\\(\\) should return float\\|string but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\:\\:DSUM\\(\\) should return float\\|string but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\:\\:DVAR\\(\\) should return float\\|string but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\:\\:DVARP\\(\\) should return float\\|string but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Parameter \\#2 \\$field of static method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\\\DCountA\\:\\:evaluate\\(\\) expects int\\|string, int\\|string\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\\\DatabaseAbstract\\:\\:buildCondition\\(\\) has parameter \\$criterion with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database/DatabaseAbstract.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\\\DatabaseAbstract\\:\\:evaluate\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database/DatabaseAbstract.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\\\DatabaseAbstract\\:\\:evaluate\\(\\) has parameter \\$criteria with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database/DatabaseAbstract.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\\\DatabaseAbstract\\:\\:evaluate\\(\\) has parameter \\$database with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database/DatabaseAbstract.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\\\DatabaseAbstract\\:\\:evaluate\\(\\) has parameter \\$field with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database/DatabaseAbstract.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Database\\\\DatabaseAbstract\\:\\:processCondition\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Database/DatabaseAbstract.php - - message: "#^Variable \\$dateValue on left side of \\?\\? always exists and is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/DateTimeExcel/DateValue.php - - message: "#^Variable \\$timeValue on left side of \\?\\? always exists and is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/DateTimeExcel/TimeValue.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\BesselJ\\:\\:besselj2a\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/BesselJ.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\BesselJ\\:\\:besselj2b\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/BesselJ.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\ConvertBase\\:\\:validatePlaces\\(\\) has parameter \\$places with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/ConvertBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\ConvertBase\\:\\:validateValue\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/ConvertBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\ConvertUOM\\:\\:getUOMDetails\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/ConvertUOM.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\ConvertUOM\\:\\:resolveTemperatureSynonyms\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/ConvertUOM.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\Erf\\:\\:erfValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/Erf.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\Erf\\:\\:erfValue\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/Erf.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\Erf\\:\\:\\$twoSqrtPi has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/Erf.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\ErfC\\:\\:erfcValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/ErfC.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\ErfC\\:\\:erfcValue\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/ErfC.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Engineering\\\\ErfC\\:\\:\\$oneSqrtPi has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Engineering/ErfC.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\:\\:ISPMT\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\:\\:ISPMT\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\:\\:NPV\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial.php - - message: "#^Parameter \\#1 \\$year of static method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\DateTimeExcel\\\\Helpers\\:\\:isLeapYear\\(\\) expects int\\|string, array\\|int\\|string given\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Amortization.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\Interest\\:\\:rateNextGuess\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/Interest.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\Interest\\:\\:rateNextGuess\\(\\) has parameter \\$futureValue with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/Interest.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\Interest\\:\\:rateNextGuess\\(\\) has parameter \\$numberOfPeriods with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/Interest.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\Interest\\:\\:rateNextGuess\\(\\) has parameter \\$payment with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/Interest.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\Interest\\:\\:rateNextGuess\\(\\) has parameter \\$presentValue with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/Interest.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\Interest\\:\\:rateNextGuess\\(\\) has parameter \\$rate with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/Interest.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\Interest\\:\\:rateNextGuess\\(\\) has parameter \\$type with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/Interest.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\Interest\\:\\:schedulePayment\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/Interest.php - - message: "#^Binary operation \"\\-\" between float\\|string and 0\\|float results in an error\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/InterestAndPrincipal.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\InterestAndPrincipal\\:\\:\\$interest has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/InterestAndPrincipal.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Constant\\\\Periodic\\\\InterestAndPrincipal\\:\\:\\$principal has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Constant/Periodic/InterestAndPrincipal.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Variable\\\\NonPeriodic\\:\\:xnpvOrdered\\(\\) should return float\\|string but returns array\\|string\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Variable/NonPeriodic.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\CashFlow\\\\Variable\\\\Periodic\\:\\:presentValue\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/CashFlow/Variable/Periodic.php - - message: "#^Parameter \\#1 \\$year of static method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Helpers\\:\\:daysPerYear\\(\\) expects int\\|string, array\\|int\\|string given\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Coupons.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Depreciation\\:\\:validateCost\\(\\) has parameter \\$cost with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Depreciation.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Depreciation\\:\\:validateFactor\\(\\) has parameter \\$factor with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Depreciation.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Depreciation\\:\\:validateLife\\(\\) has parameter \\$life with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Depreciation.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Depreciation\\:\\:validateMonth\\(\\) has parameter \\$month with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Depreciation.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Depreciation\\:\\:validatePeriod\\(\\) has parameter \\$period with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Depreciation.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Depreciation\\:\\:validateSalvage\\(\\) has parameter \\$salvage with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Depreciation.php - - message: "#^Binary operation \"/\" between float\\|string and float\\|string results in an error\\.$#" count: 2 path: src/PhpSpreadsheet/Calculation/Financial/Securities/Price.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Securities\\\\Price\\:\\:received\\(\\) should return float\\|string but returns array\\|string\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Securities/Price.php - - message: "#^Parameter \\#1 \\$year of static method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Helpers\\:\\:daysPerYear\\(\\) expects int\\|string, array\\|int\\|string given\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Financial/Securities/Price.php - - message: "#^Parameter \\#1 \\$year of static method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Financial\\\\Helpers\\:\\:daysPerYear\\(\\) expects int\\|string, array\\|int\\|string given\\.$#" count: 2 path: src/PhpSpreadsheet/Calculation/Financial/Securities/Yields.php - - message: "#^Cannot call method getTokenSubType\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\FormulaToken\\|null\\.$#" count: 4 path: src/PhpSpreadsheet/Calculation/FormulaParser.php - - message: "#^Cannot call method getTokenType\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\FormulaToken\\|null\\.$#" count: 9 path: src/PhpSpreadsheet/Calculation/FormulaParser.php - - message: "#^Cannot call method setTokenSubType\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\FormulaToken\\|null\\.$#" count: 5 path: src/PhpSpreadsheet/Calculation/FormulaParser.php - - message: "#^Cannot call method setValue\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\FormulaToken\\|null\\.$#" count: 5 path: src/PhpSpreadsheet/Calculation/FormulaParser.php - - message: "#^Strict comparison using \\=\\=\\= between PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\FormulaToken and null will always evaluate to false\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/FormulaParser.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:ifCondition\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:ifCondition\\(\\) has parameter \\$condition with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:isCellValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:isCellValue\\(\\) has parameter \\$idx with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:isMatrixValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:isMatrixValue\\(\\) has parameter \\$idx with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:isValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:isValue\\(\\) has parameter \\$idx with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:operandSpecialHandling\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Functions\\:\\:operandSpecialHandling\\(\\) has parameter \\$operand with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Functions.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Internal\\\\MakeMatrix\\:\\:make\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Internal/MakeMatrix.php - - message: "#^Call to function is_string\\(\\) with null will always evaluate to false\\.$#" count: 3 path: src/PhpSpreadsheet/Calculation/Logical/Operations.php - - message: "#^Result of && is always false\\.$#" count: 3 path: src/PhpSpreadsheet/Calculation/Logical/Operations.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\:\\:CHOOSE\\(\\) has parameter \\$chooseArgs with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\:\\:OFFSET\\(\\) should return array\\|string but returns array\\|int\\|string\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Address\\:\\:sheetName\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Address.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchFirstValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchFirstValue\\(\\) has parameter \\$lookupArray with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchFirstValue\\(\\) has parameter \\$lookupValue with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchLargestValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchLargestValue\\(\\) has parameter \\$keySet with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchLargestValue\\(\\) has parameter \\$lookupArray with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchLargestValue\\(\\) has parameter \\$lookupValue with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchSmallestValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchSmallestValue\\(\\) has parameter \\$lookupArray with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:matchSmallestValue\\(\\) has parameter \\$lookupValue with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:prepareLookupArray\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:prepareLookupArray\\(\\) has parameter \\$lookupArray with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:prepareLookupArray\\(\\) has parameter \\$matchType with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:validateLookupArray\\(\\) has parameter \\$lookupArray with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:validateLookupValue\\(\\) has parameter \\$lookupValue with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\ExcelMatch\\:\\:validateMatchType\\(\\) has parameter \\$matchType with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/ExcelMatch.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Lookup\\:\\:verifyResultVector\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Lookup.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Lookup\\:\\:verifyResultVector\\(\\) has parameter \\$resultVector with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Lookup.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\LookupBase\\:\\:validateIndexLookup\\(\\) has parameter \\$index_number with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/LookupBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Matrix\\:\\:extractRowValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Offset\\:\\:adjustEndCellColumnForWidth\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Offset.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Offset\\:\\:adjustEndCellColumnForWidth\\(\\) has parameter \\$columns with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Offset.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Offset\\:\\:adjustEndCellColumnForWidth\\(\\) has parameter \\$width with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Offset.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Offset\\:\\:adustEndCellRowForHeight\\(\\) has parameter \\$endCellRow with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Offset.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Offset\\:\\:adustEndCellRowForHeight\\(\\) has parameter \\$height with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Offset.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Offset\\:\\:adustEndCellRowForHeight\\(\\) has parameter \\$rows with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Offset.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Offset\\:\\:extractRequiredCells\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Offset.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\LookupRef\\\\Offset\\:\\:extractWorksheet\\(\\) has parameter \\$cellAddress with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/LookupRef/Offset.php - - message: "#^Binary operation \"/\" between array\\|float\\|int\\|string and array\\|float\\|int\\|string results in an error\\.$#" count: 2 path: src/PhpSpreadsheet/Calculation/MathTrig/Combinations.php - - message: "#^Parameter \\#1 \\$factVal of static method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\MathTrig\\\\Factorial\\:\\:fact\\(\\) expects array\\|float, int\\\\|int\\<0, max\\> given\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/MathTrig/Combinations.php - - message: "#^Binary operation \"/\" between array\\|float\\|int\\|string and float\\|int results in an error\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/MathTrig/Factorial.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\MathTrig\\\\IntClass\\:\\:evaluate\\(\\) should return array\\|string but returns int\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/MathTrig/IntClass.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\:\\:MAXIFS\\(\\) should return float but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\:\\:MINIFS\\(\\) should return float but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Averages\\:\\:filterArguments\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Averages.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Averages\\:\\:filterArguments\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Averages.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Averages\\:\\:modeCalc\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Averages.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Averages\\:\\:modeCalc\\(\\) has parameter \\$data with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Averages.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Conditional\\:\\:SUMIF\\(\\) should return float\\|string but returns float\\|string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Conditional.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Conditional\\:\\:buildConditionSet\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Conditional.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Conditional\\:\\:buildConditionSetForValueRange\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Conditional.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Conditional\\:\\:buildConditions\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Conditional.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Conditional\\:\\:buildDataSet\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Conditional.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Conditional\\:\\:buildDatabase\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Conditional.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Conditional\\:\\:buildDatabaseWithValueRange\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Conditional.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\Beta\\:\\:\\$logBetaCacheP has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/Beta.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\Beta\\:\\:\\$logBetaCacheQ has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/Beta.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\Beta\\:\\:\\$logBetaCacheResult has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/Beta.php - - message: "#^Constant PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:MAX_ITERATIONS is unused\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gammp\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gammp\\(\\) has parameter \\$n with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gammp\\(\\) has parameter \\$x with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gcf\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gcf\\(\\) has parameter \\$n with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gcf\\(\\) has parameter \\$x with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gser\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gser\\(\\) has parameter \\$n with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:gser\\(\\) has parameter \\$x with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:pchisq\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:pchisq\\(\\) has parameter \\$chi2 with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:pchisq\\(\\) has parameter \\$degrees with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Parameter \\#2 \\$columns of static method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\ChiSquared\\:\\:degrees\\(\\) expects int, float\\|int\\<0, max\\> given\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/ChiSquared.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\GammaBase\\:\\:calculateDistribution\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/GammaBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\GammaBase\\:\\:calculateInverse\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/GammaBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\GammaBase\\:\\:logGamma1\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/GammaBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\GammaBase\\:\\:logGamma2\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/GammaBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\GammaBase\\:\\:logGamma3\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/GammaBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\GammaBase\\:\\:logGamma4\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/GammaBase.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\GammaBase\\:\\:\\$logGammaCacheResult has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/GammaBase.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\GammaBase\\:\\:\\$logGammaCacheX has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/GammaBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\NewtonRaphson\\:\\:execute\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/NewtonRaphson.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\NewtonRaphson\\:\\:\\$callback has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/NewtonRaphson.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\Normal\\:\\:inverseNcdf\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/Normal.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\Normal\\:\\:inverseNcdf\\(\\) has parameter \\$p with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/Normal.php - - message: "#^Parameter \\#1 \\$factVal of static method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\MathTrig\\\\Factorial\\:\\:fact\\(\\) expects array\\|float, int\\<0, max\\> given\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/Poisson.php - - message: "#^Binary operation \"\\-\" between float\\|string and float\\|int\\|numeric\\-string results in an error\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/StandardNormal.php - - message: "#^Constant PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Distributions\\\\StudentT\\:\\:MAX_ITERATIONS is unused\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Distributions/StudentT.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\MaxMinBase\\:\\:datatypeAdjustmentAllowStrings\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/MaxMinBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\MaxMinBase\\:\\:datatypeAdjustmentAllowStrings\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/MaxMinBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Percentiles\\:\\:percentileFilterValues\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Percentiles.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Percentiles\\:\\:rankFilterValues\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Percentiles.php - - message: "#^Binary operation \"/\" between array\\|float\\|int\\|string and array\\|float\\|int\\|string results in an error\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Permutations.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Trends\\:\\:GROWTH\\(\\) should return array\\ but returns array\\\\>\\>\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Trends.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Trends\\:\\:TREND\\(\\) should return array\\ but returns array\\\\>\\>\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Trends.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Trends\\:\\:checkTrendArrays\\(\\) has parameter \\$array1 with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Trends.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\Trends\\:\\:checkTrendArrays\\(\\) has parameter \\$array2 with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/Trends.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\VarianceBase\\:\\:datatypeAdjustmentAllowStrings\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/VarianceBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\VarianceBase\\:\\:datatypeAdjustmentAllowStrings\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/VarianceBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\VarianceBase\\:\\:datatypeAdjustmentBooleans\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/VarianceBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\Statistical\\\\VarianceBase\\:\\:datatypeAdjustmentBooleans\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/Statistical/VarianceBase.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Calculation\\\\TextData\\:\\:CONCATENATE\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/TextData.php - - message: "#^Variable \\$value on left side of \\?\\? always exists and is not nullable\\.$#" count: 4 path: src/PhpSpreadsheet/Calculation/TextData/Extract.php - - message: "#^Variable \\$value on left side of \\?\\? always exists and is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Calculation/TextData/Text.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Cell\\:\\:getFormulaAttributes\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Cell/Cell.php - - message: "#^Parameter \\#2 \\$format of static method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\:\\:toFormattedString\\(\\) expects string, string\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Cell/Cell.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Cell\\:\\:\\$formulaAttributes has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Cell/Cell.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Cell\\:\\:\\$parent \\(PhpOffice\\\\PhpSpreadsheet\\\\Collection\\\\Cells\\) in isset\\(\\) is not nullable\\.$#" count: 6 path: src/PhpSpreadsheet/Cell/Cell.php - - message: "#^Unreachable statement \\- code above always terminates\\.$#" count: 1 path: src/PhpSpreadsheet/Cell/Cell.php - - message: "#^Call to an undefined method object\\:\\:getHashCode\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Cell/Coordinate.php - - message: "#^Parameter \\#4 \\$currentRow of static method PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Coordinate\\:\\:validateRange\\(\\) expects int, string given\\.$#" count: 1 path: src/PhpSpreadsheet/Cell/Coordinate.php - - message: "#^Parameter \\#5 \\$endRow of static method PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Coordinate\\:\\:validateRange\\(\\) expects int, string given\\.$#" count: 1 path: src/PhpSpreadsheet/Cell/Coordinate.php - - message: "#^Parameter \\#1 \\$namedRange of method PhpOffice\\\\PhpSpreadsheet\\\\Spreadsheet\\:\\:addNamedRange\\(\\) expects PhpOffice\\\\PhpSpreadsheet\\\\NamedRange, \\$this\\(PhpOffice\\\\PhpSpreadsheet\\\\DefinedName\\) given\\.$#" count: 1 path: src/PhpSpreadsheet/DefinedName.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\DefinedName\\:\\:\\$scope \\(PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\) does not accept PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" count: 3 path: src/PhpSpreadsheet/DefinedName.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\DefinedName\\:\\:\\$worksheet \\(PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\) does not accept PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/DefinedName.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\IOFactory\\:\\:createReader\\(\\) should return PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\IReader but returns object\\.$#" count: 1 path: src/PhpSpreadsheet/IOFactory.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\IOFactory\\:\\:createWriter\\(\\) should return PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\IWriter but returns object\\.$#" count: 1 path: src/PhpSpreadsheet/IOFactory.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\IOFactory\\:\\:\\$readers has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/IOFactory.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\IOFactory\\:\\:\\$writers has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/IOFactory.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\BaseReader\\:\\:getSecurityScanner\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/BaseReader.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\BaseReader\\:\\:\\$fileHandle has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/BaseReader.php - - message: "#^Comparison operation \"\\<\" between int and SimpleXMLElement\\|null results in an error\\.$#" count: 2 path: src/PhpSpreadsheet/Reader/Gnumeric.php - - message: "#^Offset 'percentage' does not exist on SimpleXMLElement\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Gnumeric/PageSetup.php - - message: "#^Offset 'value' does not exist on SimpleXMLElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Reader/Gnumeric/PageSetup.php - - message: "#^Variable \\$orientation on left side of \\?\\? always exists and is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Gnumeric/PageSetup.php - - message: "#^Comparison operation \"\\<\\=\" between SimpleXMLElement\\|null and int results in an error\\.$#" count: 2 path: src/PhpSpreadsheet/Reader/Gnumeric/Styles.php - - message: "#^Comparison operation \"\\>\" between SimpleXMLElement\\|null and int results in an error\\.$#" count: 2 path: src/PhpSpreadsheet/Reader/Gnumeric/Styles.php - - message: "#^Variable \\$value on left side of \\?\\? always exists and is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Html.php - - message: "#^Cannot call method children\\(\\) on SimpleXMLElement\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Cannot call method getAttributeNS\\(\\) on DOMElement\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Cannot call method getElementsByTagNameNS\\(\\) on DOMElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Cannot call method getNamedItem\\(\\) on DOMNamedNodeMap\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Cannot call method getNamespaces\\(\\) on SimpleXMLElement\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Cannot call method setSelectedCellByColumnAndRow\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\:\\:listWorksheetNames\\(\\) should return array\\ but returns array\\\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Parameter \\#1 \\$element of method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\:\\:scanElementForText\\(\\) expects DOMNode, DOMElement\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Parameter \\#1 \\$settings of method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\:\\:lookForActiveSheet\\(\\) expects DOMElement, DOMElement\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Parameter \\#1 \\$settings of method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\:\\:lookForSelectedCells\\(\\) expects DOMElement, DOMElement\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods.php - - message: "#^Cannot call method getElementsByTagNameNS\\(\\) on DOMElement\\|null\\.$#" count: 3 path: src/PhpSpreadsheet/Reader/Ods/PageSettings.php - - message: "#^Expression on left side of \\?\\? is not nullable\\.$#" count: 6 path: src/PhpSpreadsheet/Reader/Ods/PageSettings.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\\\PageSettings\\:\\:\\$pageLayoutStyles has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods/PageSettings.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\\\Properties\\:\\:load\\(\\) has parameter \\$namespacesMeta with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods/Properties.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\\\Properties\\:\\:setMetaProperties\\(\\) has parameter \\$namespacesMeta with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods/Properties.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\\\Properties\\:\\:setMetaProperties\\(\\) has parameter \\$propertyName with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods/Properties.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\\\Properties\\:\\:setUserDefinedProperty\\(\\) has parameter \\$propertyValue with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods/Properties.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\\\Properties\\:\\:setUserDefinedProperty\\(\\) has parameter \\$propertyValueAttributes with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods/Properties.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Ods\\\\Properties\\:\\:\\$spreadsheet has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Ods/Properties.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Security\\\\XmlScanner\\:\\:__construct\\(\\) has parameter \\$pattern with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Security/XmlScanner.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Security\\\\XmlScanner\\:\\:getInstance\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Security/XmlScanner.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Security\\\\XmlScanner\\:\\:threadSafeLibxmlDisableEntityLoaderAvailability\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Security/XmlScanner.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Security\\\\XmlScanner\\:\\:toUtf8\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Security/XmlScanner.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Security\\\\XmlScanner\\:\\:toUtf8\\(\\) has parameter \\$xml with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Security/XmlScanner.php - - message: "#^Parameter \\#2 \\$subject of function preg_match expects string, array\\\\|string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Security/XmlScanner.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Security\\\\XmlScanner\\:\\:\\$callback has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Security/XmlScanner.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Security\\\\XmlScanner\\:\\:\\$libxmlDisableEntityLoaderValue has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Security/XmlScanner.php - - message: "#^Call to an undefined method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\\\SpgrContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\\\SpgrContainer\\\\SpContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\\\BstoreContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\\\BstoreContainer\\\\BSE\\:\\:getDgContainer\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\\\SpgrContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\\\SpgrContainer\\\\SpContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\\\BstoreContainer\\|PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\\\BstoreContainer\\\\BSE\\:\\:getDggContainer\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method object\\:\\:getEndCoordinates\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method object\\:\\:getEndOffsetX\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method object\\:\\:getEndOffsetY\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method object\\:\\:getNestingLevel\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method object\\:\\:getOPT\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method object\\:\\:getStartCoordinates\\(\\)\\.$#" count: 2 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method object\\:\\:getStartOffsetX\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Call to an undefined method object\\:\\:getStartOffsetY\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Cannot access offset 1 on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^If condition is always true\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:includeCellRangeFiltered\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:includeCellRangeFiltered\\(\\) has parameter \\$cellRangeAddress with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:parseRichText\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:parseRichText\\(\\) has parameter \\$is with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Negated boolean expression is always false\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Parameter \\#1 \\$block of method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:makeKey\\(\\) expects int, float given\\.$#" count: 2 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Parameter \\#1 \\$showSummaryBelow of method PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\:\\:setShowSummaryBelow\\(\\) expects bool, int given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Parameter \\#1 \\$showSummaryRight of method PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\:\\:setShowSummaryRight\\(\\) expects bool, int given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Parameter \\#2 \\$row of method PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\IReadFilter\\:\\:readCell\\(\\) expects int, string given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Parameter \\#2 \\$row of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Xls\\:\\:sizeRow\\(\\) expects int, string given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Parameter \\#2 \\$startRow of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Xls\\:\\:getDistanceY\\(\\) expects int, string given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Parameter \\#3 \\$subject of function str_replace expects array\\|string, int\\|string\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Parameter \\#4 \\$endRow of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Xls\\:\\:getDistanceY\\(\\) expects int, string given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:\\$data \\(string\\) does not accept string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:\\$documentSummaryInformation \\(string\\) does not accept string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:\\$documentSummaryInformation \\(string\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:\\$md5Ctxt is never written, only read\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:\\$summaryInformation \\(string\\) does not accept string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xls\\:\\:\\$summaryInformation \\(string\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xls.php - - message: "#^Unreachable statement \\- code above always terminates\\.$#" count: 8 @@ -1344,1344 +1026,1075 @@ parameters: message: "#^Parameter \\#1 \\$haystack of function strpos expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xml.php - - message: "#^Parameter \\#1 \\$textValue of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\StringHelper\\:\\:convertEncoding\\(\\) expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xml.php - - message: "#^Parameter \\#2 \\$subject of function preg_match expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xml.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Reader\\\\Xml\\:\\:\\$fileContents has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xml.php - - message: "#^Argument of an invalid type SimpleXMLElement\\|null supplied for foreach, only iterables are supported\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xml/Properties.php - - message: "#^Argument of an invalid type SimpleXMLElement\\|null supplied for foreach, only iterables are supported\\.$#" count: 1 path: src/PhpSpreadsheet/Reader/Xml/Style.php - - message: "#^Elseif condition is always true\\.$#" count: 1 path: src/PhpSpreadsheet/ReferenceHelper.php - - message: "#^Expression on left side of \\?\\? is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/ReferenceHelper.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\RichText\\\\Run\\:\\:\\$font \\(PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\Font\\) does not accept PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\Font\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/RichText/Run.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Settings\\:\\:getHttpClient\\(\\) should return Psr\\\\Http\\\\Client\\\\ClientInterface but returns Psr\\\\Http\\\\Client\\\\ClientInterface\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Settings.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Settings\\:\\:getRequestFactory\\(\\) should return Psr\\\\Http\\\\Message\\\\RequestFactoryInterface but returns Psr\\\\Http\\\\Message\\\\RequestFactoryInterface\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Settings.php - - message: "#^Negated boolean expression is always false\\.$#" count: 1 path: src/PhpSpreadsheet/Settings.php - - message: "#^Result of && is always false\\.$#" count: 1 path: src/PhpSpreadsheet/Settings.php - - message: "#^Strict comparison using \\=\\=\\= between int and null will always evaluate to false\\.$#" count: 1 path: src/PhpSpreadsheet/Settings.php - - message: "#^Parameter \\#1 \\$excelFormatCode of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Date\\:\\:isDateTimeFormatCode\\(\\) expects string, string\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Date.php - - message: "#^Parameter \\#1 \\$string of function substr expects string, int given\\.$#" count: 2 path: src/PhpSpreadsheet/Shared/Date.php - - message: "#^Parameter \\#1 \\$unixTimestamp of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Date\\:\\:timestampToExcel\\(\\) expects int, float\\|int\\|string given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Date.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Date\\:\\:\\$possibleDateFormatCharacters has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Date.php - - message: "#^Cannot access offset 1 on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Drawing.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\:\\:getDgId\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\:\\:getLastSpId\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\:\\:getSpgrContainer\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\:\\:setDgId\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\:\\:setLastSpId\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\:\\:setSpgrContainer\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\:\\:setSpgrContainer\\(\\) has parameter \\$spgrContainer with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\:\\:\\$spgrContainer has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DgContainer\\\\SpgrContainer\\:\\:getChildren\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DgContainer/SpgrContainer.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\\\BstoreContainer\\\\BSE\\:\\:\\$parent is never read, only written\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Escher/DggContainer/BstoreContainer/BSE.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\EigenvalueDecomposition\\:\\:\\$cdivi has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/EigenvalueDecomposition.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\EigenvalueDecomposition\\:\\:\\$e has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/EigenvalueDecomposition.php - - message: "#^Else branch is unreachable because previous condition is always true\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/LUDecomposition.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\LUDecomposition\\:\\:getDoublePivot\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/LUDecomposition.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:__construct\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:arrayLeftDivide\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:arrayLeftDivideEquals\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:arrayRightDivide\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:arrayRightDivideEquals\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:arrayTimes\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:arrayTimesEquals\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:concat\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:getMatrix\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:minus\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:minusEquals\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:plus\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:plusEquals\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:power\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:times\\(\\) has parameter \\$args with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Parameter \\#3 \\$c of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\JAMA\\\\Matrix\\:\\:set\\(\\) expects float\\|int\\|null, string given\\.$#" count: 2 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^Unreachable statement \\- code above always terminates\\.$#" count: 19 path: src/PhpSpreadsheet/Shared/JAMA/Matrix.php - - message: "#^If condition is always true\\.$#" count: 7 path: src/PhpSpreadsheet/Shared/JAMA/SingularValueDecomposition.php - - message: "#^Left side of && is always true\\.$#" count: 4 path: src/PhpSpreadsheet/Shared/JAMA/SingularValueDecomposition.php - - message: "#^Cannot access offset 1 on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Cannot access offset 2 on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Cannot access offset 3 on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Cannot access offset 4 on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\:\\:getData\\(\\) should return string but returns string\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\:\\:getStream\\(\\) should return resource but returns resource\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#1 \\$No of class PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS constructor expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#1 \\$oleTimestamp of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\:\\:OLE2LocalDate\\(\\) expects string, string\\|false given\\.$#" count: 2 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#1 \\$string of function substr expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#2 \\$name of class PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS constructor expects string, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#3 \\$type of class PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS constructor expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#4 \\$prev of class PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS constructor expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#5 \\$next of class PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS constructor expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#6 \\$dir of class PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS constructor expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#9 \\$data of class PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS constructor expects string, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\:\\:\\$root \\(PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE.php - - message: "#^Parameter \\#2 \\$offset of function array_slice expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS.php - - message: "#^Parameter \\#3 \\$length of function array_slice expects int\\|null, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:\\$_data \\(string\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:\\$startBlock \\(int\\) on left side of \\?\\? is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS.php - - message: "#^Parameter \\#1 \\$No of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/File.php - - message: "#^Parameter \\#4 \\$prev of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/File.php - - message: "#^Parameter \\#5 \\$next of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/File.php - - message: "#^Parameter \\#6 \\$dir of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/File.php - - message: "#^Parameter \\#1 \\$No of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#1 \\$iSBDcnt of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:saveHeader\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#1 \\$iSbdSize of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:saveBbd\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#1 \\$iStBlk of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:saveBigData\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#2 \\$iBBcnt of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:saveHeader\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#2 \\$iBsize of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:saveBbd\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#3 \\$iPPScnt of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:saveHeader\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#3 \\$iPpsCnt of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:saveBbd\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#4 \\$prev of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#5 \\$next of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#6 \\$dir of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#9 \\$data of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\:\\:__construct\\(\\) expects string, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:\\$bigBlockSize \\(int\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLE\\\\PPS\\\\Root\\:\\:\\$smallBlockSize \\(int\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLE/PPS/Root.php - - message: "#^Parameter \\#1 \\$data of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLERead\\:\\:getInt4d\\(\\) expects string, string\\|false given\\.$#" count: 8 path: src/PhpSpreadsheet/Shared/OLERead.php - - message: "#^Parameter \\#1 \\$string of function substr expects string, string\\|false given\\.$#" count: 2 path: src/PhpSpreadsheet/Shared/OLERead.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLERead\\:\\:\\$data has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLERead.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLERead\\:\\:\\$documentSummaryInformation has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLERead.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLERead\\:\\:\\$summaryInformation has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLERead.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\OLERead\\:\\:\\$wrkbook has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLERead.php - - message: "#^Strict comparison using \\=\\=\\= between int and null will always evaluate to false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/OLERead.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:calculateGoodnessOfFit\\(\\) has parameter \\$const with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:calculateGoodnessOfFit\\(\\) has parameter \\$meanX with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:calculateGoodnessOfFit\\(\\) has parameter \\$meanY with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:calculateGoodnessOfFit\\(\\) has parameter \\$sumX with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:calculateGoodnessOfFit\\(\\) has parameter \\$sumX2 with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:calculateGoodnessOfFit\\(\\) has parameter \\$sumXY with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:calculateGoodnessOfFit\\(\\) has parameter \\$sumY with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:calculateGoodnessOfFit\\(\\) has parameter \\$sumY2 with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:getBestFitType\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:getError\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:sumSquares\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$DFResiduals has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$SSRegression has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$SSResiduals has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$correlation has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$covariance has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$f has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$goodnessOfFit has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$intersect has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$intersectSE has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$slope has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$slopeSE has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$stdevOfResiduals has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$xOffset has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\BestFit\\:\\:\\$yOffset has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/BestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\PolynomialBestFit\\:\\:getCoefficients\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/PolynomialBestFit.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\PolynomialBestFit\\:\\:getCoefficients\\(\\) has parameter \\$dp with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/PolynomialBestFit.php - - message: "#^Call to an undefined method object\\:\\:getGoodnessOfFit\\(\\)\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/Trend.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\Trend\\:\\:calculate\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/Trend.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\Trend\\:\\:calculate\\(\\) has parameter \\$const with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/Trend.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\Trend\\:\\:calculate\\(\\) has parameter \\$trendType with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/Trend.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\Trend\\:\\:calculate\\(\\) has parameter \\$xValues with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/Trend.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Trend\\\\Trend\\:\\:calculate\\(\\) has parameter \\$yValues with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/Trend/Trend.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\XMLWriter\\:\\:getData\\(\\) should return string but returns string\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/XMLWriter.php - - message: "#^Parameter \\#1 \\$uri of method XMLWriter\\:\\:openUri\\(\\) expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/XMLWriter.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\XMLWriter\\:\\:\\$debugEnabled has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/XMLWriter.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\XMLWriter\\:\\:\\$tempFileName \\(string\\) does not accept string\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Shared/XMLWriter.php - - message: "#^Call to function is_array\\(\\) with string will always evaluate to false\\.$#" count: 1 path: src/PhpSpreadsheet/Spreadsheet.php - - message: "#^Parameter \\#1 \\$worksheet of method PhpOffice\\\\PhpSpreadsheet\\\\Spreadsheet\\:\\:getIndex\\(\\) expects PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet, PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Spreadsheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Spreadsheet\\:\\:\\$workbookViewVisibilityValues has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Spreadsheet.php - - message: "#^Strict comparison using \\=\\=\\= between PhpOffice\\\\PhpSpreadsheet\\\\Spreadsheet and null will always evaluate to false\\.$#" count: 1 path: src/PhpSpreadsheet/Spreadsheet.php - - message: "#^Unreachable statement \\- code above always terminates\\.$#" count: 1 path: src/PhpSpreadsheet/Spreadsheet.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalDataBar\\:\\:setConditionalFormattingRuleExt\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalDataBar.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalDataBar\\:\\:setMaximumConditionalFormatValueObject\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalDataBar.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalDataBar\\:\\:setMinimumConditionalFormatValueObject\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalDataBar.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalDataBar\\:\\:setShowValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalDataBar.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalDataBarExtension\\:\\:getXmlAttributes\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalDataBarExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalDataBarExtension\\:\\:getXmlElements\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalDataBarExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalDataBarExtension\\:\\:setMaximumConditionalFormatValueObject\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalDataBarExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalDataBarExtension\\:\\:setMinimumConditionalFormatValueObject\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalDataBarExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormatValueObject\\:\\:__construct\\(\\) has parameter \\$type with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormatValueObject.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormatValueObject\\:\\:__construct\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormatValueObject.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormatValueObject\\:\\:setCellFormula\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormatValueObject.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormatValueObject\\:\\:setType\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormatValueObject.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormatValueObject\\:\\:setValue\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormatValueObject.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormatValueObject\\:\\:\\$cellFormula has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormatValueObject.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormatValueObject\\:\\:\\$type has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormatValueObject.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormatValueObject\\:\\:\\$value has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormatValueObject.php - - message: "#^Cannot access property \\$axisPosition on SimpleXMLElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Cannot access property \\$border on SimpleXMLElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Cannot access property \\$direction on SimpleXMLElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Cannot access property \\$gradient on SimpleXMLElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Cannot access property \\$maxLength on SimpleXMLElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Cannot access property \\$minLength on SimpleXMLElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Cannot access property \\$negativeBarBorderColorSameAsPositive on SimpleXMLElement\\|null\\.$#" count: 2 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormattingRuleExtension\\:\\:__construct\\(\\) has parameter \\$id with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormattingRuleExtension\\:\\:generateUuid\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormattingRuleExtension\\:\\:parseExtDataBarElementChildrenFromXml\\(\\) has parameter \\$ns with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormattingRuleExtension\\:\\:parseExtLstXml\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormattingRuleExtension\\:\\:parseExtLstXml\\(\\) has parameter \\$extLstXml with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Offset 'rgb' does not exist on SimpleXMLElement\\|null\\.$#" count: 4 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Offset 'theme' does not exist on SimpleXMLElement\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Offset 'tint' does not exist on SimpleXMLElement\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\ConditionalFormatting\\\\ConditionalFormattingRuleExtension\\:\\:\\$id has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/ConditionalFormatting/ConditionalFormattingRuleExtension.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormat\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormat\\(\\) has parameter \\$sections with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormat\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormatCompare\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormatCompare\\(\\) has parameter \\$cond with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormatCompare\\(\\) has parameter \\$dfcond with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormatCompare\\(\\) has parameter \\$dfval with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormatCompare\\(\\) has parameter \\$val with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:splitFormatCompare\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\Formatter\\:\\:toFormattedString\\(\\) should return string but returns float\\|int\\|string\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/Formatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\\\PercentageFormatter\\:\\:format\\(\\) has parameter \\$value with no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Style/NumberFormat/PercentageFormatter.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\CellIterator\\:\\:adjustForExistingOnlyRange\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/CellIterator.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Drawing\\\\Shadow\\:\\:\\$color \\(PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\Color\\) does not accept PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\Color\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Drawing/Shadow.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\PageSetup\\:\\:getPrintArea\\(\\) should return string but returns string\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/PageSetup.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\SheetView\\:\\:\\$sheetViewTypes has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/SheetView.php - - message: "#^Strict comparison using \\=\\=\\= between int\\ and null will always evaluate to false\\.$#" count: 2 path: src/PhpSpreadsheet/Worksheet/SheetView.php - - message: "#^Strict comparison using \\=\\=\\= between string and null will always evaluate to false\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/SheetView.php - - message: "#^Cannot call method getCalculatedValue\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Cell\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Cannot call method getHashCode\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Cannot call method getValue\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Cell\\|null\\.$#" count: 4 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Cannot call method getWorksheet\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\DefinedName\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Cannot call method getXfIndex\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Cell\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Cannot call method rangeToArray\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^If condition is always true\\.$#" count: 2 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Left side of && is always true\\.$#" count: 2 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\:\\:getChartByName\\(\\) should return PhpOffice\\\\PhpSpreadsheet\\\\Chart\\\\Chart\\|false but returns PhpOffice\\\\PhpSpreadsheet\\\\Chart\\\\Chart\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Parameter \\#1 \\$index of class PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\ColumnDimension constructor expects string, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Parameter \\#1 \\$index of class PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\RowDimension constructor expects int, null given\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Parameter \\#1 \\$range of static method PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Coordinate\\:\\:rangeDimension\\(\\) expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Parameter \\#2 \\$format of static method PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\NumberFormat\\:\\:toFormattedString\\(\\) expects string, string\\|null given\\.$#" count: 2 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Parameter \\#3 \\$rotation of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Font\\:\\:calculateColumnWidth\\(\\) expects int, int\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Worksheet\\\\Worksheet\\:\\:\\$parent \\(PhpOffice\\\\PhpSpreadsheet\\\\Spreadsheet\\) does not accept PhpOffice\\\\PhpSpreadsheet\\\\Spreadsheet\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Right side of && is always true\\.$#" count: 1 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Strict comparison using \\=\\=\\= between string and null will always evaluate to false\\.$#" count: 2 path: src/PhpSpreadsheet/Worksheet/Worksheet.php - - message: "#^Negated boolean expression is always false\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Ods.php - - message: "#^If condition is always true\\.$#" count: 2 path: src/PhpSpreadsheet/Writer/Ods/Cell/Style.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Ods\\\\Cell\\\\Style\\:\\:\\$writer has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Ods/Cell/Style.php - - message: "#^Parameter \\#1 \\$range of static method PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Coordinate\\:\\:splitRange\\(\\) expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Ods/Content.php - - message: "#^Parameter \\#2 \\$value of method XMLWriter\\:\\:writeAttribute\\(\\) expects string, int\\<2, max\\> given\\.$#" count: 3 path: src/PhpSpreadsheet/Writer/Ods/Content.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Ods\\\\Content\\:\\:\\$formulaConvertor has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Ods/Content.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Ods\\\\Formula\\:\\:\\$definedNames has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Ods/Formula.php - - message: "#^Cannot call method getHashCode\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\Font\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Cannot use array destructuring on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Offset 'endCoordinates' does not exist on array\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Offset 'endOffsetX' does not exist on array\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Offset 'endOffsetY' does not exist on array\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Offset 'startCoordinates' does not exist on array\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Offset 'startOffsetX' does not exist on array\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Offset 'startOffsetY' does not exist on array\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Parameter \\#1 \\$blipType of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\\\BstoreContainer\\\\BSE\\:\\:setBlipType\\(\\) expects int, int\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Parameter \\#1 \\$data of method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Escher\\\\DggContainer\\\\BstoreContainer\\\\BSE\\\\Blip\\:\\:setData\\(\\) expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Parameter \\#1 \\$font of method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Workbook\\:\\:addFont\\(\\) expects PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\Font, PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\Font\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\:\\:\\$documentSummaryInformation \\(string\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\:\\:\\$summaryInformation \\(string\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\BIFFwriter\\:\\:writeEof\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/BIFFwriter.php - - message: "#^Static property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\BIFFwriter\\:\\:\\$byteOrder \\(int\\) in isset\\(\\) is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/BIFFwriter.php - - message: "#^Elseif condition is always true\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Escher.php - - message: "#^If condition is always true\\.$#" count: 3 path: src/PhpSpreadsheet/Writer/Xls/Escher.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Escher\\:\\:\\$data has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Escher.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Escher\\:\\:\\$object has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Escher.php - - message: "#^If condition is always false\\.$#" count: 2 path: src/PhpSpreadsheet/Writer/Xls/Font.php - - message: "#^Parameter \\#1 \\$bold of static method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Font\\:\\:mapBold\\(\\) expects bool, bool\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Font.php - - message: "#^Parameter \\#1 \\$fontName of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\Font\\:\\:getCharsetFromFontName\\(\\) expects string, string\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Font.php - - message: "#^Parameter \\#1 \\$textValue of static method PhpOffice\\\\PhpSpreadsheet\\\\Shared\\\\StringHelper\\:\\:UTF8toBIFF8UnicodeShort\\(\\) expects string, string\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Font.php - - message: "#^Parameter \\#1 \\$underline of static method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Font\\:\\:mapUnderline\\(\\) expects string, string\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Font.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Parser\\:\\:advance\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Parser.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Parser\\:\\:\\$spreadsheet has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Parser.php - - message: "#^Unreachable statement \\- code above always terminates\\.$#" count: 5 path: src/PhpSpreadsheet/Writer/Xls/Parser.php - - message: "#^Cannot access offset 'encoding' on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Workbook.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Workbook\\:\\:writeAllDefinedNamesBiff8\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Workbook.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Workbook\\:\\:writeExternalsheetBiff8\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Workbook.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Workbook\\:\\:writeMsoDrawingGroup\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Workbook.php - - message: "#^Method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Workbook\\:\\:writeSupbookInternal\\(\\) has no return type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Workbook.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Workbook\\:\\:\\$biffSize is never read, only written\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Workbook.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Workbook\\:\\:\\$colors has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Workbook.php - - message: "#^Cannot access offset 'comp' on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Cannot access offset 'ident' on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Cannot access offset 'sa' on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Cannot access offset 1 on array\\|false\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Cannot access offset 2 on array\\|false\\.$#" count: 2 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Cannot call method getHashCode\\(\\) on PhpOffice\\\\PhpSpreadsheet\\\\Style\\\\Font\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Expression on left side of \\?\\? is not nullable\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Parameter \\#1 \\$coordinates of static method PhpOffice\\\\PhpSpreadsheet\\\\Cell\\\\Coordinate\\:\\:indexesFromString\\(\\) expects string, string\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Parameter \\#1 \\$string of function strlen expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Parameter \\#1 \\$string of function substr expects string, string\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Parameter \\#2 \\$length of function fread expects int\\<0, max\\>, int\\<0, max\\>\\|false given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Parameter \\#4 \\$isError of method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:writeBoolErr\\(\\) expects bool, int given\\.$#" count: 3 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Parameter \\#5 \\$width of method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:positionImage\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Parameter \\#6 \\$height of method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:positionImage\\(\\) expects int, float given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:\\$activePane \\(int\\) does not accept int\\|null\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:\\$colors has no type specified\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:\\$countCellStyleXfs is never read, only written\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:\\$outlineBelow is never read, only written\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:\\$outlineRight is never read, only written\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:\\$selection is never read, only written\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Worksheet\\:\\:\\$xlsStringMaxLength is never read, only written\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Worksheet.php - - message: "#^Parameter \\#1 \\$textRotation of static method PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Xf\\:\\:mapTextRotation\\(\\) expects int, int\\|null given\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Xf.php - - message: "#^Property PhpOffice\\\\PhpSpreadsheet\\\\Writer\\\\Xls\\\\Xf\\:\\:\\$diag is never read, only written\\.$#" count: 1 path: src/PhpSpreadsheet/Writer/Xls/Xf.php - diff --git a/src/PhpSpreadsheet/Calculation/Calculation.php b/src/PhpSpreadsheet/Calculation/Calculation.php index abeebf39e0..3709466a4d 100644 --- a/src/PhpSpreadsheet/Calculation/Calculation.php +++ b/src/PhpSpreadsheet/Calculation/Calculation.php @@ -64,14 +64,14 @@ class Calculation /** * Instance of this class. * - * @var Calculation + * @var ?Calculation */ private static $instance; /** * Instance of the spreadsheet this Calculation Engine is using. * - * @var Spreadsheet + * @var ?Spreadsheet */ private $spreadsheet; @@ -102,10 +102,8 @@ class Calculation /** * List of operators that can be used within formulae * The true/false value indicates whether it is a binary operator or a unary operator. - * - * @var array */ - private static $operators = [ + private const CALCULATION_OPERATORS = [ '+' => true, '-' => true, '*' => true, '/' => true, '^' => true, '&' => true, '%' => false, '~' => false, '>' => true, '<' => true, '=' => true, '>=' => true, @@ -115,10 +113,8 @@ class Calculation /** * List of binary operators (those that expect two operands). - * - * @var array */ - private static $binaryOperators = [ + private const BINARY_OPERATORS = [ '+' => true, '-' => true, '*' => true, '/' => true, '^' => true, '&' => true, '>' => true, '<' => true, '=' => true, '>=' => true, '<=' => true, '<>' => true, @@ -221,25 +217,47 @@ class Calculation * * @var array */ - public static $localeBoolean = [ + private static $localeBoolean = [ 'TRUE' => 'TRUE', 'FALSE' => 'FALSE', 'NULL' => 'NULL', ]; + public static function getLocaleBoolean(string $index): string + { + return self::$localeBoolean[$index]; + } + /** * Excel constant string translations to their PHP equivalents * Constant conversion from text name/value to actual (datatyped) value. * * @var array */ - public static $excelConstants = [ + private static $excelConstants = [ 'TRUE' => true, 'FALSE' => false, 'NULL' => null, ]; - /** @var array */ + public static function keyInExcelConstants(string $key): bool + { + return array_key_exists($key, self::$excelConstants); + } + + /** @return mixed */ + public static function getExcelConstants(string $key) + { + return self::$excelConstants[$key]; + } + + /** + * Array of functions usable on Spreadsheet. + * In theory, this could be const rather than static; + * however, Phpstan breaks trying to analyze it when attempted. + * + *@var array + */ private static $phpSpreadsheetFunctions = [ 'ABS' => [ 'category' => Category::CATEGORY_MATH_AND_TRIG, @@ -2855,7 +2873,8 @@ public function __construct(?Spreadsheet $spreadsheet = null) private static function loadLocales(): void { $localeFileDirectory = __DIR__ . '/locale/'; - foreach (glob($localeFileDirectory . '*', GLOB_ONLYDIR) as $filename) { + $localeFileNames = glob($localeFileDirectory . '*', GLOB_ONLYDIR) ?: []; + foreach ($localeFileNames as $filename) { $filename = substr($filename, strlen($localeFileDirectory)); if ($filename != 'en') { self::$validLocaleLanguages[] = $filename; @@ -3118,7 +3137,7 @@ public function setLocale(string $locale) } // Retrieve the list of locale or language specific function names - $localeFunctions = file($functionNamesFile, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); + $localeFunctions = file($functionNamesFile, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES) ?: []; foreach ($localeFunctions as $localeFunction) { [$localeFunction] = explode('##', $localeFunction); // Strip out comments if (strpos($localeFunction, '=') !== false) { @@ -3142,7 +3161,7 @@ public function setLocale(string $locale) return false; } - $localeSettings = file($configFile, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); + $localeSettings = file($configFile, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES) ?: []; foreach ($localeSettings as $localeSetting) { [$localeSetting] = explode('##', $localeSetting); // Strip out comments if (strpos($localeSetting, '=') !== false) { @@ -3239,7 +3258,7 @@ private static function translateFormula(array $from, array $to, string $formula $notWithinQuotes = false; foreach ($temp as &$value) { // Only adjust in alternating array entries - $notWithinQuotes = !$notWithinQuotes; + $notWithinQuotes = self::logicalNot($notWithinQuotes); if ($notWithinQuotes === true) { $value = self::translateFormulaBlock($from, $to, $value, $inFunctionBracesLevel, $inMatrixBracesLevel, $fromSeparator, $toSeparator); } @@ -3453,12 +3472,19 @@ public function calculateCellValue(?Cell $cell = null, $resetLog = true) try { $result = self::unwrapResult($this->_calculateFormulaValue($cell->getValue(), $cell->getCoordinate(), $cell)); + if ($this->spreadsheet === null) { + throw new Exception('null spreadsheet in calculateCellValue'); + } $cellAddress = array_pop($this->cellStack); - $this->spreadsheet->getSheetByName($cellAddress['sheet'])->getCell($cellAddress['cell']); + if ($cellAddress === null) { + throw new Exception('null cellAddress in calculateCellValue'); + } + $testSheet = $this->spreadsheet->getSheetByName($cellAddress['sheet']); + if ($testSheet === null) { + throw new Exception('worksheet not found in calculateCellValue'); + } + $testSheet->getCell($cellAddress['cell']); } catch (\Exception $e) { - $cellAddress = array_pop($this->cellStack); - $this->spreadsheet->getSheetByName($cellAddress['sheet'])->getCell($cellAddress['cell']); - throw new Exception($e->getMessage()); } @@ -3933,7 +3959,7 @@ private function convertMatrixReferences($formula) $notWithinQuotes = false; foreach ($temp as &$value) { // Only count/replace in alternating array entries - $notWithinQuotes = !$notWithinQuotes; + $notWithinQuotes = self::logicalNot($notWithinQuotes); if ($notWithinQuotes === true) { $openCount += substr_count($value, self::FORMULA_OPEN_MATRIX_BRACE); $closeCount += substr_count($value, self::FORMULA_CLOSE_MATRIX_BRACE); @@ -4077,11 +4103,11 @@ private function internalParseFormula($formula, ?Cell $cell = null) ++$index; // Drop the redundant plus symbol } elseif ((($opCharacter == '~') || ($opCharacter == '∩') || ($opCharacter == '∪')) && (!$isOperandOrFunction)) { // We have to explicitly deny a tilde, union or intersect because they are legal return $this->raiseFormulaError("Formula Error: Illegal character '~'"); // on the stack but not in the input expression - } elseif ((isset(self::$operators[$opCharacter]) || $isOperandOrFunction) && $expectingOperator) { // Are we putting an operator on the stack? + } elseif ((isset(self::CALCULATION_OPERATORS[$opCharacter]) || $isOperandOrFunction) && $expectingOperator) { // Are we putting an operator on the stack? while ( $stack->count() > 0 && ($o2 = $stack->last()) && - isset(self::$operators[$o2['value']]) && + isset(self::CALCULATION_OPERATORS[$o2['value']]) && @(self::$operatorAssociativity[$opCharacter] ? self::$operatorPrecedence[$opCharacter] < self::$operatorPrecedence[$o2['value']] : self::$operatorPrecedence[$opCharacter] <= self::$operatorPrecedence[$o2['value']]) ) { $output[] = $stack->pop(); // Swap operands and higher precedence operators from the stack to the output @@ -4095,9 +4121,6 @@ private function internalParseFormula($formula, ?Cell $cell = null) } elseif ($opCharacter == ')' && $expectingOperator) { // Are we expecting to close a parenthesis? $expectingOperand = false; while (($o2 = $stack->pop()) && $o2['value'] !== '(') { // Pop off the stack back to the last ( - if ($o2 === null) { - return $this->raiseFormulaError('Formula Error: Unexpected closing brace ")"'); - } $output[] = $o2; } $d = $stack->last(2); @@ -4121,10 +4144,14 @@ private function internalParseFormula($formula, ?Cell $cell = null) $output[] = $stack->pop(); // Pop the function and push onto the output if (isset(self::$controlFunctions[$functionName])) { $expectedArgumentCount = self::$controlFunctions[$functionName]['argumentCount']; + // Scrutinizer says functionCall is unused after this assignment. + // It might be right, but I'm too lazy to confirm. $functionCall = self::$controlFunctions[$functionName]['functionCall']; + self::doNothing($functionCall); } elseif (isset(self::$phpSpreadsheetFunctions[$functionName])) { $expectedArgumentCount = self::$phpSpreadsheetFunctions[$functionName]['argumentCount']; $functionCall = self::$phpSpreadsheetFunctions[$functionName]['functionCall']; + self::doNothing($functionCall); } else { // did we somehow push a non-function on the stack? this should never happen return $this->raiseFormulaError('Formula Error: Internal error, non-function on stack'); } @@ -4145,6 +4172,7 @@ private function internalParseFormula($formula, ?Cell $cell = null) } } elseif ($expectedArgumentCount != '*') { $isOperandOrFunction = preg_match('/(\d*)([-+,])(\d*)/', $expectedArgumentCount, $argMatch); + self::doNothing($isOperandOrFunction); switch ($argMatch[2]) { case '+': if ($argumentCount < $argMatch[1]) { @@ -4182,9 +4210,6 @@ private function internalParseFormula($formula, ?Cell $cell = null) } while (($o2 = $stack->pop()) && $o2['value'] !== '(') { // Pop off the stack back to the last ( - if ($o2 === null) { - return $this->raiseFormulaError('Formula Error: Unexpected ,'); - } $output[] = $o2; // pop the argument expression stuff and push onto the output } // If we've a comma when we're expecting an operand, then what we actually have is a null operand; @@ -4256,20 +4281,20 @@ private function internalParseFormula($formula, ?Cell $cell = null) if ($matches[2] === '') { // Otherwise, we 'inherit' the worksheet reference from the start cell reference // The start of the cell range reference should be the last entry in $output - $rangeStartCellRef = $output[count($output) - 1]['value']; + $rangeStartCellRef = $output[count($output) - 1]['value'] ?? ''; if ($rangeStartCellRef === ':') { // Do we have chained range operators? - $rangeStartCellRef = $output[count($output) - 2]['value']; + $rangeStartCellRef = $output[count($output) - 2]['value'] ?? ''; } preg_match('/^' . self::CALCULATION_REGEXP_CELLREF . '$/miu', $rangeStartCellRef, $rangeStartMatches); if ($rangeStartMatches[2] > '') { $val = $rangeStartMatches[2] . '!' . $val; } } else { - $rangeStartCellRef = $output[count($output) - 1]['value']; + $rangeStartCellRef = $output[count($output) - 1]['value'] ?? ''; if ($rangeStartCellRef === ':') { // Do we have chained range operators? - $rangeStartCellRef = $output[count($output) - 2]['value']; + $rangeStartCellRef = $output[count($output) - 2]['value'] ?? ''; } preg_match('/^' . self::CALCULATION_REGEXP_CELLREF . '$/miu', $rangeStartCellRef, $rangeStartMatches); if ($rangeStartMatches[2] !== $matches[2]) { @@ -4299,9 +4324,9 @@ private function internalParseFormula($formula, ?Cell $cell = null) !is_numeric($val) && ((ctype_alpha($val) === false || strlen($val) > 3)) && (preg_match('/^' . self::CALCULATION_REGEXP_DEFINEDNAME . '$/mui', $val) !== false) && - ($this->spreadsheet->getNamedRange($val) !== null) + ($this->spreadsheet === null || $this->spreadsheet->getNamedRange($val) !== null) ) { - $namedRange = $this->spreadsheet->getNamedRange($val); + $namedRange = ($this->spreadsheet === null) ? null : $this->spreadsheet->getNamedRange($val); if ($namedRange !== null) { $stackItemType = 'Defined Name'; $address = str_replace('$', '', $namedRange->getValue()); @@ -4319,7 +4344,7 @@ private function internalParseFormula($formula, ?Cell $cell = null) $val = $address; } } else { - $startRowColRef = $output[count($output) - 1]['value']; + $startRowColRef = $output[count($output) - 1]['value'] ?? ''; [$rangeWS1, $startRowColRef] = Worksheet::extractSheetTitle($startRowColRef, true); $rangeSheetRef = $rangeWS1; if ($rangeWS1 !== '') { @@ -4395,7 +4420,7 @@ private function internalParseFormula($formula, ?Cell $cell = null) $stackItemType = 'Defined Name'; $stackItemReference = $val; } elseif (is_numeric($val)) { - if ((strpos($val, '.') !== false) || (stripos($val, 'e') !== false) || ($val > PHP_INT_MAX) || ($val < -PHP_INT_MAX)) { + if ((strpos((string) $val, '.') !== false) || (stripos((string) $val, 'e') !== false) || ($val > PHP_INT_MAX) || ($val < -PHP_INT_MAX)) { $val = (float) $val; } else { $val = (int) $val; @@ -4419,7 +4444,7 @@ private function internalParseFormula($formula, ?Cell $cell = null) } else { return $this->raiseFormulaError("Formula Error: Unexpected ')'"); } - } elseif (isset(self::$operators[$opCharacter]) && !$expectingOperator) { + } elseif (isset(self::CALCULATION_OPERATORS[$opCharacter]) && !$expectingOperator) { return $this->raiseFormulaError("Formula Error: Unexpected operator '$opCharacter'"); } else { // I don't even want to know what you did to get here return $this->raiseFormulaError('Formula Error: An unexpected error occurred'); @@ -4428,7 +4453,7 @@ private function internalParseFormula($formula, ?Cell $cell = null) if ($index == strlen($formula)) { // Did we end with an operator?. // Only valid for the % unary operator - if ((isset(self::$operators[$opCharacter])) && ($opCharacter != '%')) { + if ((isset(self::CALCULATION_OPERATORS[$opCharacter])) && ($opCharacter != '%')) { return $this->raiseFormulaError("Formula Error: Operator '$opCharacter' has no operands"); } @@ -4462,7 +4487,7 @@ private function internalParseFormula($formula, ?Cell $cell = null) while ( $stack->count() > 0 && ($o2 = $stack->last()) && - isset(self::$operators[$o2['value']]) && + isset(self::CALCULATION_OPERATORS[$o2['value']]) && @(self::$operatorAssociativity[$opCharacter] ? self::$operatorPrecedence[$opCharacter] < self::$operatorPrecedence[$o2['value']] : self::$operatorPrecedence[$opCharacter] <= self::$operatorPrecedence[$o2['value']]) ) { $output[] = $stack->pop(); // Swap operands and higher precedence operators from the stack to the output @@ -4475,7 +4500,7 @@ private function internalParseFormula($formula, ?Cell $cell = null) while (($op = $stack->pop()) !== null) { // pop everything off the stack and push onto output - if ((is_array($op) && $op['value'] == '(') || ($op === '(')) { + if ((is_array($op) && $op['value'] == '(')) { return $this->raiseFormulaError("Formula Error: Expecting ')'"); // if there are any opening braces on the stack, then braces were unbalanced } $output[] = $op; @@ -4605,7 +4630,7 @@ private function processTokenStack($tokens, $cellID = null, ?Cell $cell = null) } // if the token is a binary operator, pop the top two values off the stack, do the operation, and push the result back on the stack - if (!is_numeric($token) && isset(self::$binaryOperators[$token])) { + if (!is_numeric($token) && isset(self::BINARY_OPERATORS[$token])) { // We must have two operands, error if we don't if (($operand2Data = $stack->pop()) === null) { return $this->raiseFormulaError('Internal error - Operand value missing from stack'); @@ -4642,7 +4667,7 @@ private function processTokenStack($tokens, $cellID = null, ?Cell $cell = null) // Binary Operators case ':': // Range if ($operand1Data['type'] === 'Defined Name') { - if (preg_match('/$' . self::CALCULATION_REGEXP_DEFINEDNAME . '^/mui', $operand1Data['reference']) !== false) { + if (preg_match('/$' . self::CALCULATION_REGEXP_DEFINEDNAME . '^/mui', $operand1Data['reference']) !== false && $this->spreadsheet !== null) { $definedName = $this->spreadsheet->getNamedRange($operand1Data['reference']); if ($definedName !== null) { $operand1Data['reference'] = $operand1Data['value'] = str_replace('$', '', $definedName->getValue()); @@ -4692,7 +4717,7 @@ private function processTokenStack($tokens, $cellID = null, ?Cell $cell = null) $oRow[] = $oCR[1]; } $cellRef = Coordinate::stringFromColumnIndex(min($oCol) + 1) . min($oRow) . ':' . Coordinate::stringFromColumnIndex(max($oCol) + 1) . max($oRow); - if ($pCellParent !== null) { + if ($pCellParent !== null && $this->spreadsheet !== null) { $cellValue = $this->extractCellRange($cellRef, $this->spreadsheet->getSheetByName($sheet1), false); } else { return $this->raiseFormulaError('Unable to access Cell Reference'); @@ -4853,7 +4878,7 @@ private function processTokenStack($tokens, $cellID = null, ?Cell $cell = null) } $matches[2] = trim($matches[2], "\"'"); $this->debugLog->writeDebugLog('Evaluating Cell Range %s in worksheet %s', $cellRef, $matches[2]); - if ($pCellParent !== null) { + if ($pCellParent !== null && $this->spreadsheet !== null) { $cellValue = $this->extractCellRange($cellRef, $this->spreadsheet->getSheetByName($matches[2]), false); } else { return $this->raiseFormulaError('Unable to access Cell Reference'); @@ -4882,7 +4907,7 @@ private function processTokenStack($tokens, $cellID = null, ?Cell $cell = null) return $this->raiseFormulaError('Unable to access External Workbook'); } $this->debugLog->writeDebugLog('Evaluating Cell %s in worksheet %s', $cellRef, $matches[2]); - if ($pCellParent !== null) { + if ($pCellParent !== null && $this->spreadsheet !== null) { $cellSheet = $this->spreadsheet->getSheetByName($matches[2]); if ($cellSheet && $cellSheet->cellExists($cellRef)) { $cellValue = $this->extractCellRange($cellRef, $this->spreadsheet->getSheetByName($matches[2]), false); @@ -5272,7 +5297,7 @@ protected function raiseFormulaError(string $errorMessage) { $this->formulaError = $errorMessage; $this->cyclicReferenceStack->clear(); - $suppress = $this->suppressFormulaErrors ?? $this->suppressFormulaErrorsNew; + $suppress = /** @scrutinizer ignore-deprecated */ $this->suppressFormulaErrors ?? $this->suppressFormulaErrorsNew; if (!$suppress) { throw new Exception($errorMessage); } @@ -5299,16 +5324,18 @@ public function extractCellRange(&$range = 'A1', ?Worksheet $worksheet = null, $ if (strpos($range, '!') !== false) { [$worksheetName, $range] = Worksheet::extractSheetTitle($range, true); - $worksheet = $this->spreadsheet->getSheetByName($worksheetName); + $worksheet = ($this->spreadsheet === null) ? null : $this->spreadsheet->getSheetByName($worksheetName); } // Extract range $aReferences = Coordinate::extractAllCellReferencesInRange($range); $range = "'" . $worksheetName . "'" . '!' . $range; + $currentCol = ''; + $currentRow = 0; if (!isset($aReferences[1])) { // Single cell in range sscanf($aReferences[0], '%[A-Z]%d', $currentCol, $currentRow); - if ($worksheet->cellExists($aReferences[0])) { + if ($worksheet !== null && $worksheet->cellExists($aReferences[0])) { $returnValue[$currentRow][$currentCol] = $worksheet->getCell($aReferences[0])->getCalculatedValue($resetLog); } else { $returnValue[$currentRow][$currentCol] = null; @@ -5318,7 +5345,7 @@ public function extractCellRange(&$range = 'A1', ?Worksheet $worksheet = null, $ foreach ($aReferences as $reference) { // Extract range sscanf($reference, '%[A-Z]%d', $currentCol, $currentRow); - if ($worksheet->cellExists($reference)) { + if ($worksheet !== null && $worksheet->cellExists($reference)) { $returnValue[$currentRow][$currentCol] = $worksheet->getCell($reference)->getCalculatedValue($resetLog); } else { $returnValue[$currentRow][$currentCol] = null; @@ -5347,11 +5374,11 @@ public function extractNamedRange(string &$range = 'A1', ?Worksheet $worksheet = if ($worksheet !== null) { if (strpos($range, '!') !== false) { [$worksheetName, $range] = Worksheet::extractSheetTitle($range, true); - $worksheet = $this->spreadsheet->getSheetByName($worksheetName); + $worksheet = ($this->spreadsheet === null) ? null : $this->spreadsheet->getSheetByName($worksheetName); } // Named range? - $namedRange = DefinedName::resolveName($range, /** @scrutinizer ignore-type */ $worksheet); + $namedRange = ($worksheet === null) ? null : DefinedName::resolveName($range, $worksheet); if ($namedRange === null) { return Information\ExcelError::REF(); } @@ -5360,10 +5387,10 @@ public function extractNamedRange(string &$range = 'A1', ?Worksheet $worksheet = $range = $namedRange->getValue(); $splitRange = Coordinate::splitRange($range); // Convert row and column references - if (ctype_alpha($splitRange[0][0])) { - $range = $splitRange[0][0] . '1:' . $splitRange[0][1] . $namedRange->getWorksheet()->getHighestRow(); - } elseif (ctype_digit($splitRange[0][0])) { - $range = 'A' . $splitRange[0][0] . ':' . $namedRange->getWorksheet()->getHighestColumn() . $splitRange[0][1]; + if ($worksheet !== null && ctype_alpha($splitRange[0][0])) { + $range = $splitRange[0][0] . '1:' . $splitRange[0][1] . $worksheet->getHighestRow(); + } elseif ($worksheet !== null && ctype_digit($splitRange[0][0])) { + $range = 'A' . $splitRange[0][0] . ':' . $worksheet->getHighestColumn() . $splitRange[0][1]; } // Extract range @@ -5371,7 +5398,7 @@ public function extractNamedRange(string &$range = 'A1', ?Worksheet $worksheet = if (!isset($aReferences[1])) { // Single cell (or single column or row) in range [$currentCol, $currentRow] = Coordinate::coordinateFromString($aReferences[0]); - if ($worksheet->cellExists($aReferences[0])) { + if ($worksheet !== null && $worksheet->cellExists($aReferences[0])) { $returnValue[$currentRow][$currentCol] = $worksheet->getCell($aReferences[0])->getCalculatedValue($resetLog); } else { $returnValue[$currentRow][$currentCol] = null; @@ -5381,7 +5408,7 @@ public function extractNamedRange(string &$range = 'A1', ?Worksheet $worksheet = foreach ($aReferences as $reference) { // Extract range [$currentCol, $currentRow] = Coordinate::coordinateFromString($reference); - if ($worksheet->cellExists($reference)) { + if ($worksheet !== null && $worksheet->cellExists($reference)) { $returnValue[$currentRow][$currentCol] = $worksheet->getCell($reference)->getCalculatedValue($resetLog); } else { $returnValue[$currentRow][$currentCol] = null; @@ -5593,4 +5620,15 @@ public function getSuppressFormulaErrors(): bool { return $this->suppressFormulaErrorsNew; } + + private static function logicalNot(bool $arg): bool + { + return $arg === false; + } + + /** @param mixed $arg */ + private static function doNothing($arg): bool + { + return (bool) $arg; + } } diff --git a/src/PhpSpreadsheet/Calculation/TextData/Format.php b/src/PhpSpreadsheet/Calculation/TextData/Format.php index 03e75d1d22..f8db04996f 100644 --- a/src/PhpSpreadsheet/Calculation/TextData/Format.php +++ b/src/PhpSpreadsheet/Calculation/TextData/Format.php @@ -236,7 +236,7 @@ public static function valueToText($value, $format = false) $value = ($format === true) ? Calculation::wrapResult($value) : $value; $value = str_replace("\n", '', $value); } elseif (is_bool($value)) { - $value = Calculation::$localeBoolean[$value === true ? 'TRUE' : 'FALSE']; + $value = Calculation::getLocaleBoolean($value ? 'TRUE' : 'FALSE'); } return (string) $value; diff --git a/src/PhpSpreadsheet/Calculation/TextData/Text.php b/src/PhpSpreadsheet/Calculation/TextData/Text.php index 83810422cc..984f3f6825 100644 --- a/src/PhpSpreadsheet/Calculation/TextData/Text.php +++ b/src/PhpSpreadsheet/Calculation/TextData/Text.php @@ -232,7 +232,7 @@ public static function fromArray(array $array, int $format = 0): string private static function formatValueMode0($cellValue): string { if (is_bool($cellValue)) { - return ($cellValue) ? Calculation::$localeBoolean['TRUE'] : Calculation::$localeBoolean['FALSE']; + return Calculation::getLocaleBoolean($cellValue ? 'TRUE' : 'FALSE'); } return (string) $cellValue; @@ -246,7 +246,7 @@ private static function formatValueMode1($cellValue): string if (is_string($cellValue) && Functions::isError($cellValue) === false) { return Calculation::FORMULA_STRING_QUOTE . $cellValue . Calculation::FORMULA_STRING_QUOTE; } elseif (is_bool($cellValue)) { - return ($cellValue) ? Calculation::$localeBoolean['TRUE'] : Calculation::$localeBoolean['FALSE']; + return Calculation::getLocaleBoolean($cellValue ? 'TRUE' : 'FALSE'); } return (string) $cellValue; diff --git a/src/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/CellValue.php b/src/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/CellValue.php index f36033dd1c..b6150744a5 100644 --- a/src/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/CellValue.php +++ b/src/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/CellValue.php @@ -140,8 +140,8 @@ public static function fromConditional(Conditional $conditional, string $cellRan // Best-guess to try and identify if the text is a string literal, a cell reference or a formula? $operandValueType = Wizard::VALUE_TYPE_LITERAL; if (is_string($condition)) { - if (array_key_exists($condition, Calculation::$excelConstants)) { - $condition = Calculation::$excelConstants[$condition]; + if (Calculation::keyInExcelConstants($condition)) { + $condition = Calculation::getExcelConstants($condition); } elseif (preg_match('/^' . Calculation::CALCULATION_REGEXP_CELLREF_RELATIVE . '$/i', $condition)) { $operandValueType = Wizard::VALUE_TYPE_CELL; $condition = self::reverseAdjustCellRef($condition, $cellRange); diff --git a/src/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/TextValue.php b/src/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/TextValue.php index 4fa635bec5..8362984fa7 100644 --- a/src/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/TextValue.php +++ b/src/PhpSpreadsheet/Style/ConditionalFormatting/Wizard/TextValue.php @@ -129,9 +129,7 @@ public static function fromConditional(Conditional $conditional, string $cellRan // Best-guess to try and identify if the text is a string literal, a cell reference or a formula? $wizard->operandValueType = Wizard::VALUE_TYPE_LITERAL; $condition = $conditional->getText(); - if (is_string($condition) && array_key_exists($condition, Calculation::$excelConstants)) { - $condition = Calculation::$excelConstants[$condition]; - } elseif (preg_match('/^' . Calculation::CALCULATION_REGEXP_CELLREF_RELATIVE . '$/i', $condition)) { + if (preg_match('/^' . Calculation::CALCULATION_REGEXP_CELLREF_RELATIVE . '$/i', $condition)) { $wizard->operandValueType = Wizard::VALUE_TYPE_CELL; $condition = self::reverseAdjustCellRef($condition, $cellRange); } elseif (