Skip to content

Commit c31f9f7

Browse files
committed
Sync date_diff and DateTime::diff return type
This function/method cannot return false.
1 parent 48e2e53 commit c31f9f7

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

ext/date/php_date.stub.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ public function setTimestamp(int $timestamp) {}
238238
public function getTimestamp() {}
239239

240240
/**
241-
* @return DateInterval|false
241+
* @return DateInterval
242242
* @alias date_diff
243243
*/
244244
public function diff(DateTimeInterface $targetObject, bool $absolute = false) {}
@@ -291,7 +291,7 @@ public function getOffset() {}
291291
public function getTimestamp() {}
292292

293293
/**
294-
* @return DateInterval|false
294+
* @return DateInterval
295295
* @alias date_diff
296296
*/
297297
public function diff(DateTimeInterface $targetObject, bool $absolute = false) {}

ext/date/php_date_arginfo.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/* This is a generated file, edit the .stub.php file instead.
2-
* Stub hash: 339c2c91f38eeaafac6134ac04573243069502f5 */
2+
* Stub hash: 880a93d8a3461635447318317869fa7d3d7762dd */
33

44
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_strtotime, 0, 1, MAY_BE_LONG|MAY_BE_FALSE)
55
ZEND_ARG_TYPE_INFO(0, datetime, IS_STRING, 0)

0 commit comments

Comments
 (0)