+static inline php_property_proxy_object_t *get_propro(zval *object)
+{
+ ZEND_ASSERT(Z_TYPE_P(object) == IS_OBJECT);
+ return PHP_PROPRO_PTR(Z_OBJ_P(object));
+}
+
+static HashTable *get_gc(zval *object, zval **table, int *n)
+{
+ php_property_proxy_object_t *o = get_propro(object);
+
+ if (Z_ISUNDEF(o->parent)) {
+ *table = &o->proxy->container;
+ } else {
+ *table = &o->parent;
+ }
+ *n = 1;
+ return NULL;
+}
+
+static HashTable *get_debug_info(zval *object, int *is_temp)
+{
+ HashTable *ht;
+ zval *zmember;
+ php_property_proxy_object_t *obj = get_propro(object);
+
+ ALLOC_HASHTABLE(ht);
+ zend_hash_init(ht, 3, NULL, NULL, 0);
+
+ if (Z_ISUNDEF(obj->parent)) {
+ zend_hash_str_add_empty_element(ht, "parent", sizeof("parent")-1);
+ zend_hash_str_add(ht, "container", sizeof("container")-1, &obj->proxy->container);
+ } else {
+ zend_hash_str_add(ht, "parent", sizeof("parent")-1, &obj->parent);
+ zend_hash_str_add_empty_element(ht, "container", sizeof("container")-1);
+ }
+
+ zmember = zend_hash_str_add_empty_element(ht, "member", sizeof("member")-1);
+ ZVAL_STR(zmember, obj->proxy->member);
+
+ *is_temp = 1;
+ return ht;
+}
+