From: Marcus Boerger Date: Wed, 10 May 2006 19:41:34 +0000 (+0000) Subject: - ze1 cleanup (bjori) /thx X-Git-Tag: php-5.2.0RC1~607 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0dacd6d5c00eed33180ae5de7055bb3c1d00bd30;p=php - ze1 cleanup (bjori) /thx --- diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index 6a8104ea9b..07a0affa07 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -716,7 +716,6 @@ static inline void zend_assign_to_variable(znode *result, znode *op1, znode *op2 } if(Z_TYPE_P(variable_ptr) == IS_OBJECT && Z_OBJ_HANDLER_P(variable_ptr, set)) { - /* TODO? ze1_compatibility_mode support */ Z_OBJ_HANDLER_P(variable_ptr, set)(variable_ptr_ptr, value TSRMLS_CC); goto done_setting_var; } diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c index 07262a8d49..fba049be93 100644 --- a/ext/dom/php_dom.c +++ b/ext/dom/php_dom.c @@ -69,7 +69,6 @@ zend_class_entry *dom_xpath_class_entry; zend_class_entry *dom_namespace_node_class_entry; zend_object_handlers dom_object_handlers; -zend_object_handlers dom_ze1_object_handlers; static HashTable classes; @@ -451,13 +450,6 @@ zend_object_value dom_objects_store_clone_obj(zval *zobject TSRMLS_DC) return retval; } -zend_object_value dom_objects_ze1_clone_obj(zval *zobject TSRMLS_DC) -{ - php_error(E_ERROR, "Cannot clone object of class %s due to 'zend.ze1_compatibility_mode'", Z_OBJCE_P(zobject)->name); - /* Return zobject->value.obj just to satisfy compiler */ - return zobject->value.obj; -} - static zend_function_entry dom_functions[] = { PHP_FE(dom_import_simplexml, NULL) {NULL, NULL, NULL} @@ -503,13 +495,6 @@ PHP_MINIT_FUNCTION(dom) dom_object_handlers.clone_obj = dom_objects_store_clone_obj; dom_object_handlers.has_property = dom_property_exists; - memcpy(&dom_ze1_object_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); - dom_ze1_object_handlers.read_property = dom_read_property; - dom_ze1_object_handlers.write_property = dom_write_property; - dom_object_handlers.get_property_ptr_ptr = dom_get_property_ptr_ptr; - dom_ze1_object_handlers.clone_obj = dom_objects_ze1_clone_obj; - dom_ze1_object_handlers.has_property = dom_property_exists; - zend_hash_init(&classes, 0, NULL, NULL, 1); INIT_CLASS_ENTRY(ce, "DOMException", php_dom_domexception_class_functions); diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index a2cb8e99ba..fffd049e49 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -1682,38 +1682,6 @@ static zend_object_handlers sxe_object_handlers = { sxe_count_elements }; -static zend_object_handlers sxe_ze1_object_handlers = { - ZEND_OBJECTS_STORE_HANDLERS, - sxe_property_read, - sxe_property_write, - sxe_dimension_read, - sxe_dimension_write, - sxe_property_get_adr, - sxe_get_value, /* get */ - NULL, - sxe_property_exists, - sxe_property_delete, - sxe_dimension_exists, - sxe_dimension_delete, - sxe_properties_get, - NULL, /* zend_get_std_object_handlers()->get_method,*/ - NULL, /* zend_get_std_object_handlers()->call_method,*/ - NULL, /* zend_get_std_object_handlers()->get_constructor, */ - NULL, /* zend_get_std_object_handlers()->get_class_entry,*/ - NULL, /* zend_get_std_object_handlers()->get_class_name,*/ - sxe_objects_compare, - sxe_object_cast, - sxe_count_elements -}; - -static zend_object_value sxe_object_ze1_clone(zval *zobject TSRMLS_DC) -{ - php_error(E_ERROR, "Cannot clone object of class %s due to 'zend.ze1_compatibility_mode'", Z_OBJCE_P(zobject)->name); - /* Return zobject->value.obj just to satisfy compiler */ - /* FIXME: Should not be a fatal */ - return zobject->value.obj; -} - /* {{{ sxe_object_clone() */ static void @@ -2270,12 +2238,6 @@ PHP_MINIT_FUNCTION(simplexml) sxe_object_handlers.get_class_entry = zend_get_std_object_handlers()->get_class_entry; sxe_object_handlers.get_class_name = zend_get_std_object_handlers()->get_class_name; - sxe_ze1_object_handlers.get_method = zend_get_std_object_handlers()->get_method; - sxe_ze1_object_handlers.get_constructor = zend_get_std_object_handlers()->get_constructor; - sxe_ze1_object_handlers.get_class_entry = zend_get_std_object_handlers()->get_class_entry; - sxe_ze1_object_handlers.get_class_name = zend_get_std_object_handlers()->get_class_name; - sxe_ze1_object_handlers.clone_obj = sxe_object_ze1_clone; - #ifdef HAVE_SPL if (zend_get_module_started("spl") == SUCCESS) { PHP_MINIT(spl_sxe)(INIT_FUNC_ARGS_PASSTHRU); diff --git a/php.ini-dist b/php.ini-dist index ffbaae89b6..26fee87451 100644 --- a/php.ini-dist +++ b/php.ini-dist @@ -71,9 +71,6 @@ ; Enable the PHP scripting language engine under Apache. engine = On -; Enable compatibility mode with Zend Engine 1 (PHP 4.x) -zend.ze1_compatibility_mode = Off - ; Allow the tags are recognized. ; NOTE: Using short tags should be avoided when developing applications or ; libraries that are meant for redistribution, or deployment on PHP diff --git a/php.ini-recommended b/php.ini-recommended index 081743db65..8d0eeae2c9 100644 --- a/php.ini-recommended +++ b/php.ini-recommended @@ -129,9 +129,6 @@ ; Enable the PHP scripting language engine under Apache. engine = On -; Enable compatibility mode with Zend Engine 1 (PHP 4.x) -zend.ze1_compatibility_mode = Off - ; Allow the tags are recognized. ; NOTE: Using short tags should be avoided when developing applications or ; libraries that are meant for redistribution, or deployment on PHP