You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS(), "s|l", &isostr, &isostr_len, &options) ==FAILURE) {
4124
+
zend_type_error("DatePeriod::__construct() accepts either (DateTimeInterface, DateInterval, int [, int]) OR (DateTimeInterface, DateInterval, DateTime [, int]) OR (string [, int]) as arguments");
4125
+
RETURN_THROWS();
4126
+
}
4127
+
}
4128
+
}
4134
4129
4135
4130
dpobj=Z_PHPPERIOD_P(ZEND_THIS);
4136
4131
dpobj->current=NULL;
4137
4132
4138
-
if (start_str) {
4139
-
if (interval_obj) {
4140
-
zend_argument_type_error(2, "must be of type ?int when argument #1 ($start) is a string");
4141
-
RETURN_THROWS();
4142
-
}
4143
-
4144
-
if (!end_is_null) {
4145
-
zend_argument_value_error(3, "must be null when argument #1 ($start) is a string");
Fatal error: Uncaught ArgumentCountError: DatePeriod::__construct() expects at least 1 argument, 0 given in %s:%d
14
-
Stack trace:
15
-
#0 %s(%d): DatePeriod->__construct()
16
-
#1 {main}
17
-
thrown in %s on line %d
17
+
--EXPECT--
18
+
DatePeriod::__construct() accepts either (DateTimeInterface, DateInterval, int [, int]) OR (DateTimeInterface, DateInterval, DateTime [, int]) OR (string [, int]) as arguments
0 commit comments