xref: /ext-ds/src/php/classes/php_hashable_ce.c (revision 9955b96e)
1 #include "../../common.h"
2 #include "../arginfo.h"
3 
4 #include "php_hashable_ce.h"
5 
6 zend_class_entry *hashable_ce;
7 
8 ARGINFO_NONE(hash);
9 ARGINFO_ZVAL_RETURN_BOOL(equals, obj);
10 
11 static zend_function_entry hashable_methods[] = {
12     PHP_ABSTRACT_ME(Hashable, hash,   arginfo_hash)
13     PHP_ABSTRACT_ME(Hashable, equals, arginfo_equals)
14     PHP_FE_END
15 };
16 
php_ds_register_hashable()17 void php_ds_register_hashable()
18 {
19     zend_class_entry ce;
20     INIT_CLASS_ENTRY(ce, PHP_DS_NS(Hashable), hashable_methods);
21     hashable_ce = zend_register_internal_interface(&ce);
22 }
23