__tostring = reg_function;
} else if (zend_string_equals_literal(lowercase_name, ZEND_GET_FUNC_NAME)) {
__get = reg_function;
+ scope->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (zend_string_equals_literal(lowercase_name, ZEND_SET_FUNC_NAME)) {
__set = reg_function;
+ scope->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (zend_string_equals_literal(lowercase_name, ZEND_UNSET_FUNC_NAME)) {
__unset = reg_function;
+ scope->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (zend_string_equals_literal(lowercase_name, ZEND_ISSET_FUNC_NAME)) {
__isset = reg_function;
+ scope->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (zend_string_equals_literal(lowercase_name, ZEND_DEBUGINFO_FUNC_NAME)) {
__debugInfo = reg_function;
} else {
"public visibility and cannot be static");
}
ce->__get = (zend_function *) op_array;
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (zend_string_equals_literal(lcname, ZEND_SET_FUNC_NAME)) {
if (!is_public || is_static) {
zend_error(E_WARNING, "The magic method __set() must have "
"public visibility and cannot be static");
}
ce->__set = (zend_function *) op_array;
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (zend_string_equals_literal(lcname, ZEND_UNSET_FUNC_NAME)) {
if (!is_public || is_static) {
zend_error(E_WARNING, "The magic method __unset() must have "
"public visibility and cannot be static");
}
ce->__unset = (zend_function *) op_array;
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (zend_string_equals_literal(lcname, ZEND_ISSET_FUNC_NAME)) {
if (!is_public || is_static) {
zend_error(E_WARNING, "The magic method __isset() must have "
"public visibility and cannot be static");
}
ce->__isset = (zend_function *) op_array;
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (zend_string_equals_literal(lcname, ZEND_TOSTRING_FUNC_NAME)) {
if (!is_public || is_static) {
zend_error(E_WARNING, "The magic method __toString() must have "
#define ZEND_ACC_RETURN_REFERENCE 0x4000000
#define ZEND_ACC_DONE_PASS_TWO 0x8000000
+/* class has magic methods __get/__set/__unset/__isset that use guards */
+#define ZEND_ACC_USE_GUARDS 0x1000000
+
/* function has arguments with type hinting */
#define ZEND_ACC_HAS_TYPE_HINTS 0x10000000
/* The verification will be done in runtime by ZEND_VERIFY_ABSTRACT_CLASS */
zend_verify_abstract_class(ce);
}
- ce->ce_flags |= parent_ce->ce_flags & ZEND_HAS_STATIC_IN_METHODS;
+ ce->ce_flags |= parent_ce->ce_flags & (ZEND_HAS_STATIC_IN_METHODS | ZEND_ACC_USE_GUARDS);
}
/* }}} */
ce->destructor = fe; fe->common.fn_flags |= ZEND_ACC_DTOR;
} else if (!strncmp(mname->val, ZEND_GET_FUNC_NAME, mname->len)) {
ce->__get = fe;
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (!strncmp(mname->val, ZEND_SET_FUNC_NAME, mname->len)) {
ce->__set = fe;
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (!strncmp(mname->val, ZEND_CALL_FUNC_NAME, mname->len)) {
ce->__call = fe;
} else if (!strncmp(mname->val, ZEND_UNSET_FUNC_NAME, mname->len)) {
ce->__unset = fe;
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (!strncmp(mname->val, ZEND_ISSET_FUNC_NAME, mname->len)) {
ce->__isset = fe;
+ ce->ce_flags |= ZEND_ACC_USE_GUARDS;
} else if (!strncmp(mname->val, ZEND_CALLSTATIC_FUNC_NAME, mname->len)) {
ce->__callstatic = fe;
} else if (!strncmp(mname->val, ZEND_TOSTRING_FUNC_NAME, mname->len)) {
static zend_long *zend_get_property_guard(zend_object *zobj, zend_string *member) /* {{{ */
{
+ HashTable *guards;
zend_long stub, *guard;
+ zval tmp;
- if (!zobj->guards) {
- ALLOC_HASHTABLE(zobj->guards);
- zend_hash_init(zobj->guards, 8, NULL, zend_property_guard_dtor, 0);
- } else if ((guard = (zend_long *)zend_hash_find_ptr(zobj->guards, member)) != NULL) {
- return guard;
+ ZEND_ASSERT(GC_FLAGS(zobj) & IS_OBJ_USE_GUARDS);
+ if (GC_FLAGS(zobj) & IS_OBJ_HAS_GUARDS) {
+ guards = Z_PTR(zobj->properties_table[zobj->ce->default_properties_count]);
+ ZEND_ASSERT(guards != NULL);
+ if ((guard = (zend_long *)zend_hash_find_ptr(guards, member)) != NULL) {
+ return guard;
+ }
+ } else {
+ ALLOC_HASHTABLE(guards);
+ zend_hash_init(guards, 8, NULL, zend_property_guard_dtor, 0);
+ ZVAL_PTR(&tmp, guards);
+ Z_PTR(zobj->properties_table[zobj->ce->default_properties_count]) = guards;
+ GC_FLAGS(zobj) |= IS_OBJ_HAS_GUARDS;
}
stub = 0;
- return (zend_long *)zend_hash_add_mem(zobj->guards, member, &stub, sizeof(zend_ulong));
+ return (zend_long *)zend_hash_add_mem(guards, member, &stub, sizeof(zend_ulong));
}
/* }}} */
GC_TYPE_INFO(object) = IS_OBJECT;
object->ce = ce;
object->properties = NULL;
- object->guards = NULL;
zend_objects_store_put(object);
if (EXPECTED(ce->default_properties_count != 0)) {
zval *p = object->properties_table;
p++;
} while (p != end);
}
+ if (ce->ce_flags & ZEND_ACC_USE_GUARDS) {
+ GC_FLAGS(object) |= IS_OBJ_USE_GUARDS;
+ ZVAL_UNDEF(&object->properties_table[ce->default_properties_count]);
+ Z_PTR(object->properties_table[ce->default_properties_count]) = NULL;
+ }
}
ZEND_API void zend_object_std_dtor(zend_object *object)
{
int i, count;
- if (object->guards) {
- zend_hash_destroy(object->guards);
- FREE_HASHTABLE(object->guards);
- }
if (object->properties) {
zend_array_destroy(object->properties);
FREE_HASHTABLE(object->properties);
for (i = 0; i < count; i++) {
i_zval_ptr_dtor(&object->properties_table[i] ZEND_FILE_LINE_CC);
}
+ if (GC_FLAGS(object) & IS_OBJ_HAS_GUARDS) {
+ HashTable *guards = Z_PTR(object->properties_table[count]);
+
+ ZEND_ASSERT(guards != NULL);
+ zend_hash_destroy(guards);
+ FREE_HASHTABLE(guards);
+ }
}
ZEND_API void zend_objects_destroy_object(zend_object *object)
ZEND_API zend_object *zend_objects_new(zend_class_entry *ce)
{
- zend_object *object = emalloc(sizeof(zend_object) + sizeof(zval) * (ce->default_properties_count - 1));
+ zend_object *object = emalloc(sizeof(zend_object) + zend_object_properties_size(ce));
zend_object_std_init(object, ce);
object->handlers = &std_object_handlers;
#define ZEND_OBJECTS_API_H
#include "zend.h"
+#include "zend_compile.h"
#define OBJ_BUCKET_INVALID (1<<0)
}
}
+static zend_always_inline size_t zend_object_properties_size(zend_class_entry *ce)
+{
+ return sizeof(zval) *
+ (ce->default_properties_count -
+ ((ce->ce_flags & ZEND_ACC_USE_GUARDS) ? 0 : 1));
+}
+
#endif /* ZEND_OBJECTS_H */
/*
zend_class_entry *ce;
const zend_object_handlers *handlers;
HashTable *properties;
- HashTable *guards; /* protects from __get/__set ... recursion */
zval properties_table[1];
};
#define IS_OBJ_APPLY_COUNT 0x07
#define IS_OBJ_DESTRUCTOR_CALLED (1<<3)
#define IS_OBJ_FREE_CALLED (1<<4)
+#define IS_OBJ_USE_GUARDS (1<<5)
+#define IS_OBJ_HAS_GUARDS (1<<6)
#define Z_OBJ_APPLY_COUNT(zval) \
(Z_GC_FLAGS(zval) & IS_OBJ_APPLY_COUNT)
{
php_date_obj *intern;
- intern = ecalloc(1, sizeof(php_date_obj) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_date_obj) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->std, class_type);
if (init_props) {
{
php_timezone_obj *intern;
- intern = ecalloc(1, sizeof(php_timezone_obj) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_timezone_obj) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->std, class_type);
if (init_props) {
{
php_interval_obj *intern;
- intern = ecalloc(1, sizeof(php_interval_obj) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_interval_obj) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->std, class_type);
if (init_props) {
{
php_period_obj *intern;
- intern = ecalloc(1, sizeof(php_period_obj) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_period_obj) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->std, class_type);
if (init_props) {
static dom_object* dom_objects_set_class(zend_class_entry *class_type, zend_bool hash_copy) /* {{{ */
{
- dom_object *intern = ecalloc(1, sizeof(dom_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ dom_object *intern = ecalloc(1, sizeof(dom_object) + zend_object_properties_size(class_type));
zend_class_entry *base_class = class_type;
while (base_class->type != ZEND_INTERNAL_CLASS && base_class->parent != NULL) {
/* {{{ zend_object_value dom_xpath_objects_new(zend_class_entry *class_type) */
zend_object *dom_xpath_objects_new(zend_class_entry *class_type)
{
- dom_xpath_object *intern = ecalloc(1, sizeof(dom_xpath_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ dom_xpath_object *intern = ecalloc(1, sizeof(dom_xpath_object) + zend_object_properties_size(class_type));
ALLOC_HASHTABLE(intern->registered_phpfunctions);
zend_hash_init(intern->registered_phpfunctions, 0, NULL, ZVAL_PTR_DTOR, 0);
{
finfo_object *intern;
- intern = ecalloc(1, sizeof(finfo_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(finfo_object) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->zo, class_type);
object_properties_init(&intern->zo, class_type);
static inline zend_object *gmp_create_object_ex(zend_class_entry *ce, mpz_ptr *gmpnum_target) /* {{{ */
{
- gmp_object *intern = emalloc(sizeof(gmp_object)
- + sizeof(zval) * (ce->default_properties_count - 1));
+ gmp_object *intern = emalloc(sizeof(gmp_object) + zend_object_properties_size(ce));
zend_object_std_init(&intern->std, ce);
object_properties_init(&intern->std, ce);
{
Collator_object* intern;
- intern = ecalloc(1, sizeof(Collator_object) + sizeof(zval) * (ce->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(Collator_object) + zend_object_properties_size(ce));
intl_error_init(COLLATOR_ERROR_P(intern));
zend_object_std_init(&intern->zo, ce );
object_properties_init(&intern->zo, ce);
static zend_object *php_converter_object_ctor(zend_class_entry *ce, php_converter_object **pobjval) {
php_converter_object *objval;
- objval = ecalloc(1, sizeof(php_converter_object) + sizeof(zval) * (ce->default_properties_count - 1));
+ objval = ecalloc(1, sizeof(php_converter_object) + zend_object_properties_size(ce));
zend_object_std_init(&objval->obj, ce );
intl_error_init(&(objval->error));
{
IntlDateFormatter_object* intern;
- intern = ecalloc( 1, sizeof(IntlDateFormatter_object) + sizeof(zval) * (ce->default_properties_count - 1) );
+ intern = ecalloc( 1, sizeof(IntlDateFormatter_object) + zend_object_properties_size(ce));
dateformat_data_init( &intern->datef_data );
zend_object_std_init( &intern->zo, ce );
object_properties_init(&intern->zo, ce);
{
NumberFormatter_object* intern;
- intern = ecalloc( 1, sizeof(NumberFormatter_object) + sizeof(zval) * (ce->default_properties_count - 1) );
+ intern = ecalloc( 1, sizeof(NumberFormatter_object) + zend_object_properties_size(ce));
formatter_data_init( &intern->nf_data );
zend_object_std_init( &intern->zo, ce );
object_properties_init(&intern->zo, ce);
{
MessageFormatter_object* intern;
- intern = ecalloc( 1, sizeof(MessageFormatter_object) + sizeof(zval) * (ce->default_properties_count - 1));
+ intern = ecalloc( 1, sizeof(MessageFormatter_object) + zend_object_properties_size(ce));
msgformat_data_init( &intern->mf_data );
zend_object_std_init( &intern->zo, ce );
object_properties_init(&intern->zo, ce);
{
ResourceBundle_object *rb;
- rb = ecalloc( 1, sizeof(ResourceBundle_object) + sizeof(zval) * (ce->default_properties_count - 1) );
+ rb = ecalloc( 1, sizeof(ResourceBundle_object) + zend_object_properties_size(ce));
zend_object_std_init( &rb->zend, ce );
object_properties_init( &rb->zend, ce);
{
Spoofchecker_object* intern;
- intern = ecalloc(1, sizeof(Spoofchecker_object) + sizeof(zval) * (ce->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(Spoofchecker_object) + zend_object_properties_size(ce));
intl_error_init(SPOOFCHECKER_ERROR_P(intern));
zend_object_std_init(&intern->zo, ce);
object_properties_init(&intern->zo, ce);
{
Transliterator_object* intern;
- intern = ecalloc( 1, sizeof( Transliterator_object ) + sizeof(zval) * (ce->default_properties_count - 1));
+ intern = ecalloc( 1, sizeof( Transliterator_object ) + zend_object_properties_size(ce));
zend_object_std_init( &intern->zo, ce );
object_properties_init( &intern->zo, ce );
zend_class_entry *mysqli_base_class;
zend_object_handlers *handlers;
- intern = ecalloc(1, sizeof(mysqli_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(mysqli_object) + zend_object_properties_size(class_type));
mysqli_base_class = class_type;
while (mysqli_base_class->type != ZEND_INTERNAL_CLASS &&
{
pdo_dbh_object_t *dbh;
- dbh = ecalloc(1, sizeof(pdo_dbh_object_t) + sizeof(zval) * (ce->default_properties_count - 1));
+ dbh = ecalloc(1, sizeof(pdo_dbh_object_t) + zend_object_properties_size(ce));
zend_object_std_init(&dbh->std, ce);
object_properties_init(&dbh->std, ce);
rebuild_object_properties(&dbh->std);
pdo_stmt_t *stmt;
pdo_stmt_t *old_stmt;
- stmt = ecalloc(1, sizeof(pdo_stmt_t) + sizeof(zval) * (Z_OBJCE_P(zobject)->default_properties_count - 1));
+ stmt = ecalloc(1, sizeof(pdo_stmt_t) + zend_object_properties_size(Z_OBJCE_P(zobject)));
zend_object_std_init(&stmt->std, Z_OBJCE_P(zobject));
object_properties_init(&stmt->std, Z_OBJCE_P(zobject));
{
pdo_stmt_t *stmt;
- stmt = ecalloc(1, sizeof(pdo_stmt_t) + sizeof(zval) * (ce->default_properties_count - 1));
+ stmt = ecalloc(1, sizeof(pdo_stmt_t) + zend_object_properties_size(ce));
zend_object_std_init(&stmt->std, ce);
object_properties_init(&stmt->std, ce);
{
reflection_object *intern;
- intern = ecalloc(1, sizeof(reflection_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(reflection_object) + zend_object_properties_size(class_type));
intern->zo.ce = class_type;
zend_object_std_init(&intern->zo, class_type);
}
GET_REFLECTION_OBJECT_PTR(ce);
- RETURN_LONG(ce->ce_flags & ~ZEND_ACC_CONSTANTS_UPDATED);
+ RETURN_LONG(ce->ce_flags & ~(ZEND_ACC_CONSTANTS_UPDATED|ZEND_ACC_USE_GUARDS));
}
/* }}} */
zend_class_entry *parent = ce;
int inherited = 0;
- intern = ecalloc(1, sizeof(php_sxe_object) + sizeof(zval) * (parent->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_sxe_object) + zend_object_properties_size(parent));
intern->iter.type = SXE_ITER_NONE;
intern->iter.nsprefix = NULL;
php_snmp_object *intern;
/* Allocate memory for it */
- intern = ecalloc(1, sizeof(php_snmp_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_snmp_object) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->zo, class_type);
object_properties_init(&intern->zo, class_type);
zend_class_entry *parent = class_type;
int inherited = 0;
- intern = ecalloc(1, sizeof(spl_array_object) + sizeof(zval) * (parent->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(spl_array_object) + zend_object_properties_size(parent));
zend_object_std_init(&intern->std, class_type);
object_properties_init(&intern->std, class_type);
{
spl_filesystem_object *intern;
- intern = ecalloc(1, sizeof(spl_filesystem_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(spl_filesystem_object) + zend_object_properties_size(class_type));
/* intern->type = SPL_FS_INFO; done by set 0 */
intern->file_class = spl_ce_SplFileObject;
intern->info_class = spl_ce_SplFileInfo;
zend_class_entry *parent = class_type;
int inherited = 0;
- intern = ecalloc(1, sizeof(spl_dllist_object) + sizeof(zval) * (parent->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(spl_dllist_object) + zend_object_properties_size(parent));
zend_object_std_init(&intern->std, class_type);
object_properties_init(&intern->std, class_type);
zend_class_entry *parent = class_type;
int inherited = 0;
- intern = ecalloc(1, sizeof(spl_fixedarray_object) + (sizeof(zval) * parent->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(spl_fixedarray_object) + zend_object_properties_size(parent));
zend_object_std_init(&intern->std, class_type);
object_properties_init(&intern->std, class_type);
zend_class_entry *parent = class_type;
int inherited = 0;
- intern = ecalloc(1, sizeof(spl_heap_object) + sizeof(zval) * (parent->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(spl_heap_object) + zend_object_properties_size(parent));
zend_object_std_init(&intern->std, class_type);
object_properties_init(&intern->std, class_type);
{
spl_recursive_it_object *intern;
- intern = ecalloc(1, sizeof(spl_recursive_it_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(spl_recursive_it_object) + zend_object_properties_size(class_type));
if (init_prefix) {
smart_str_appendl(&intern->prefix[0], "", 0);
{
spl_dual_it_object *intern;
- intern = ecalloc(1, sizeof(spl_dual_it_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(spl_dual_it_object) + zend_object_properties_size(class_type));
intern->dit_type = DIT_Unknown;
zend_object_std_init(&intern->std, class_type);
spl_SplObjectStorage *intern;
zend_class_entry *parent = class_type;
- intern = emalloc(sizeof(spl_SplObjectStorage) + sizeof(zval) * (parent->default_properties_count - 1));
+ intern = emalloc(sizeof(spl_SplObjectStorage) + zend_object_properties_size(parent));
memset(intern, 0, sizeof(spl_SplObjectStorage) - sizeof(zval));
intern->pos = INVALID_IDX;
php_sqlite3_db_object *intern;
/* Allocate memory for it */
- intern = ecalloc(1, sizeof(php_sqlite3_db_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_sqlite3_db_object) + zend_object_properties_size(class_type));
/* Need to keep track of things to free */
zend_llist_init(&(intern->free_list), sizeof(php_sqlite3_free_list *), (llist_dtor_func_t)php_sqlite3_free_list_dtor, 0);
php_sqlite3_stmt *intern;
/* Allocate memory for it */
- intern = ecalloc(1, sizeof(php_sqlite3_stmt) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_sqlite3_stmt) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->zo, class_type);
object_properties_init(&intern->zo, class_type);
php_sqlite3_result *intern;
/* Allocate memory for it */
- intern = ecalloc(1, sizeof(php_sqlite3_result) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(php_sqlite3_result) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->zo, class_type);
object_properties_init(&intern->zo, class_type);
{
PHPTidyObj *intern;
- intern = ecalloc(1, sizeof(PHPTidyObj) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(PHPTidyObj) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->std, class_type);
object_properties_init(&intern->std, class_type);
{
xmlreader_object *intern;
- intern = ecalloc(1, sizeof(xmlreader_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(xmlreader_object) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->std, class_type);
object_properties_init(&intern->std, class_type);
intern->prop_handler = &xmlreader_prop_handlers;
{
ze_xmlwriter_object *intern;
- intern = ecalloc(1, sizeof(ze_xmlwriter_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(ze_xmlwriter_object) + zend_object_properties_size(class_type));
zend_object_std_init(&intern->std, class_type);
object_properties_init(&intern->std, class_type);
intern->std.handlers = &xmlwriter_object_handlers;
{
xsl_object *intern;
- intern = ecalloc(1, sizeof(xsl_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(xsl_object) + zend_object_properties_size(class_type));
intern->securityPrefs = XSL_SECPREF_DEFAULT;
zend_object_std_init(&intern->std, class_type);
{
ze_zip_object *intern;
- intern = ecalloc(1, sizeof(ze_zip_object) + sizeof(zval) * (class_type->default_properties_count - 1));
+ intern = ecalloc(1, sizeof(ze_zip_object) + zend_object_properties_size(class_type));
intern->prop_handler = &zip_prop_handlers;
zend_object_std_init(&intern->zo, class_type);
object_properties_init(&intern->zo, class_type);