Skip to content

Use Lowercase in Deprecation Annotations #3166

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 6 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -716,10 +716,6 @@ parameters:
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\\<string\\> but returns array\\<int, string\\|null\\>\\.$#"
count: 1
Expand Down
2 changes: 1 addition & 1 deletion samples/Chart/33_Chart_create_line_dateaxis.php
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ function dateRange(int $nrows, Spreadsheet $wrkbk): array
$ExcelQtrStartDateVal = SharedDate::convertIsoDate($qtrStartStr);

// end the xaxis at the end of the quarter of the last date
$lastDateStr = $dataSheet->getCellByColumnAndRow(2, $nrows + 1)->getValue();
$lastDateStr = $dataSheet->getCell([2, $nrows + 1])->getValue();
$lastDate = DateTime::createFromFormat('Y-m-d', $lastDateStr);
$lastMonth = (int) $lastDate->format('n');
$lastYr = (int) $lastDate->format('Y');
Expand Down
2 changes: 1 addition & 1 deletion src/PhpSpreadsheet/Calculation/Calculation.php
Original file line number Diff line number Diff line change
Expand Up @@ -4819,7 +4819,7 @@ private function processTokenStack($tokens, $cellID = null, ?Cell $cell = null)
}
if (count(Functions::flattenArray($cellIntersect)) === 0) {
$this->debugLog->writeDebugLog('Evaluation Result is %s', $this->showTypeDetails($cellIntersect));
$stack->push('Error', Functions::null(), null);
$stack->push('Error', \PhpOffice\PhpSpreadsheet\Calculation\Information\ExcelError::null(), null);
} else {
$cellRef = Coordinate::stringFromColumnIndex(min($oCol) + 1) . min($oRow) . ':' .
Coordinate::stringFromColumnIndex(max($oCol) + 1) . max($oRow);
Expand Down
62 changes: 26 additions & 36 deletions src/PhpSpreadsheet/Calculation/Database.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

/**
* @deprecated 1.17.0
*
* @codeCoverageIgnore
*/
class Database
{
Expand All @@ -15,10 +17,9 @@ class Database
* Excel Function:
* DAVERAGE(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DAverage::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DAverage class instead
* @see Database\DAverage::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -51,10 +52,9 @@ public static function DAVERAGE($database, $field, $criteria)
* Excel Function:
* DCOUNT(database,[field],criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DCount::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DCount class instead
* @see Database\DCount::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -89,10 +89,9 @@ public static function DCOUNT($database, $field, $criteria)
* Excel Function:
* DCOUNTA(database,[field],criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DCountA::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DCountA class instead
* @see Database\DCountA::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -125,10 +124,9 @@ public static function DCOUNTA($database, $field, $criteria)
* Excel Function:
* DGET(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DGet::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DGet class instead
* @see Database\DGet::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -161,10 +159,9 @@ public static function DGET($database, $field, $criteria)
* Excel Function:
* DMAX(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DMax::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DMax class instead
* @see Database\DMax::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -197,10 +194,9 @@ public static function DMAX($database, $field, $criteria)
* Excel Function:
* DMIN(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DMin::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DMin class instead
* @see Database\DMin::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -232,10 +228,9 @@ public static function DMIN($database, $field, $criteria)
* Excel Function:
* DPRODUCT(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DProduct::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DProduct class instead
* @see Database\DProduct::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -268,10 +263,9 @@ public static function DPRODUCT($database, $field, $criteria)
* Excel Function:
* DSTDEV(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DStDev::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DStDev class instead
* @see Database\DStDev::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -304,10 +298,9 @@ public static function DSTDEV($database, $field, $criteria)
* Excel Function:
* DSTDEVP(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DStDevP::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DStDevP class instead
* @see Database\DStDevP::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -339,10 +332,9 @@ public static function DSTDEVP($database, $field, $criteria)
* Excel Function:
* DSUM(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DSum::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DSum class instead
* @see Database\DSum::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -375,10 +367,9 @@ public static function DSUM($database, $field, $criteria)
* Excel Function:
* DVAR(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DVar::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DVar class instead
* @see Database\DVar::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down Expand Up @@ -411,10 +402,9 @@ public static function DVAR($database, $field, $criteria)
* Excel Function:
* DVARP(database,field,criteria)
*
* @Deprecated 1.17.0
*
* @see Database\DVarP::evaluate()
* @deprecated 1.17.0
* Use the evaluate() method in the Database\DVarP class instead
* @see Database\DVarP::evaluate()
*
* @param mixed[] $database The range of cells that makes up the list or database.
* A database is a list of related data in which rows of related
Expand Down
Loading