cvs: ZendEngine2 / zend_builtin_functions.c php-src NEWS

From: Date: Fri, 28 Oct 2005 20:08:30 +0000
Subject: cvs: ZendEngine2 / zend_builtin_functions.c php-src NEWS
Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-4295@lists.php.net to get a copy of this message
sebastian Fri Oct 28 16:08:30 2005 EDT Modified files: /php-src NEWS /ZendEngine2 zend_builtin_functions.c Log: Add an additional field $frame['object'] to the result array of debug_backtrace() that contains a reference to the respective object when the frame was called from an object. Patch has been reviewed by Andi, Zeev, and Marcus. I will coordinate with Ilia on merging it to the PHP_5_1 branch after PHP 5.1.0 has been released. http://cvs.php.net/diff.php/php-src/NEWS?r1=1.2072&r2=1.2073&ty=u Index: php-src/NEWS diff -u php-src/NEWS:1.2072 php-src/NEWS:1.2073 --- php-src/NEWS:1.2072 Thu Oct 20 15:35:14 2005 +++ php-src/NEWS Fri Oct 28 16:08:05 2005 @@ -22,4 +22,7 @@ the part of haystack before or after first occurence of needle. (Johannes) - Added possibility to check in which extension an internal function was defined using reflection API. (Johannes) +- Added an additional field $frame['object'] to the result array of + debug_backtrace() that contains a reference to the respective object when the + frame was called from an object. (Sebastian) - Fixed bug #34286 (__toString() behavior is inconsistent). (Marcus) http://cvs.php.net/diff.php/ZendEngine2/zend_builtin_functions.c?r1=1.294&r2=1.295&ty=u Index: ZendEngine2/zend_builtin_functions.c diff -u ZendEngine2/zend_builtin_functions.c:1.294 ZendEngine2/zend_builtin_functions.c:1.295 --- ZendEngine2/zend_builtin_functions.c:1.294 Fri Sep 9 02:47:14 2005 +++ ZendEngine2/zend_builtin_functions.c Fri Oct 28 16:08:25 2005 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend_builtin_functions.c,v 1.294 2005/09/09 06:47:14 dmitry Exp $ */ +/* $Id: zend_builtin_functions.c,v 1.295 2005/10/28 20:08:25 sebastian Exp $ */ #include "zend.h" #include "zend_API.h" @@ -2005,6 +2005,9 @@ dup = zend_get_object_classname(ptr->object, &class_name, &class_name_len TSRMLS_CC); add_assoc_text_ex(stack_frame, "class", sizeof("class"), class_name, dup); } + add_assoc_zval_ex(stack_frame, "object", sizeof("object"), ptr->object); + ptr->object->refcount++; + add_assoc_ascii_string_ex(stack_frame, "type", sizeof("type"), "->", 1); } else if (ptr->function_state.function->common.scope) { add_assoc_textl_ex(stack_frame, "class", sizeof("class"), ptr->function_state.function->common.scope->name, ptr->function_state.function->common.scope->name_length, 1);

« previous php.zend-engine.cvs (#4295) next »