summaryrefslogtreecommitdiff
path: root/ext/reflection/php_reflection.c
diff options
context:
space:
mode:
authorNikita Popov <nikic@php.net>2016-12-18 17:10:54 +0100
committerNikita Popov <nikic@php.net>2016-12-18 17:10:54 +0100
commit4ef4e34c2ef59a2e3b85e7a4f64d2c3f371b61e0 (patch)
tree618a925a8a9bcb3ac4bb9c256d5651dcb2051461 /ext/reflection/php_reflection.c
parent7d404bc3d636a9bac94bf169dd31bb09fea8c7d5 (diff)
parentc1af9f282f62eaf8a5973068ce373a800e0f752c (diff)
downloadphp-git-4ef4e34c2ef59a2e3b85e7a4f64d2c3f371b61e0.tar.gz
Merge branch 'PHP-7.0' into PHP-7.1
Diffstat (limited to 'ext/reflection/php_reflection.c')
-rw-r--r--ext/reflection/php_reflection.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c
index 1169bb682c..1c5b09d87f 100644
--- a/ext/reflection/php_reflection.c
+++ b/ext/reflection/php_reflection.c
@@ -348,6 +348,15 @@ static void reflection_free_objects_storage(zend_object *object) /* {{{ */
}
/* }}} */
+static HashTable *reflection_get_gc(zval *obj, zval **gc_data, int *gc_data_count) /* {{{ */
+{
+ reflection_object *intern = Z_REFLECTION_P(obj);
+ *gc_data = &intern->obj;
+ *gc_data_count = 1;
+ return zend_std_get_properties(obj);
+}
+/* }}} */
+
static zend_object *reflection_objects_new(zend_class_entry *class_type) /* {{{ */
{
reflection_object *intern;
@@ -6802,6 +6811,7 @@ PHP_MINIT_FUNCTION(reflection) /* {{{ */
reflection_object_handlers.free_obj = reflection_free_objects_storage;
reflection_object_handlers.clone_obj = NULL;
reflection_object_handlers.write_property = _reflection_write_property;
+ reflection_object_handlers.get_gc = reflection_get_gc;
INIT_CLASS_ENTRY(_reflection_entry, "ReflectionException", reflection_exception_functions);
reflection_exception_ptr = zend_register_internal_class_ex(&_reflection_entry, zend_ce_exception);