summaryrefslogtreecommitdiff
path: root/Zend/zend_iterators.h
diff options
context:
space:
mode:
Diffstat (limited to 'Zend/zend_iterators.h')
-rw-r--r--Zend/zend_iterators.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/Zend/zend_iterators.h b/Zend/zend_iterators.h
index 873f36efbe..09346aee90 100644
--- a/Zend/zend_iterators.h
+++ b/Zend/zend_iterators.h
@@ -36,7 +36,7 @@ typedef struct _zend_object_iterator_funcs {
int (*valid)(zend_object_iterator *iter TSRMLS_DC);
/* fetch the item data for the current element */
- void (*get_current_data)(zend_object_iterator *iter, zval ***data TSRMLS_DC);
+ zval *(*get_current_data)(zend_object_iterator *iter TSRMLS_DC);
/* fetch the key for the current element (optional, may be NULL). The key
* should be written into the provided zval* using the ZVAL_* macros. If
@@ -55,7 +55,8 @@ typedef struct _zend_object_iterator_funcs {
} zend_object_iterator_funcs;
struct _zend_object_iterator {
- void *data;
+ zend_object std;
+ zval data;
zend_object_iterator_funcs *funcs;
ulong index; /* private to fe_reset/fe_fetch opcodes */
};
@@ -82,7 +83,8 @@ BEGIN_EXTERN_C()
ZEND_API enum zend_object_iterator_kind zend_iterator_unwrap(zval *array_ptr, zend_object_iterator **iter TSRMLS_DC);
/* given an iterator, wrap it up as a zval for use by the engine opcodes */
-ZEND_API zval *zend_iterator_wrap(zend_object_iterator *iter TSRMLS_DC);
+ZEND_API void zend_iterator_init(zend_object_iterator *iter TSRMLS_DC);
+ZEND_API void zend_iterator_dtor(zend_object_iterator *iter TSRMLS_DC);
ZEND_API void zend_register_iterator_wrapper(TSRMLS_D);
END_EXTERN_C()