Skip to content

Commit

Permalink
Add missing param to DatePeriod::__construct()
Browse files Browse the repository at this point in the history
The signature is very overloaded, but takes at most four params,
not three.
  • Loading branch information
nikic committed Jul 17, 2020
1 parent 6b2c4be commit 81d8d60
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ext/date/php_date.stub.php
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,7 @@ public static function __set_state(array $array) {}
class DatePeriod implements IteratorAggregate
{
/* Has an overloaded signature */
public function __construct($start, $interval = UNKNOWN, $end = UNKNOWN) {}
public function __construct($start, $interval = UNKNOWN, $end = UNKNOWN, $options = UNKNOWN) {}

/** @return DateTimeInterface */
public function getStartDate() {}
Expand Down
3 changes: 2 additions & 1 deletion ext/date/php_date_arginfo.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* This is a generated file, edit the .stub.php file instead.
* Stub hash: 656ce4aafb67dd9fc53d53081bb1a73c7a8b42d6 */
* Stub hash: d1a39515c3457e71f6a00d2bb406ad5c79564e7e */

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_strtotime, 0, 1, MAY_BE_LONG|MAY_BE_FALSE)
ZEND_ARG_TYPE_INFO(0, time, IS_STRING, 0)
Expand Down Expand Up @@ -409,6 +409,7 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_DatePeriod___construct, 0, 0, 1)
ZEND_ARG_INFO(0, start)
ZEND_ARG_INFO(0, interval)
ZEND_ARG_INFO(0, end)
ZEND_ARG_INFO(0, options)
ZEND_END_ARG_INFO()

#define arginfo_class_DatePeriod_getStartDate arginfo_class_DateTimeInterface_getTimezone
Expand Down

0 comments on commit 81d8d60

Please sign in to comment.