Skip to content

Commit

Permalink
Restore PDOStatement::setFetchMode() signature
Browse files Browse the repository at this point in the history
I don't think this is worth the BC break, and getting variadic
signature changes compatible across PHP versions is somewhat tricky.
  • Loading branch information
nikic committed Dec 6, 2019
1 parent e0a8c7a commit 4a5e17f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ext/pdo/pdo.stub.php
Original file line number Diff line number Diff line change
Expand Up @@ -129,5 +129,5 @@ public function rowCount() {}
public function setAttribute(int $attribute, $value) {}

/** @return bool */
public function setFetchMode(int $mode, ...$params) {}
public function setFetchMode(int $mode, $param1 = UNKNOWN, $param2 = UNKNOWN) {}
}
3 changes: 2 additions & 1 deletion ext/pdo/pdo_arginfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,5 +125,6 @@ ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_PDOStatement_setFetchMode, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, mode, IS_LONG, 0)
ZEND_ARG_VARIADIC_INFO(0, params)
ZEND_ARG_INFO(0, param1)
ZEND_ARG_INFO(0, param2)
ZEND_END_ARG_INFO()

0 comments on commit 4a5e17f

Please sign in to comment.