From 11b5ec491fa953f880b02e78ad4988cd4cde05ec Mon Sep 17 00:00:00 2001 From: =?utf8?q?Pavel=20Kov=C3=A1=C5=99?= Date: Fri, 11 May 2018 16:57:39 +0200 Subject: [PATCH] Export php_date_get_interval_ce() and php_date_get_period_ce() for extension use --- ext/date/php_date.c | 10 ++++++++++ ext/date/php_date.h | 2 ++ 2 files changed, 12 insertions(+) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index be1df2d81c..81ef632cb2 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -612,6 +612,16 @@ PHPAPI zend_class_entry *php_date_get_timezone_ce(void) return date_ce_timezone; } +PHPAPI zend_class_entry *php_date_get_interval_ce(void) +{ + return date_ce_interval; +} + +PHPAPI zend_class_entry *php_date_get_period_ce(void) +{ + return date_ce_period; +} + static zend_object_handlers date_object_handlers_date; static zend_object_handlers date_object_handlers_immutable; static zend_object_handlers date_object_handlers_timezone; diff --git a/ext/date/php_date.h b/ext/date/php_date.h index ebabf45a7b..d652aafaa1 100644 --- a/ext/date/php_date.h +++ b/ext/date/php_date.h @@ -224,6 +224,8 @@ PHPAPI zend_class_entry *php_date_get_date_ce(void); PHPAPI zend_class_entry *php_date_get_immutable_ce(void); PHPAPI zend_class_entry *php_date_get_interface_ce(void); PHPAPI zend_class_entry *php_date_get_timezone_ce(void); +PHPAPI zend_class_entry *php_date_get_interval_ce(void); +PHPAPI zend_class_entry *php_date_get_period_ce(void); /* Functions for creating DateTime objects, and initializing them from a string */ PHPAPI zval *php_date_instantiate(zend_class_entry *pce, zval *object); -- 2.40.0