summaryrefslogtreecommitdiff
path: root/Zend/zend_generators.c
diff options
context:
space:
mode:
authorMáté Kocsis <kocsismate@woohoolabs.com>2020-04-25 23:10:07 +0200
committerMáté Kocsis <kocsismate@woohoolabs.com>2020-04-26 11:13:14 +0200
commit33c3691c332f9f084a04cba6d775b5876da1fec3 (patch)
tree987ee902bd14e17bfad6d856d71598275689c141 /Zend/zend_generators.c
parentd21d23afef54f152d9ca661909c6d042d6bfcf48 (diff)
downloadphp-git-33c3691c332f9f084a04cba6d775b5876da1fec3.tar.gz
Generate method entries from stubs for Zend classes
Closes GH-5459
Diffstat (limited to 'Zend/zend_generators.c')
-rw-r--r--Zend/zend_generators.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/Zend/zend_generators.c b/Zend/zend_generators.c
index 7bb35384d2..b3261842eb 100644
--- a/Zend/zend_generators.c
+++ b/Zend/zend_generators.c
@@ -1189,23 +1189,11 @@ zend_object_iterator *zend_generator_get_iterator(zend_class_entry *ce, zval *ob
}
/* }}} */
-static const zend_function_entry generator_functions[] = {
- ZEND_ME(Generator, rewind, arginfo_class_Generator_rewind, ZEND_ACC_PUBLIC)
- ZEND_ME(Generator, valid, arginfo_class_Generator_valid, ZEND_ACC_PUBLIC)
- ZEND_ME(Generator, current, arginfo_class_Generator_current, ZEND_ACC_PUBLIC)
- ZEND_ME(Generator, key, arginfo_class_Generator_key, ZEND_ACC_PUBLIC)
- ZEND_ME(Generator, next, arginfo_class_Generator_next, ZEND_ACC_PUBLIC)
- ZEND_ME(Generator, send, arginfo_class_Generator_send, ZEND_ACC_PUBLIC)
- ZEND_ME(Generator, throw, arginfo_class_Generator_throw, ZEND_ACC_PUBLIC)
- ZEND_ME(Generator, getReturn,arginfo_class_Generator_getReturn, ZEND_ACC_PUBLIC)
- ZEND_FE_END
-};
-
void zend_register_generator_ce(void) /* {{{ */
{
zend_class_entry ce;
- INIT_CLASS_ENTRY(ce, "Generator", generator_functions);
+ INIT_CLASS_ENTRY(ce, "Generator", class_Generator_methods);
zend_ce_generator = zend_register_internal_class(&ce);
zend_ce_generator->ce_flags |= ZEND_ACC_FINAL;
zend_ce_generator->create_object = zend_generator_create;