Deleted Added
full compact
php_reflection.c (e656b829) php_reflection.c (345e0255)
1/*
2 +----------------------------------------------------------------------+
3 | Zend Engine |
4 +----------------------------------------------------------------------+
5 | Copyright (c) 1998-2004 Zend Technologies Ltd. (http://www.zend.com) |
6 +----------------------------------------------------------------------+
7 | This source file is subject to version 2.00 of the Zend license, |
8 | that is bundled with this package in the file LICENSE, and is |

--- 191 unchanged lines hidden (view full) ---

200{
201 reflection_object *intern = (reflection_object *) object;
202 reflection_object **intern_clone = (reflection_object **) object_clone;
203
204 *intern_clone = emalloc(sizeof(reflection_object));
205 (*intern_clone)->zo.ce = intern->zo.ce;
206 (*intern_clone)->zo.in_get = 0;
207 (*intern_clone)->zo.in_set = 0;
1/*
2 +----------------------------------------------------------------------+
3 | Zend Engine |
4 +----------------------------------------------------------------------+
5 | Copyright (c) 1998-2004 Zend Technologies Ltd. (http://www.zend.com) |
6 +----------------------------------------------------------------------+
7 | This source file is subject to version 2.00 of the Zend license, |
8 | that is bundled with this package in the file LICENSE, and is |

--- 191 unchanged lines hidden (view full) ---

200{
201 reflection_object *intern = (reflection_object *) object;
202 reflection_object **intern_clone = (reflection_object **) object_clone;
203
204 *intern_clone = emalloc(sizeof(reflection_object));
205 (*intern_clone)->zo.ce = intern->zo.ce;
206 (*intern_clone)->zo.in_get = 0;
207 (*intern_clone)->zo.in_set = 0;
208 (*intern_clone)->zo.in_unset = 0;
209 (*intern_clone)->zo.in_isset = 0;
208 ALLOC_HASHTABLE((*intern_clone)->zo.properties);
209 (*intern_clone)->ptr = intern->ptr;
210 (*intern_clone)->free_ptr = intern->free_ptr;
211 (*intern_clone)->obj = intern->obj;
212 if (intern->obj) {
213 zval_add_ref(&intern->obj);
214 }
215}
216
217static zend_object_value reflection_objects_new(zend_class_entry *class_type TSRMLS_DC)
218{
219 zval tmp;
220 zend_object_value retval;
221 reflection_object *intern;
222
223 intern = emalloc(sizeof(reflection_object));
224 intern->zo.ce = class_type;
225 intern->zo.in_get = 0;
226 intern->zo.in_set = 0;
210 ALLOC_HASHTABLE((*intern_clone)->zo.properties);
211 (*intern_clone)->ptr = intern->ptr;
212 (*intern_clone)->free_ptr = intern->free_ptr;
213 (*intern_clone)->obj = intern->obj;
214 if (intern->obj) {
215 zval_add_ref(&intern->obj);
216 }
217}
218
219static zend_object_value reflection_objects_new(zend_class_entry *class_type TSRMLS_DC)
220{
221 zval tmp;
222 zend_object_value retval;
223 reflection_object *intern;
224
225 intern = emalloc(sizeof(reflection_object));
226 intern->zo.ce = class_type;
227 intern->zo.in_get = 0;
228 intern->zo.in_set = 0;
229 intern->zo.in_unset = 0;
230 intern->zo.in_isset = 0;
227 intern->ptr = NULL;
228 intern->obj = NULL;
229 intern->free_ptr = 0;
230
231 ALLOC_HASHTABLE(intern->zo.properties);
232 zend_hash_init(intern->zo.properties, 0, NULL, ZVAL_PTR_DTOR, 0);
233 zend_hash_copy(intern->zo.properties, &class_type->default_properties, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
234 retval.handle = zend_objects_store_put(intern, NULL, reflection_free_objects_storage, reflection_objects_clone TSRMLS_CC);

--- 3809 unchanged lines hidden ---
231 intern->ptr = NULL;
232 intern->obj = NULL;
233 intern->free_ptr = 0;
234
235 ALLOC_HASHTABLE(intern->zo.properties);
236 zend_hash_init(intern->zo.properties, 0, NULL, ZVAL_PTR_DTOR, 0);
237 zend_hash_copy(intern->zo.properties, &class_type->default_properties, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *));
238 retval.handle = zend_objects_store_put(intern, NULL, reflection_free_objects_storage, reflection_objects_clone TSRMLS_CC);

--- 3809 unchanged lines hidden ---