mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
18 lines
511 B
PHP
18 lines
511 B
PHP
--TEST--
|
|
Bug #54283 (new DatePeriod(NULL) causes crash)
|
|
--FILE--
|
|
<?php
|
|
|
|
try {
|
|
var_dump(new DatePeriod(NULL));
|
|
} catch (Exception $e) {
|
|
var_dump($e->getMessage());
|
|
}
|
|
|
|
?>
|
|
--EXPECTF--
|
|
Deprecated: DatePeriod::__construct(): Passing null to parameter #1 ($start) of type string is deprecated in %s on line %d
|
|
|
|
Deprecated: Calling DatePeriod::__construct(string $isostr, int $options = 0) is deprecated, use DatePeriod::createFromISO8601String() instead in %s on line %d
|
|
string(24) "Unknown or bad format ()"
|