dmitry Fri Aug 12 07:29:35 2005 EDT
Modified files:
/ZendEngine2 zend.c zend.h zend_API.c zend_API.h zend_compile.c
zend_compile.h zend_exceptions.c zend_exceptions.h
zend_interfaces.c zend_interfaces.h
zend_object_handlers.c zend_operators.c
zend_reflection_api.c zend_reflection_api.h
/php-src/ext/dom attr.c cdatasection.c characterdata.c comment.c
document.c documentfragment.c dom_iterators.c
domexception.c domimplementation.c element.c
entityreference.c namednodemap.c node.c nodelist.c
php_dom.c processinginstruction.c text.c xpath.c
/php-src/ext/pdo pdo.c pdo_dbh.c pdo_stmt.c
/php-src/ext/simplexml simplexml.c
/php-src/ext/spl php_spl.c spl_array.c spl_directory.c
spl_iterators.c
Log:
Unicode support
http://cvs.php.net/diff.php/ZendEngine2/zend.c?r1=1.310&r2=1.311&ty=u
Index: ZendEngine2/zend.c
diff -u ZendEngine2/zend.c:1.310 ZendEngine2/zend.c:1.311
--- ZendEngine2/zend.c:1.310 Thu Aug 11 22:11:03 2005
+++ ZendEngine2/zend.c Fri Aug 12 07:29:24 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend.c,v 1.310 2005/08/12 02:11:03 iliaa Exp $ */
+/* $Id: zend.c,v 1.311 2005/08/12 11:29:24 dmitry Exp $ */
#include "zend.h"
#include "zend_extensions.h"
@@ -755,6 +755,27 @@
u_charsToUChars(func->common.function_name, uname, len);
func->common.function_name = (char*)uname;
}
+ if (func->common.arg_info) {
+ zend_arg_info *args;
+ int n = func->common.num_args;
+
+ args = malloc((n + 1) * sizeof(zend_arg_info));
+ memcpy(args, func->common.arg_info, (n + 1) * sizeof(zend_arg_info));
+ while (n > 0) {
+ --n;
+ if (args[n].name) {
+ UChar *uname = malloc(UBYTES(args[n].name_len));
+ u_charsToUChars(args[n].name, uname, args[n].name_len);
+ args[n].name = (char*)uname;
+ }
+ if (args[n].class_name) {
+ UChar *uname = malloc(UBYTES(args[n].class_name_len));
+ u_charsToUChars(args[n].class_name, uname, args[n].class_name_len);
+ args[n].class_name = (char*)uname;
+ }
+ }
+ func->common.arg_info = args;
+ }
}
static void property_info_to_unicode(zend_property_info *info)
@@ -794,17 +815,41 @@
static void class_to_unicode(zend_class_entry **ce)
{
zend_class_entry *new_ce = malloc(sizeof(zend_class_entry));
- zend_function tmp_func;
zend_constant tmp_const;
zend_property_info tmp_info;
zval* tmp_zval;
memcpy(new_ce, *ce, sizeof(zend_class_entry));
+ (*ce)->u_twin = new_ce;
+
+ /* Convert name to unicode */
+ if (new_ce->name) {
+ UChar *uname = malloc(UBYTES(new_ce->name_length+1));
+
+ u_charsToUChars(new_ce->name, uname, new_ce->name_length+1);
+ new_ce->name = (char*)uname;
+ }
/* Copy methods */
zend_u_hash_init_ex(&new_ce->function_table, (*ce)->function_table.nNumOfElements, NULL, ZEND_U_FUNCTION_DTOR, 1, 1, 0);
- zend_hash_copy(&new_ce->function_table, &(*ce)->function_table, (copy_ctor_func_t) function_to_unicode, &tmp_func, sizeof(zend_function));
+ {
+ Bucket *p = (*ce)->function_table.pListHead;
+ while (p != NULL) {
+ zend_function *src = (zend_function*)p->pData;
+ zend_function *target;
+ zend_function tmp_func = *src;
+
+ function_to_unicode(&tmp_func);
+
+ zend_hash_add(&new_ce->function_table, p->key.u.string, p->nKeyLength, &tmp_func, sizeof(zend_function), (void**)&target);
+ src->common.u_twin = target;
+ p = p->pListNext;
+ }
+ }
+/*
+ zend_hash_copy(&new_ce->function_table, &(*ce)->function_table, (copy_ctor_func_t) function_to_unicode, &tmp_func, sizeof(zend_function));
+*/
/* Copy constants */
zend_u_hash_init_ex(&new_ce->constants_table, (*ce)->constants_table.nNumOfElements, NULL, (*ce)->constants_table.pDestructor, 1, 1, 0);
zend_hash_copy(&new_ce->constants_table, &(*ce)->constants_table, (copy_ctor_func_t) zval_ptr_to_unicode, &tmp_const, sizeof(zend_constant));
@@ -827,20 +872,14 @@
static void fix_classes(HashTable *ht) {
Bucket *p = ht->pListHead;
+ Bucket *q;
/* Fix parent classes */
while (p != NULL) {
zend_class_entry *ce = *(zend_class_entry**)p->pData;
- zend_class_entry **parent;
if (ce->parent) {
- char *lcname = do_alloca(ce->parent->name_length+1);
-
- zend_str_tolower_copy(lcname, ce->parent->name, ce->parent->name_length);
- if (zend_hash_find(ht, lcname, ce->parent->name_length+1, (void**)&parent) == SUCCESS) {
- ce->parent = *parent;
- }
- free_alloca(lcname);
+ ce->parent = ce->parent->u_twin;
}
if (ce->num_interfaces > 0 && ce->interfaces) {
int i = sizeof(zend_class_entry*)*ce->num_interfaces;
@@ -850,30 +889,48 @@
memcpy(new_interfaces, ce->interfaces, i);
ce->interfaces = new_interfaces;
for (i = 0; i < ce->num_interfaces; i++) {
- char *lcname = do_alloca(ce->interfaces[i]->name_length+1);
-
- zend_str_tolower_copy(lcname, ce->interfaces[i]->name, ce->interfaces[i]->name_length);
- if (zend_hash_find(ht, lcname, ce->interfaces[i]->name_length+1, (void**)&parent) == SUCCESS) {
- ce->interfaces[i] = *parent;
- }
- free_alloca(lcname);
-
+ ce->interfaces[i] = ce->interfaces[i]->u_twin;
}
}
- p = p->pListNext;
- }
-
- /* Convert Class Names to unicode */
- p = ht->pListHead;
- while (p != NULL) {
- zend_class_entry *ce = *(zend_class_entry**)p->pData;
- UChar *uname = malloc(UBYTES(ce->name_length+1));
+
+ q = ce->function_table.pListHead;
+ while (q != NULL) {
+ zend_function *f = (zend_function*)q->pData;
+
+ if (f->common.scope) {
+ f->common.scope = f->common.scope->u_twin;
+ }
+ if (f->common.prototype) {
+ f->common.prototype = f->common.prototype->common.u_twin;
+ }
+ q = q->pListNext;
+ }
- u_charsToUChars(ce->name, uname, ce->name_length+1);
- ce->name = (char*)uname;
+ if (ce->constructor) {
+ ce->constructor = ce->constructor->common.u_twin;
+ } else if (ce->destructor) {
+ ce->destructor = ce->destructor->common.u_twin;
+ } else if (ce->clone) {
+ ce->clone = ce->clone->common.u_twin;
+ } else if (ce->__get) {
+ ce->__get = ce->__get->common.u_twin;
+ } else if (ce->__set) {
+ ce->__set = ce->__set->common.u_twin;
+ } else if (ce->__unset) {
+ ce->__unset = ce->__unset->common.u_twin;
+ } else if (ce->__isset) {
+ ce->__isset = ce->__isset->common.u_twin;
+ } else if (ce->__call) {
+ ce->__call = ce->__call->common.u_twin;
+ } else if (ce->serialize_func) {
+ ce->serialize_func = ce->serialize_func->common.u_twin;
+ } else if (ce->unserialize_func) {
+ ce->unserialize_func = ce->unserialize_func->common.u_twin;
+ }
p = p->pListNext;
}
+
}
#ifdef ZTS
@@ -1435,14 +1492,9 @@
CG(auto_globals) = UG(unicode)?global_u_auto_globals_table:global_auto_globals_table;
EG(zend_constants) = UG(unicode)?global_u_constants_table:global_constants_table;
#endif
- zend_standard_class_def = zend_get_named_class_entry("stdClass", sizeof("stdClass")-1 TSRMLS_CC);
-
init_unicode_request_globals(TSRMLS_C);
init_unicode_strings();
- init_exceptions(TSRMLS_C);
- init_interfaces(TSRMLS_C);
- init_reflection_api(TSRMLS_C);
init_compiler(TSRMLS_C);
init_executor(TSRMLS_C);
startup_scanner(TSRMLS_C);
http://cvs.php.net/diff.php/ZendEngine2/zend.h?r1=1.294&r2=1.295&ty=u
Index: ZendEngine2/zend.h
diff -u ZendEngine2/zend.h:1.294 ZendEngine2/zend.h:1.295
--- ZendEngine2/zend.h:1.294 Thu Aug 11 19:34:54 2005
+++ ZendEngine2/zend.h Fri Aug 12 07:29:24 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend.h,v 1.294 2005/08/11 23:34:54 andrei Exp $ */
+/* $Id: zend.h,v 1.295 2005/08/12 11:29:24 dmitry Exp $ */
#ifndef ZEND_H
#define ZEND_H
@@ -381,6 +381,8 @@
zend_uint line_end;
char *doc_comment;
zend_uint doc_comment_len;
+
+ zend_class_entry *u_twin;
struct _zend_module_entry *module;
};
http://cvs.php.net/diff.php/ZendEngine2/zend_API.c?r1=1.298&r2=1.299&ty=u
Index: ZendEngine2/zend_API.c
diff -u ZendEngine2/zend_API.c:1.298 ZendEngine2/zend_API.c:1.299
--- ZendEngine2/zend_API.c:1.298 Fri Aug 12 01:53:27 2005
+++ ZendEngine2/zend_API.c Fri Aug 12 07:29:24 2005
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_API.c,v 1.298 2005/08/12 05:53:27 sebastian Exp $ */
+/* $Id: zend_API.c,v 1.299 2005/08/12 11:29:24 dmitry Exp $ */
#include "zend.h"
#include "zend_execute.h"
@@ -1068,7 +1068,7 @@
ZEND_API int _object_init(zval *arg ZEND_FILE_LINE_DC TSRMLS_DC)
{
- return _object_init_ex(arg, zend_standard_class_def ZEND_FILE_LINE_RELAY_CC TSRMLS_CC);
+ return _object_init_ex(arg, U_CLASS_ENTRY(zend_standard_class_def) ZEND_FILE_LINE_RELAY_CC TSRMLS_CC);
}
@@ -2841,22 +2841,6 @@
return value;
}
-ZEND_API zend_class_entry* zend_get_named_class_entry(char* name, int name_length TSRMLS_DC)
-{
- zend_class_entry **scope;
- char *lcname = do_alloca(name_length+1);
-
- zend_str_tolower_copy(lcname, name, name_length);
- if (zend_hash_find(CG(class_table), lcname, name_length+1, (void**)&scope) == FAILURE) {
- free_alloca(lcname);
- zend_error(E_ERROR, "Class '%s' is not defined", name);
- return NULL;
- }
- free_alloca(lcname);
- return *scope;
-}
-
-
/*
* Return the most precise string type out of the list.
* If none of the types are string types, IS_STRING is returned.
http://cvs.php.net/diff.php/ZendEngine2/zend_API.h?r1=1.209&r2=1.210&ty=u
Index: ZendEngine2/zend_API.h
diff -u ZendEngine2/zend_API.h:1.209 ZendEngine2/zend_API.h:1.210
--- ZendEngine2/zend_API.h:1.209 Fri Aug 12 01:53:27 2005
+++ ZendEngine2/zend_API.h Fri Aug 12 07:29:24 2005
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_API.h,v 1.209 2005/08/12 05:53:27 sebastian Exp $ */
+/* $Id: zend_API.h,v 1.210 2005/08/12 11:29:24 dmitry Exp $ */
#ifndef ZEND_API_H
#define ZEND_API_H
@@ -114,7 +114,7 @@
#endif
-
+#define U_CLASS_ENTRY(ce) ((UG(unicode)&&ce)?ce->u_twin:ce)
#define INIT_CLASS_ENTRY(class_container, class_name, functions) INIT_OVERLOADED_CLASS_ENTRY(class_container, class_name, functions, NULL, NULL, NULL)
@@ -135,6 +135,8 @@
class_container.__set = handle_propset; \
class_container.__unset = handle_propunset; \
class_container.__isset = handle_propisset; \
+ class_container.serialize_func = NULL; \
+ class_container.unserialize_func = NULL; \
class_container.serialize = NULL; \
class_container.unserialize = NULL; \
class_container.parent = NULL; \
@@ -142,6 +144,7 @@
class_container.interfaces = NULL; \
class_container.get_iterator = NULL; \
class_container.iterator_funcs.funcs = NULL; \
+ class_container.u_twin = NULL; \
class_container.module = NULL; \
}
@@ -385,8 +388,6 @@
ZEND_API int zend_delete_global_variable(char *name, int name_len TSRMLS_DC);
ZEND_API int zend_u_delete_global_variable(zend_uchar type, void *name, int name_len TSRMLS_DC);
-ZEND_API zend_class_entry* zend_get_named_class_entry(char* name, int name_length TSRMLS_DC);
-
ZEND_API void zend_reset_all_cv(HashTable *symbol_table TSRMLS_DC);
#define add_method(arg, key, method) add_assoc_function((arg), (key), (method))
http://cvs.php.net/diff.php/ZendEngine2/zend_compile.c?r1=1.651&r2=1.652&ty=u
Index: ZendEngine2/zend_compile.c
diff -u ZendEngine2/zend_compile.c:1.651 ZendEngine2/zend_compile.c:1.652
--- ZendEngine2/zend_compile.c:1.651 Fri Aug 12 01:53:27 2005
+++ ZendEngine2/zend_compile.c Fri Aug 12 07:29:25 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_compile.c,v 1.651 2005/08/12 05:53:27 sebastian Exp $ */
+/* $Id: zend_compile.c,v 1.652 2005/08/12 11:29:25 dmitry Exp $ */
#include <zend_language_parser.h>
#include "zend.h"
@@ -514,7 +514,7 @@
if (modifiers->u.constant.value.lval & ZEND_ACC_ABSTRACT) {
if(modifiers->u.constant.value.lval & ZEND_ACC_PRIVATE) {
- zend_error(E_COMPILE_ERROR, "%s function %s::%s() cannot be declared private", method_type, CG(active_class_entry)->name, function_name->u.constant.value.str.val);
+ zend_error(E_COMPILE_ERROR, "%s function %v::%R() cannot be declared private", method_type, CG(active_class_entry)->name, Z_TYPE(function_name->u.constant), Z_UNIVAL(function_name->u.constant));
}
if (body->u.constant.value.lval == ZEND_ACC_ABSTRACT) {
zend_op *opline = get_next_op(CG(active_op_array) TSRMLS_CC);
http://cvs.php.net/diff.php/ZendEngine2/zend_compile.h?r1=1.318&r2=1.319&ty=u
Index: ZendEngine2/zend_compile.h
diff -u ZendEngine2/zend_compile.h:1.318 ZendEngine2/zend_compile.h:1.319
--- ZendEngine2/zend_compile.h:1.318 Thu Aug 11 19:34:55 2005
+++ ZendEngine2/zend_compile.h Fri Aug 12 07:29:26 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_compile.h,v 1.318 2005/08/11 23:34:55 andrei Exp $ */
+/* $Id: zend_compile.h,v 1.319 2005/08/12 11:29:26 dmitry Exp $ */
#ifndef ZEND_COMPILE_H
#define ZEND_COMPILE_H
@@ -179,6 +179,7 @@
zend_arg_info *arg_info;
zend_bool pass_rest_by_reference;
unsigned char return_reference;
+ union _zend_function *u_twin;
/* END of common elements */
zend_uint *refcount;
@@ -232,6 +233,7 @@
zend_arg_info *arg_info;
zend_bool pass_rest_by_reference;
unsigned char return_reference;
+ union _zend_function *u_twin;
/* END of common elements */
void (*handler)(INTERNAL_FUNCTION_PARAMETERS);
@@ -253,6 +255,7 @@
zend_arg_info *arg_info;
zend_bool pass_rest_by_reference;
unsigned char return_reference;
+ union _zend_function *u_twin;
} common;
zend_op_array op_array;
http://cvs.php.net/diff.php/ZendEngine2/zend_exceptions.c?r1=1.80&r2=1.81&ty=u
Index: ZendEngine2/zend_exceptions.c
diff -u ZendEngine2/zend_exceptions.c:1.80 ZendEngine2/zend_exceptions.c:1.81
--- ZendEngine2/zend_exceptions.c:1.80 Thu Aug 11 19:34:55 2005
+++ ZendEngine2/zend_exceptions.c Fri Aug 12 07:29:26 2005
@@ -19,7 +19,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_exceptions.c,v 1.80 2005/08/11 23:34:55 andrei Exp $ */
+/* $Id: zend_exceptions.c,v 1.81 2005/08/12 11:29:26 dmitry Exp $ */
#include "zend.h"
#include "zend_API.h"
@@ -94,9 +94,9 @@
trace->refcount = 0;
zend_fetch_debug_backtrace(trace, skip_top_traces TSRMLS_CC);
- zend_update_property_string(default_exception_ce, &obj, "file", sizeof("file")-1, zend_get_executed_filename(TSRMLS_C) TSRMLS_CC);
- zend_update_property_long(default_exception_ce, &obj, "line", sizeof("line")-1, zend_get_executed_lineno(TSRMLS_C) TSRMLS_CC);
- zend_update_property(default_exception_ce, &obj, "trace", sizeof("trace")-1, trace TSRMLS_CC);
+ zend_update_property_string(U_CLASS_ENTRY(default_exception_ce), &obj, "file", sizeof("file")-1, zend_get_executed_filename(TSRMLS_C) TSRMLS_CC);
+ zend_update_property_long(U_CLASS_ENTRY(default_exception_ce), &obj, "line", sizeof("line")-1, zend_get_executed_lineno(TSRMLS_C) TSRMLS_CC);
+ zend_update_property(U_CLASS_ENTRY(default_exception_ce), &obj, "trace", sizeof("trace")-1, trace TSRMLS_CC);
return obj.value.obj;
}
@@ -138,11 +138,11 @@
object = getThis();
if (message) {
- zend_update_property_string(default_exception_ce, object, "message", sizeof("message")-1, message TSRMLS_CC);
+ zend_update_property_string(U_CLASS_ENTRY(default_exception_ce), object, "message", sizeof("message")-1, message TSRMLS_CC);
}
if (code) {
- zend_update_property_long(default_exception_ce, object, "code", sizeof("code")-1, code TSRMLS_CC);
+ zend_update_property_long(U_CLASS_ENTRY(default_exception_ce), object, "code", sizeof("code")-1, code TSRMLS_CC);
}
}
/* }}} */
@@ -164,21 +164,21 @@
object = getThis();
if (message) {
- zend_update_property_string(default_exception_ce, object, "message", sizeof("message")-1, message TSRMLS_CC);
+ zend_update_property_string(U_CLASS_ENTRY(default_exception_ce), object, "message", sizeof("message")-1, message TSRMLS_CC);
}
if (code) {
- zend_update_property_long(default_exception_ce, object, "code", sizeof("code")-1, code TSRMLS_CC);
+ zend_update_property_long(U_CLASS_ENTRY(default_exception_ce), object, "code", sizeof("code")-1, code TSRMLS_CC);
}
- zend_update_property_long(default_exception_ce, object, "severity", sizeof("severity")-1, severity TSRMLS_CC);
+ zend_update_property_long(U_CLASS_ENTRY(default_exception_ce), object, "severity", sizeof("severity")-1, severity TSRMLS_CC);
if (argc >= 4) {
- zend_update_property_string(default_exception_ce, object, "file", sizeof("file")-1, filename TSRMLS_CC);
+ zend_update_property_string(U_CLASS_ENTRY(default_exception_ce), object, "file", sizeof("file")-1, filename TSRMLS_CC);
if (argc < 5) {
lineno = 0; /* invalidate lineno */
}
- zend_update_property_long(default_exception_ce, object, "line", sizeof("line")-1, lineno TSRMLS_CC);
+ zend_update_property_long(U_CLASS_ENTRY(default_exception_ce), object, "line", sizeof("line")-1, lineno TSRMLS_CC);
}
}
/* }}} */
@@ -192,7 +192,7 @@
{
zval *value;
- value = zend_read_property(default_exception_ce, object, name, name_len, 0 TSRMLS_CC);
+ value = zend_read_property(U_CLASS_ENTRY(default_exception_ce), object, name, name_len, 0 TSRMLS_CC);
*return_value = *value;
zval_copy_ctor(return_value);
@@ -435,7 +435,7 @@
char *res = estrdup(""), **str = &res, *s_tmp;
int res_len = 0, *len = &res_len, num = 0;
- trace = zend_read_property(default_exception_ce, getThis(), "trace", sizeof("trace")-1, 1 TSRMLS_CC);
+ trace = zend_read_property(U_CLASS_ENTRY(default_exception_ce), getThis(), "trace", sizeof("trace")-1, 1 TSRMLS_CC);
zend_hash_apply_with_arguments(Z_ARRVAL_P(trace), (apply_func_args_t)_build_trace_string, 3, str, len, &num);
s_tmp = emalloc(1 + MAX_LENGTH_OF_LONG + 7 + 1);
@@ -508,7 +508,7 @@
/* We store the result in the private property string so we can access
* the result in uncaught exception handlers without memleaks. */
- zend_update_property_string(default_exception_ce, getThis(), "string", sizeof("string")-1, str TSRMLS_CC);
+ zend_update_property_string(U_CLASS_ENTRY(default_exception_ce), getThis(), "string", sizeof("string")-1, str TSRMLS_CC);
if (trace) {
zval_ptr_dtor(&trace);
@@ -590,12 +590,12 @@
ZEND_API zend_class_entry *zend_exception_get_default(void)
{
- return default_exception_ce;
+ return U_CLASS_ENTRY(default_exception_ce);
}
ZEND_API zend_class_entry *zend_get_error_exception(void)
{
- return error_exception_ce;
+ return U_CLASS_ENTRY(error_exception_ce);
}
@@ -605,21 +605,21 @@
MAKE_STD_ZVAL(ex);
if (exception_ce) {
- if (!instanceof_function(exception_ce, default_exception_ce TSRMLS_CC)) {
+ if (!instanceof_function(exception_ce, U_CLASS_ENTRY(default_exception_ce) TSRMLS_CC)) {
zend_error(E_NOTICE, "Exceptions must be derived from the Exception base class");
- exception_ce = default_exception_ce;
+ exception_ce = U_CLASS_ENTRY(default_exception_ce);
}
} else {
- exception_ce = default_exception_ce;
+ exception_ce = U_CLASS_ENTRY(default_exception_ce);
}
object_init_ex(ex, exception_ce);
if (message) {
- zend_update_property_string(default_exception_ce, ex, "message", sizeof("message")-1, message TSRMLS_CC);
+ zend_update_property_string(U_CLASS_ENTRY(default_exception_ce), ex, "message", sizeof("message")-1, message TSRMLS_CC);
}
if (code) {
- zend_update_property_long(default_exception_ce, ex, "code", sizeof("code")-1, code TSRMLS_CC);
+ zend_update_property_long(U_CLASS_ENTRY(default_exception_ce), ex, "code", sizeof("code")-1, code TSRMLS_CC);
}
zend_throw_exception_internal(ex TSRMLS_CC);
@@ -645,7 +645,7 @@
ZEND_API zval * zend_throw_error_exception(zend_class_entry *exception_ce, char *message, long code, int severity TSRMLS_DC)
{
zval *ex = zend_throw_exception(exception_ce, message, code TSRMLS_CC);
- zend_update_property_long(default_exception_ce, ex, "severity", sizeof("severity")-1, severity TSRMLS_CC);
+ zend_update_property_long(U_CLASS_ENTRY(default_exception_ce), ex, "severity", sizeof("severity")-1, severity TSRMLS_CC);
return ex;
}
@@ -662,7 +662,7 @@
ZEND_API void zend_exception_error(zval *exception TSRMLS_DC)
{
zend_class_entry *ce_exception = Z_OBJCE_P(exception);
- if (instanceof_function(ce_exception, default_exception_ce TSRMLS_CC)) {
+ if (instanceof_function(ce_exception, U_CLASS_ENTRY(default_exception_ce) TSRMLS_CC)) {
zval *str, *file, *line;
EG(exception) = NULL;
@@ -672,16 +672,16 @@
if (Z_TYPE_P(str) != IS_STRING) {
zend_error(E_WARNING, "%v::__toString() must return a string", ce_exception->name);
} else {
- zend_update_property_string(default_exception_ce, exception, "string", sizeof("string")-1, EG(exception) ? ce_exception->name : Z_STRVAL_P(str) TSRMLS_CC);
+ zend_update_property_string(U_CLASS_ENTRY(default_exception_ce), exception, "string", sizeof("string")-1, EG(exception) ? ce_exception->name : Z_STRVAL_P(str) TSRMLS_CC);
}
}
zval_ptr_dtor(&str);
if (EG(exception)) {
/* do the best we can to inform about the inner exception */
- if (instanceof_function(ce_exception, default_exception_ce TSRMLS_CC)) {
- file = zend_read_property(default_exception_ce, EG(exception), "file", sizeof("file")-1, 1 TSRMLS_CC);
- line = zend_read_property(default_exception_ce, EG(exception), "line", sizeof("line")-1, 1 TSRMLS_CC);
+ if (instanceof_function(ce_exception, U_CLASS_ENTRY(default_exception_ce) TSRMLS_CC)) {
+ file = zend_read_property(U_CLASS_ENTRY(default_exception_ce), EG(exception), "file", sizeof("file")-1, 1 TSRMLS_CC);
+ line = zend_read_property(U_CLASS_ENTRY(default_exception_ce), EG(exception), "line", sizeof("line")-1, 1 TSRMLS_CC);
} else {
file = NULL;
line = NULL;
@@ -689,9 +689,9 @@
zend_error_va(E_WARNING, file ? Z_STRVAL_P(file) : NULL, line ? Z_LVAL_P(line) : 0, "Uncaught %v in exception handling during call to %v::__tostring()", Z_OBJCE_P(EG(exception))->name, ce_exception->name);
}
- str = zend_read_property(default_exception_ce, exception, "string", sizeof("string")-1, 1 TSRMLS_CC);
- file = zend_read_property(default_exception_ce, exception, "file", sizeof("file")-1, 1 TSRMLS_CC);
- line = zend_read_property(default_exception_ce, exception, "line", sizeof("line")-1, 1 TSRMLS_CC);
+ str = zend_read_property(U_CLASS_ENTRY(default_exception_ce), exception, "string", sizeof("string")-1, 1 TSRMLS_CC);
+ file = zend_read_property(U_CLASS_ENTRY(default_exception_ce), exception, "file", sizeof("file")-1, 1 TSRMLS_CC);
+ line = zend_read_property(U_CLASS_ENTRY(default_exception_ce), exception, "line", sizeof("line")-1, 1 TSRMLS_CC);
zend_error_va(E_ERROR, Z_STRVAL_P(file), Z_LVAL_P(line), "Uncaught %s\n thrown", Z_STRVAL_P(str));
} else {
@@ -710,18 +710,12 @@
exception_ce = Z_OBJCE_P(exception);
- if (!exception_ce || !instanceof_function(exception_ce, default_exception_ce TSRMLS_CC)) {
+ if (!exception_ce || !instanceof_function(exception_ce, U_CLASS_ENTRY(default_exception_ce) TSRMLS_CC)) {
zend_error(E_ERROR, "Exceptions must be valid objects derived from the Exception base class");
}
zend_throw_exception_internal(exception TSRMLS_CC);
}
-void init_exceptions(TSRMLS_D)
-{
- default_exception_ce = zend_get_named_class_entry("Exception", sizeof("Exception")-1 TSRMLS_CC);
- error_exception_ce = zend_get_named_class_entry("ErrorException", sizeof("ErrorException")-1 TSRMLS_CC);
-}
-
/*
* Local variables:
* tab-width: 4
http://cvs.php.net/diff.php/ZendEngine2/zend_exceptions.h?r1=1.22&r2=1.23&ty=u
Index: ZendEngine2/zend_exceptions.h
diff -u ZendEngine2/zend_exceptions.h:1.22 ZendEngine2/zend_exceptions.h:1.23
--- ZendEngine2/zend_exceptions.h:1.22 Thu Aug 11 19:34:55 2005
+++ ZendEngine2/zend_exceptions.h Fri Aug 12 07:29:26 2005
@@ -19,7 +19,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_exceptions.h,v 1.22 2005/08/11 23:34:55 andrei Exp $ */
+/* $Id: zend_exceptions.h,v 1.23 2005/08/12 11:29:26 dmitry Exp $ */
#ifndef ZEND_EXCEPTIONS_H
#define ZEND_EXCEPTIONS_H
@@ -48,8 +48,6 @@
/* show an exception using zend_error(E_ERROR,...) */
ZEND_API void zend_exception_error(zval *exception TSRMLS_DC);
-void init_exceptions(TSRMLS_D);
-
END_EXTERN_C()
#endif
http://cvs.php.net/diff.php/ZendEngine2/zend_interfaces.c?r1=1.34&r2=1.35&ty=u
Index: ZendEngine2/zend_interfaces.c
diff -u ZendEngine2/zend_interfaces.c:1.34 ZendEngine2/zend_interfaces.c:1.35
--- ZendEngine2/zend_interfaces.c:1.34 Thu Aug 11 19:34:57 2005
+++ ZendEngine2/zend_interfaces.c Fri Aug 12 07:29:26 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_interfaces.c,v 1.34 2005/08/11 23:34:57 andrei Exp $ */
+/* $Id: zend_interfaces.c,v 1.35 2005/08/12 11:29:26 dmitry Exp $ */
#include "zend.h"
#include "zend_API.h"
@@ -322,11 +322,11 @@
return SUCCESS;
}
for (i = 0; i < class_type->num_interfaces; i++) {
- if (class_type->interfaces[i] == zend_ce_aggregate || class_type->interfaces[i] == zend_ce_iterator) {
+ if (class_type->interfaces[i] == U_CLASS_ENTRY(zend_ce_aggregate) || class_type->interfaces[i] == U_CLASS_ENTRY(zend_ce_iterator)) {
return SUCCESS;
}
}
- zend_error(E_CORE_ERROR, "Class %v must implement interface %v as part of either %v or %v",
+ zend_error(E_CORE_ERROR, "Class %v must implement interface %s as part of either %s or %s",
class_type->name,
zend_ce_traversable->name,
zend_ce_iterator->name,
@@ -348,10 +348,10 @@
/* c-level get_iterator cannot be changed (exception being only Traversable is implmented) */
if (class_type->num_interfaces) {
for (i = 0; i < class_type->num_interfaces; i++) {
- if (class_type->interfaces[i] == zend_ce_iterator) {
+ if (class_type->interfaces[i] == U_CLASS_ENTRY(zend_ce_iterator)) {
return FAILURE;
}
- if (class_type->interfaces[i] == zend_ce_traversable) {
+ if (class_type->interfaces[i] == U_CLASS_ENTRY(zend_ce_traversable)) {
t = i;
}
}
@@ -562,14 +562,6 @@
}
/* }}} */
-void init_interfaces(TSRMLS_D)
-{
- zend_ce_traversable = zend_get_named_class_entry("Traversable", sizeof("Traversable")-1 TSRMLS_CC);
- zend_ce_aggregate = zend_get_named_class_entry("IteratorAggregate", sizeof("IteratorAggregate")-1 TSRMLS_CC);
- zend_ce_iterator = zend_get_named_class_entry("Iterator", sizeof("Iterator")-1 TSRMLS_CC);
- zend_ce_arrayaccess = zend_get_named_class_entry("ArrayAccess", sizeof("ArrayAccess")-1 TSRMLS_CC);
-}
-
/*
* Local variables:
* tab-width: 4
http://cvs.php.net/diff.php/ZendEngine2/zend_interfaces.h?r1=1.12&r2=1.13&ty=u
Index: ZendEngine2/zend_interfaces.h
diff -u ZendEngine2/zend_interfaces.h:1.12 ZendEngine2/zend_interfaces.h:1.13
--- ZendEngine2/zend_interfaces.h:1.12 Thu Aug 11 19:34:57 2005
+++ ZendEngine2/zend_interfaces.h Fri Aug 12 07:29:26 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_interfaces.h,v 1.12 2005/08/11 23:34:57 andrei Exp $ */
+/* $Id: zend_interfaces.h,v 1.13 2005/08/12 11:29:26 dmitry Exp $ */
#ifndef ZEND_INTERFACES_H
#define ZEND_INTERFACES_H
@@ -51,8 +51,6 @@
ZEND_API void zend_register_interfaces(TSRMLS_D);
-void init_interfaces(TSRMLS_D);
-
END_EXTERN_C()
#endif /* ZEND_INTERFACES_H */
http://cvs.php.net/diff.php/ZendEngine2/zend_object_handlers.c?r1=1.136&r2=1.137&ty=u
Index: ZendEngine2/zend_object_handlers.c
diff -u ZendEngine2/zend_object_handlers.c:1.136 ZendEngine2/zend_object_handlers.c:1.137
--- ZendEngine2/zend_object_handlers.c:1.136 Thu Aug 11 19:34:57 2005
+++ ZendEngine2/zend_object_handlers.c Fri Aug 12 07:29:26 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_object_handlers.c,v 1.136 2005/08/11 23:34:57 andrei Exp $ */
+/* $Id: zend_object_handlers.c,v 1.137 2005/08/12 11:29:26 dmitry Exp $ */
#include "zend.h"
#include "zend_globals.h"
@@ -207,7 +207,7 @@
*/
} else {
if (!silent && (property_info->flags & ZEND_ACC_STATIC)) {
- zend_error(E_STRICT, "Accessing static property %s::$%s as non static", ce->name, Z_STRVAL_P(member));
+ zend_error(E_STRICT, "Accessing static property %v::$%R as non static", ce->name, Z_TYPE_P(member), Z_UNIVAL_P(member));
}
return property_info;
}
@@ -229,7 +229,7 @@
if (silent) {
return NULL;
}
- zend_error(E_ERROR, "Cannot access %s property %v::$%s", zend_visibility_string(property_info->flags), ce->name, Z_STRVAL_P(member));
+ zend_error(E_ERROR, "Cannot access %s property %v::$%R", zend_visibility_string(property_info->flags), ce->name, Z_TYPE_P(member), Z_STRVAL_P(member));
} else {
/* fall through, return property_info... */
}
@@ -287,17 +287,17 @@
zobj = Z_OBJ_P(object);
use_get = (zobj->ce->__get && !zobj->in_get);
- if (member->type != IS_STRING) {
+ if (member->type != IS_STRING && member->type != IS_UNICODE) {
ALLOC_ZVAL(tmp_member);
*tmp_member = *member;
INIT_PZVAL(tmp_member);
zval_copy_ctor(tmp_member);
- convert_to_string(tmp_member);
+ convert_to_text(tmp_member);
member = tmp_member;
}
#if DEBUG_OBJECT_HANDLERS
- fprintf(stderr, "Read object #%d property: %s\n", Z_OBJ_HANDLE_P(object), Z_STRVAL_P(member));
+ fprintf(stderr, "Read object #%d property: %R\n", Z_OBJ_HANDLE_P(object), Z_TYPE_P(member), Z_STRVAL_P(member));
#endif
/* make zend_get_property_info silent if we have getter - we may want to use it */
@@ -317,7 +317,7 @@
}
} else {
if (!silent) {
- zend_error(E_NOTICE,"Undefined property: %v::$%s", zobj->ce->name, Z_STRVAL_P(member));
+ zend_error(E_NOTICE,"Undefined property: %v::$%R", zobj->ce->name, Z_TYPE_P(member), Z_STRVAL_P(member));
}
retval = &EG(uninitialized_zval_ptr);
}
@@ -403,7 +403,7 @@
zend_class_entry *ce = Z_OBJCE_P(object);
zval *retval;
- if (instanceof_function_ex(ce, zend_ce_arrayaccess, 1 TSRMLS_CC)) {
+ if (instanceof_function_ex(ce, U_CLASS_ENTRY(zend_ce_arrayaccess), 1 TSRMLS_CC)) {
if(offset == NULL) {
/* [] construct */
ALLOC_INIT_ZVAL(offset);
@@ -436,7 +436,7 @@
{
zend_class_entry *ce = Z_OBJCE_P(object);
- if (instanceof_function_ex(ce, zend_ce_arrayaccess, 1 TSRMLS_CC)) {
+ if (instanceof_function_ex(ce, U_CLASS_ENTRY(zend_ce_arrayaccess), 1 TSRMLS_CC)) {
if (!offset) {
ALLOC_INIT_ZVAL(offset);
} else {
@@ -456,7 +456,7 @@
zval *retval;
int result;
- if (instanceof_function_ex(ce, zend_ce_arrayaccess, 1 TSRMLS_CC)) {
+ if (instanceof_function_ex(ce, U_CLASS_ENTRY(zend_ce_arrayaccess), 1 TSRMLS_CC)) {
SEPARATE_ARG_IF_REF(offset);
zend_call_method_with_1_params(&object, ce, NULL, "offsetexists", &retval, offset);
if (retval) {
@@ -498,7 +498,7 @@
}
#if DEBUG_OBJECT_HANDLERS
- fprintf(stderr, "Ptr object #%d property: %s\n", Z_OBJ_HANDLE_P(object), Z_STRVAL_P(member));
+ fprintf(stderr, "Ptr object #%d property: %R\n", Z_OBJ_HANDLE_P(object), Z_TYPE_P(member), Z_STRVAL_P(member));
#endif
property_info = zend_get_property_info(zobj->ce, member, 0 TSRMLS_CC);
@@ -510,7 +510,7 @@
/* we don't have access controls - will just add it */
new_zval = &EG(uninitialized_zval);
-/* zend_error(E_NOTICE, "Undefined property: %s", Z_STRVAL_P(member)); */
+/* zend_error(E_NOTICE, "Undefined property: %R", Z_TYPE_P(member), Z_STRVAL_P(member)); */
new_zval->refcount++;
zend_u_hash_quick_update(zobj->properties, Z_TYPE_P(member), property_info->name, property_info->name_length+1, property_info->h, &new_zval, sizeof(zval *), (void **) &retval);
} else {
@@ -565,7 +565,7 @@
{
zend_class_entry *ce = Z_OBJCE_P(object);
- if (instanceof_function_ex(ce, zend_ce_arrayaccess, 1 TSRMLS_CC)) {
+ if (instanceof_function_ex(ce, U_CLASS_ENTRY(zend_ce_arrayaccess), 1 TSRMLS_CC)) {
SEPARATE_ARG_IF_REF(offset);
zend_call_method_with_1_params(&object, ce, NULL, "offsetunset", NULL, offset);
zval_ptr_dtor(&offset);
@@ -757,14 +757,14 @@
*/
updated_fbc = zend_check_private_int(fbc, object->value.obj.handlers->get_class_entry(object TSRMLS_CC), lc_method_name, method_len TSRMLS_CC);
if (!updated_fbc) {
- zend_error(E_ERROR, "Call to %s method %v::%v() from context '%s'", zend_visibility_string(fbc->common.fn_flags), ZEND_FN_SCOPE_NAME(fbc), method_name, EG(scope) ? EG(scope)->name : "");
+ zend_error(E_ERROR, "Call to %s method %v::%v() from context '%v'", zend_visibility_string(fbc->common.fn_flags), ZEND_FN_SCOPE_NAME(fbc), method_name, EG(scope) ? EG(scope)->name : EMPTY_STR);
}
fbc = updated_fbc;
} else if ((fbc->common.fn_flags & ZEND_ACC_PROTECTED)) {
/* Ensure that if we're calling a protected function, we're allowed to do so.
*/
if (!zend_check_protected(fbc->common.scope, EG(scope))) {
- zend_error(E_ERROR, "Call to %s method %v::%v() from context '%s'", zend_visibility_string(fbc->common.fn_flags), ZEND_FN_SCOPE_NAME(fbc), method_name, EG(scope) ? EG(scope)->name : "");
+ zend_error(E_ERROR, "Call to %s method %v::%v() from context '%v'", zend_visibility_string(fbc->common.fn_flags), ZEND_FN_SCOPE_NAME(fbc), method_name, EG(scope) ? EG(scope)->name : EMPTY_STR);
}
}
@@ -926,7 +926,7 @@
}
#if DEBUG_OBJECT_HANDLERS
- fprintf(stderr, "Read object #%d property: %s\n", Z_OBJ_HANDLE_P(object), Z_STRVAL_P(member));
+ fprintf(stderr, "Read object #%d property: %R\n", Z_OBJ_HANDLE_P(object), Z_TYPE_P(member), Z_STRVAL_P(member));
#endif
property_info = zend_get_property_info(zobj->ce, member, 1 TSRMLS_CC);
http://cvs.php.net/diff.php/ZendEngine2/zend_operators.c?r1=1.209&r2=1.210&ty=u
Index: ZendEngine2/zend_operators.c
diff -u ZendEngine2/zend_operators.c:1.209 ZendEngine2/zend_operators.c:1.210
--- ZendEngine2/zend_operators.c:1.209 Thu Aug 11 19:34:59 2005
+++ ZendEngine2/zend_operators.c Fri Aug 12 07:29:26 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_operators.c,v 1.209 2005/08/11 23:34:59 andrei Exp $ */
+/* $Id: zend_operators.c,v 1.210 2005/08/12 11:29:26 dmitry Exp $ */
#include <ctype.h>
@@ -879,7 +879,7 @@
switch (op->type) {
case IS_ARRAY:
{
- object_and_properties_init(op, zend_standard_class_def, op->value.ht);
+ object_and_properties_init(op, U_CLASS_ENTRY(zend_standard_class_def), op->value.ht);
return;
break;
}
http://cvs.php.net/diff.php/ZendEngine2/zend_reflection_api.c?r1=1.166&r2=1.167&ty=u
Index: ZendEngine2/zend_reflection_api.c
diff -u ZendEngine2/zend_reflection_api.c:1.166 ZendEngine2/zend_reflection_api.c:1.167
--- ZendEngine2/zend_reflection_api.c:1.166 Thu Aug 11 19:34:59 2005
+++ ZendEngine2/zend_reflection_api.c Fri Aug 12 07:29:27 2005
@@ -19,7 +19,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_reflection_api.c,v 1.166 2005/08/11 23:34:59 andrei Exp $ */
+/* $Id: zend_reflection_api.c,v 1.167 2005/08/12 11:29:27 dmitry Exp $ */
#include "zend.h"
#include "zend_API.h"
#include "zend_exceptions.h"
@@ -54,11 +54,11 @@
/* Exception throwing macro */
#define _DO_THROW(msg) \
- zend_throw_exception(reflection_exception_ptr, msg, 0 TSRMLS_CC); \
+ zend_throw_exception(U_CLASS_ENTRY(reflection_exception_ptr), msg, 0 TSRMLS_CC); \
return; \
#define RETURN_ON_EXCEPTION \
- if (EG(exception) && Z_OBJCE_P(EG(exception)) == reflection_exception_ptr) { \
+ if (EG(exception) && Z_OBJCE_P(EG(exception)) == U_CLASS_ENTRY(reflection_exception_ptr)) { \
return; \
}
@@ -870,7 +870,7 @@
} else {
ZVAL_STRINGL(name, ce->name, ce->name_length, 1);
}
- reflection_instanciate(reflection_class_ptr, object TSRMLS_CC);
+ reflection_instanciate(U_CLASS_ENTRY(reflection_class_ptr), object TSRMLS_CC);
intern = (reflection_object *) zend_object_store_get_object(object TSRMLS_CC);
intern->ptr = ce;
intern->free_ptr = 0;
@@ -896,7 +896,7 @@
}
free_alloca(lcname);
- reflection_instanciate(reflection_extension_ptr, object TSRMLS_CC);
+ reflection_instanciate(U_CLASS_ENTRY(reflection_extension_ptr), object TSRMLS_CC);
intern = (reflection_object *) zend_object_store_get_object(object TSRMLS_CC);
MAKE_STD_ZVAL(name);
ZVAL_STRINGL(name, module->name, name_len, 1);
@@ -924,7 +924,7 @@
} else {
ZVAL_NULL(name);
}
- reflection_instanciate(reflection_parameter_ptr, object TSRMLS_CC);
+ reflection_instanciate(U_CLASS_ENTRY(reflection_parameter_ptr), object TSRMLS_CC);
intern = (reflection_object *) zend_object_store_get_object(object TSRMLS_CC);
reference = (parameter_reference*) emalloc(sizeof(parameter_reference));
reference->arg_info = arg_info;
@@ -951,7 +951,7 @@
ZVAL_STRING(name, function->common.function_name, 1);
}
- reflection_instanciate(reflection_function_ptr, object TSRMLS_CC);
+ reflection_instanciate(U_CLASS_ENTRY(reflection_function_ptr), object TSRMLS_CC);
intern = (reflection_object *) zend_object_store_get_object(object TSRMLS_CC);
intern->ptr = function;
intern->free_ptr = 0;
@@ -976,7 +976,7 @@
ZVAL_STRING(name, method->common.function_name, 1);
ZVAL_STRINGL(classname, ce->name, ce->name_length, 1);
}
- reflection_instanciate(reflection_method_ptr, object TSRMLS_CC);
+ reflection_instanciate(U_CLASS_ENTRY(reflection_method_ptr), object TSRMLS_CC);
intern = (reflection_object *) zend_object_store_get_object(object TSRMLS_CC);
intern->ptr = method;
intern->free_ptr = 0;
@@ -1023,7 +1023,7 @@
ZVAL_STRINGL(classname, ce->name, ce->name_length, 1);
}
- reflection_instanciate(reflection_property_ptr, object TSRMLS_CC);
+ reflection_instanciate(U_CLASS_ENTRY(reflection_property_ptr), object TSRMLS_CC);
intern = (reflection_object *) zend_object_store_get_object(object TSRMLS_CC);
reference = (property_reference*) emalloc(sizeof(property_reference));
reference->ce = ce;
@@ -1107,7 +1107,7 @@
params[1] = &output_ptr;
ZVAL_STRINGL(&fname, "export", sizeof("export") - 1, 0);
- fci.function_table = &reflection_ptr->function_table;
+ fci.function_table = &U_CLASS_ENTRY(reflection_ptr)->function_table;
fci.function_name = &fname;
fci.object_pp = NULL;
fci.retval_ptr_ptr = &retval_ptr;
@@ -1150,7 +1150,7 @@
int result;
zend_bool return_output = 0;
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O|b", &object, reflector_ptr, &return_output) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O|b", &object, U_CLASS_ENTRY(reflector_ptr), &return_output) == FAILURE) {
return;
}
@@ -1222,7 +1222,7 @@
Exports a reflection object. Returns the output if TRUE is specified for return, printing it otherwise. */
ZEND_METHOD(reflection_function, export)
{
- _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, reflection_function_ptr, 1);
+ _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(reflection_function_ptr), 1);
}
/* }}} */
@@ -1252,7 +1252,7 @@
lcname = zend_u_str_case_fold(type, name_str, name_len, 1, &lcname_len);
if (zend_u_hash_find(EG(function_table), type, lcname, lcname_len + 1, (void **)&fptr) == FAILURE) {
efree(lcname);
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Function %R() does not exist", type, name_str);
return;
}
@@ -1446,7 +1446,7 @@
efree(params);
if (result == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Invocation of function %v() failed", fptr->common.function_name);
return;
}
@@ -1510,7 +1510,7 @@
efree(params);
if (result == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Invocation of function %v() failed", fptr->common.function_name);
return;
}
@@ -1594,7 +1594,7 @@
Exports a reflection object. Returns the output if TRUE is specified for return, printing it otherwise. */
ZEND_METHOD(reflection_parameter, export)
{
- _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, reflection_parameter_ptr, 2);
+ _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(reflection_parameter_ptr), 2);
}
/* }}} */
@@ -1633,7 +1633,7 @@
lcname = zend_u_str_case_fold(Z_TYPE_P(reference), Z_STRVAL_P(reference), Z_STRLEN_P(reference), 1, &lcname_len);
if (zend_u_hash_find(EG(function_table), Z_TYPE_P(reference), lcname, lcname_len + 1, (void**) &fptr) == FAILURE) {
efree(lcname);
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Function %R() does not exist", Z_TYPE_P(reference), Z_STRVAL_P(reference));
return;
}
@@ -1659,7 +1659,7 @@
} else {
convert_to_text_ex(classref);
if (zend_u_lookup_class(Z_TYPE_PP(classref), Z_UNIVAL_PP(classref), Z_UNILEN_PP(classref), &pce TSRMLS_CC) == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Class %R does not exist", Z_TYPE_PP(classref), Z_UNIVAL_PP(classref));
return;
}
@@ -1670,7 +1670,7 @@
lcname = zend_u_str_case_fold(Z_TYPE_PP(method), Z_UNIVAL_PP(method), Z_UNILEN_PP(method), 1, &lcname_len);
if (zend_u_hash_find(&ce->function_table, Z_TYPE_PP(method), lcname, lcname_len + 1, (void **) &fptr) == FAILURE) {
efree(lcname);
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Method %R::%R() does not exist", Z_TYPE_PP(classref), Z_UNIVAL_PP(classref), Z_TYPE_PP(method), Z_UNIVAL_PP(method));
return;
}
@@ -1775,7 +1775,7 @@
if (zend_u_hash_find(EG(class_table), UG(unicode)?IS_UNICODE:IS_STRING, lcname, lcname_len + 1, (void **) &pce) == FAILURE) {
efree(lcname);
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Class %v does not exist", param->arg_info->class_name);
return;
}
@@ -1881,16 +1881,16 @@
if (param->fptr->type != ZEND_USER_FUNCTION)
{
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Cannot determine default value for internal functions");
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC, "Cannot determine default value for internal functions");
return;
}
if (param->offset < param->required) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Parameter is not optional");
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC, "Parameter is not optional");
return;
}
precv = _get_recv_op((zend_op_array*)param->fptr, param->offset);
if (!precv || precv->opcode != ZEND_RECV_INIT || precv->op2.op_type == IS_UNUSED) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Internal error");
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC, "Internal error");
return;
}
@@ -1905,7 +1905,7 @@
Exports a reflection object. Returns the output if TRUE is specified for return, printing it otherwise. */
ZEND_METHOD(reflection_method, export)
{
- _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, reflection_method_ptr, 2);
+ _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(reflection_method_ptr), 2);
}
/* }}} */
@@ -1940,7 +1940,7 @@
case IS_STRING:
case IS_UNICODE:
if (zend_u_lookup_class(Z_TYPE_P(classname), Z_UNIVAL_P(classname), Z_UNILEN_P(classname), &pce TSRMLS_CC) == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Class %v does not exist", Z_UNIVAL_P(classname));
return;
}
@@ -1968,7 +1968,7 @@
if (zend_u_hash_find(&ce->function_table, type, lcname, lcname_len + 1, (void **) &mptr) == FAILURE) {
efree(lcname);
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Method %v::%R() does not exist", ce->name, type, name_str);
return;
}
@@ -2030,11 +2030,11 @@
if (!(mptr->common.fn_flags & ZEND_ACC_PUBLIC) ||
(mptr->common.fn_flags & ZEND_ACC_ABSTRACT)) {
if (mptr->common.fn_flags & ZEND_ACC_ABSTRACT) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Trying to invoke abstract method %v::%v()",
mptr->common.scope->name, mptr->common.function_name);
} else {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Trying to invoke %s method %v::%v() from scope %v",
mptr->common.fn_flags & ZEND_ACC_PROTECTED ? "protected" : "private",
mptr->common.scope->name, mptr->common.function_name,
@@ -2095,7 +2095,7 @@
efree(params);
if (result == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Invocation of method %v::%v() failed", mptr->common.scope->name, mptr->common.function_name);
return;
}
@@ -2133,11 +2133,11 @@
if (!(mptr->common.fn_flags & ZEND_ACC_PUBLIC) ||
(mptr->common.fn_flags & ZEND_ACC_ABSTRACT)) {
if (mptr->common.fn_flags & ZEND_ACC_ABSTRACT) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Trying to invoke abstract method %v::%v",
mptr->common.scope->name, mptr->common.function_name);
} else {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Trying to invoke %s method %v::%v from scope %v",
mptr->common.fn_flags & ZEND_ACC_PROTECTED ? "protected" : "private",
mptr->common.scope->name, mptr->common.function_name,
@@ -2164,7 +2164,7 @@
} else {
if (!object) {
efree(params);
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Trying to invoke non static method %v::%v without an object",
mptr->common.scope->name, mptr->common.function_name);
return;
@@ -2199,7 +2199,7 @@
efree(params);
if (result == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Invocation of method %v::%v() failed", mptr->common.scope->name, mptr->common.function_name);
return;
}
@@ -2319,7 +2319,7 @@
Exports a reflection object. Returns the output if TRUE is specified for return, printing it otherwise. */
ZEND_METHOD(reflection_class, export)
{
- _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, reflection_class_ptr, 1);
+ _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(reflection_class_ptr), 1);
}
/* }}} */
@@ -2365,7 +2365,7 @@
convert_to_string_ex(&argument);
if (zend_u_lookup_class(Z_TYPE_P(argument), Z_UNIVAL_P(argument), Z_UNILEN_P(argument), &ce TSRMLS_CC) == FAILURE) {
if (!EG(exception)) {
- zend_throw_exception_ex(reflection_exception_ptr, -1 TSRMLS_CC, "Class %s does not exist", Z_STRVAL_P(argument));
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), -1 TSRMLS_CC, "Class %s does not exist", Z_STRVAL_P(argument));
}
return;
}
@@ -2432,7 +2432,7 @@
if (def_value) {
RETURN_ZVAL(def_value, 1, 0);
} else {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Class %s does not have a property named %s", ce->name, name);
}
return;
@@ -2463,7 +2463,7 @@
zend_update_class_constants(ce TSRMLS_CC);
variable_ptr = zend_std_get_static_property(ce, name, name_len, 1 TSRMLS_CC);
if (!variable_ptr) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Class %s does not have a property named %s", ce->name, name);
return;
}
@@ -2709,7 +2709,7 @@
efree(lc_name);
} else {
efree(lc_name);
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Method %R does not exist", type, name);
return;
}
@@ -2813,7 +2813,7 @@
if (zend_hash_find(&ce->properties_info, name, name_len + 1, (void**) &property_info) == SUCCESS && (property_info->flags & ZEND_ACC_SHADOW) == 0) {
reflection_property_factory(ce, property_info, return_value TSRMLS_CC);
} else {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Property %s does not exist", name);
return;
}
@@ -3043,7 +3043,7 @@
zend_fcall_info_cache fcc;
if (!(ce->constructor->common.fn_flags & ZEND_ACC_PUBLIC)) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC, "Access to non-public constructor of class %v", ce->name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC, "Access to non-public constructor of class %v", ce->name);
return;
}
@@ -3145,14 +3145,14 @@
case IS_STRING:
case IS_UNICODE:
if (zend_u_lookup_class(Z_TYPE_P(class_name), Z_UNIVAL_P(class_name), Z_UNILEN_P(class_name), &pce TSRMLS_CC) == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Interface %s does not exist", Z_STRVAL_P(class_name));
return;
}
class_ce = *pce;
break;
case IS_OBJECT:
- if (instanceof_function(Z_OBJCE_P(class_name), reflection_class_ptr TSRMLS_CC)) {
+ if (instanceof_function(Z_OBJCE_P(class_name), U_CLASS_ENTRY(reflection_class_ptr) TSRMLS_CC)) {
argument = (reflection_object *) zend_object_store_get_object(class_name TSRMLS_CC);
if (argument == NULL || argument->ptr == NULL) {
zend_error(E_ERROR, "Internal error: Failed to retrieve the argument's reflection object");
@@ -3163,7 +3163,7 @@
}
/* no break */
default:
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Parameter one must either be a string or a ReflectionClass object");
return;
}
@@ -3192,14 +3192,14 @@
case IS_STRING:
case IS_UNICODE:
if (zend_u_lookup_class(Z_TYPE_P(interface), Z_UNIVAL_P(interface), Z_UNILEN_P(interface), &pce TSRMLS_CC) == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Interface %s does not exist", Z_STRVAL_P(interface));
return;
}
interface_ce = *pce;
break;
case IS_OBJECT:
- if (instanceof_function(Z_OBJCE_P(interface), reflection_class_ptr TSRMLS_CC)) {
+ if (instanceof_function(Z_OBJCE_P(interface), U_CLASS_ENTRY(reflection_class_ptr) TSRMLS_CC)) {
argument = (reflection_object *) zend_object_store_get_object(interface TSRMLS_CC);
if (argument == NULL || argument->ptr == NULL) {
zend_error(E_ERROR, "Internal error: Failed to retrieve the argument's reflection object");
@@ -3210,13 +3210,13 @@
}
/* no break */
default:
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Parameter one must either be a string or a ReflectionClass object");
return;
}
if (!(interface_ce->ce_flags & ZEND_ACC_INTERFACE)) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Interface %v is a Class", interface_ce->name);
return;
}
@@ -3276,7 +3276,7 @@
Exports a reflection object. Returns the output if TRUE is specified for return, printing it otherwise. */
ZEND_METHOD(reflection_object, export)
{
- _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, reflection_object_ptr, 1);
+ _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(reflection_object_ptr), 1);
}
/* }}} */
@@ -3292,7 +3292,7 @@
Exports a reflection object. Returns the output if TRUE is specified for return, printing it otherwise. */
ZEND_METHOD(reflection_property, export)
{
- _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, reflection_property_ptr, 2);
+ _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(reflection_property_ptr), 2);
}
/* }}} */
@@ -3325,7 +3325,7 @@
case IS_STRING:
case IS_UNICODE:
if (zend_u_lookup_class(Z_TYPE_P(classname), Z_UNIVAL_P(classname), Z_UNILEN_P(classname), &pce TSRMLS_CC) == FAILURE) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Class %s does not exist", Z_STRVAL_P(classname));
return;
}
@@ -3342,7 +3342,7 @@
}
if (zend_hash_find(&ce->properties_info, name_str, name_len + 1, (void **) &property_info) == FAILURE || (property_info->flags & ZEND_ACC_SHADOW)) {
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Property %v::$%s does not exist", ce->name, name_str);
return;
}
@@ -3614,7 +3614,7 @@
Exports a reflection object. Returns the output if TRUE is specified for return, printing it otherwise. */
ZEND_METHOD(reflection_extension, export)
{
- _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, reflection_extension_ptr, 1);
+ _reflection_export(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(reflection_extension_ptr), 1);
}
/* }}} */
@@ -3643,7 +3643,7 @@
zend_str_tolower_copy(lcname, name_str, name_len);
if (zend_hash_find(&module_registry, lcname, name_len + 1, (void **)&module) == FAILURE) {
free_alloca(lcname);
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Extension %s does not exist", name_str);
return;
}
@@ -4015,7 +4015,7 @@
&& (ZEND_U_EQUAL(Z_TYPE_P(member), Z_UNIVAL_P(member), Z_UNILEN_P(member), "name", sizeof("name")-1) ||
ZEND_U_EQUAL(Z_TYPE_P(member), Z_UNIVAL_P(member), Z_UNILEN_P(member), "class", sizeof("class")-1)))
{
- zend_throw_exception_ex(reflection_exception_ptr, 0 TSRMLS_CC,
+ zend_throw_exception_ex(U_CLASS_ENTRY(reflection_exception_ptr), 0 TSRMLS_CC,
"Cannot set read-only property %v::$%R", Z_OBJCE_P(object)->name, Z_TYPE_P(member), Z_UNIVAL_P(member));
}
else
@@ -4106,20 +4106,6 @@
}
/* }}} */
-void init_reflection_api(TSRMLS_D)
-{
- reflection_exception_ptr = zend_get_named_class_entry("ReflectionException", sizeof("ReflectionException")-1 TSRMLS_CC);
- reflection_ptr = zend_get_named_class_entry("Reflection", sizeof("Reflection")-1 TSRMLS_CC);
- reflector_ptr = zend_get_named_class_entry("Reflector", sizeof("Reflector")-1 TSRMLS_CC);
- reflection_function_ptr = zend_get_named_class_entry("ReflectionFunction", sizeof("ReflectionFunction")-1 TSRMLS_CC);
- reflection_parameter_ptr = zend_get_named_class_entry("ReflectionParameter", sizeof("ReflectionParameter")-1 TSRMLS_CC);
- reflection_method_ptr = zend_get_named_class_entry("ReflectionMethod", sizeof("ReflectionMethod")-1 TSRMLS_CC);
- reflection_class_ptr = zend_get_named_class_entry("ReflectionClass", sizeof("ReflectionClass")-1 TSRMLS_CC);
- reflection_object_ptr = zend_get_named_class_entry("ReflectionObject", sizeof("ReflectionObject")-1 TSRMLS_CC);
- reflection_property_ptr = zend_get_named_class_entry("ReflectionProperty", sizeof("ReflectionProperty")-1 TSRMLS_CC);
- reflection_extension_ptr = zend_get_named_class_entry("ReflectionExtension", sizeof("ReflectionExtension")-1 TSRMLS_CC);
-}
-
/*
* Local variables:
* tab-width: 4
http://cvs.php.net/diff.php/ZendEngine2/zend_reflection_api.h?r1=1.5&r2=1.6&ty=u
Index: ZendEngine2/zend_reflection_api.h
diff -u ZendEngine2/zend_reflection_api.h:1.5 ZendEngine2/zend_reflection_api.h:1.6
--- ZendEngine2/zend_reflection_api.h:1.5 Thu Aug 11 19:34:59 2005
+++ ZendEngine2/zend_reflection_api.h Fri Aug 12 07:29:27 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_reflection_api.h,v 1.5 2005/08/11 23:34:59 andrei Exp $ */
+/* $Id: zend_reflection_api.h,v 1.6 2005/08/12 11:29:27 dmitry Exp $ */
#ifndef ZEND_REFLECTION_API_H
#define ZEND_REFLECTION_API_H
@@ -26,8 +26,6 @@
ZEND_API void zend_register_reflection_api(TSRMLS_D);
ZEND_API void zend_reflection_class_factory(zend_class_entry *ce, zval *object TSRMLS_DC);
-void init_reflection_api(TSRMLS_D);
-
END_EXTERN_C()
#endif
http://cvs.php.net/diff.php/php-src/ext/dom/attr.c?r1=1.18&r2=1.19&ty=u
Index: php-src/ext/dom/attr.c
diff -u php-src/ext/dom/attr.c:1.18 php-src/ext/dom/attr.c:1.19
--- php-src/ext/dom/attr.c:1.18 Wed Aug 3 10:06:58 2005
+++ php-src/ext/dom/attr.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: attr.c,v 1.18 2005/08/03 14:06:58 sniper Exp $ */
+/* $Id: attr.c,v 1.19 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -54,8 +54,8 @@
char *name, *value = NULL;
int name_len, value_len, name_valid;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s", &id, dom_attr_class_entry, &name, &name_len, &value, &value_len) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s", &id, U_CLASS_ENTRY(dom_attr_class_entry), &name, &name_len, &value, &value_len) == FAILURE) {
php_std_error_handling();
return;
}
@@ -264,7 +264,7 @@
xmlAttrPtr attrp;
xmlNodePtr nodep;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_attr_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_attr_class_entry)) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/cdatasection.c?r1=1.11&r2=1.12&ty=u
Index: php-src/ext/dom/cdatasection.c
diff -u php-src/ext/dom/cdatasection.c:1.11 php-src/ext/dom/cdatasection.c:1.12
--- php-src/ext/dom/cdatasection.c:1.11 Wed Aug 3 10:06:59 2005
+++ php-src/ext/dom/cdatasection.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: cdatasection.c,v 1.11 2005/08/03 14:06:59 sniper Exp $ */
+/* $Id: cdatasection.c,v 1.12 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -50,8 +50,8 @@
char *value = NULL;
int value_len;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_cdatasection_class_entry, &value, &value_len) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_cdatasection_class_entry), &value, &value_len) == FAILURE) {
php_std_error_handling();
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/characterdata.c?r1=1.15&r2=1.16&ty=u
Index: php-src/ext/dom/characterdata.c
diff -u php-src/ext/dom/characterdata.c:1.15 php-src/ext/dom/characterdata.c:1.16
--- php-src/ext/dom/characterdata.c:1.15 Wed Aug 3 10:06:59 2005
+++ php-src/ext/dom/characterdata.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: characterdata.c,v 1.15 2005/08/03 14:06:59 sniper Exp $ */
+/* $Id: characterdata.c,v 1.16 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -154,7 +154,7 @@
int length;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll", &id, dom_characterdata_class_entry, &offset, &count) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll", &id, U_CLASS_ENTRY(dom_characterdata_class_entry), &offset, &count) == FAILURE) {
return;
}
@@ -202,7 +202,7 @@
char *arg;
int arg_len;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_characterdata_class_entry, &arg, &arg_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_characterdata_class_entry), &arg, &arg_len) == FAILURE) {
return;
}
@@ -229,7 +229,7 @@
int length, arg_len;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ols", &id, dom_characterdata_class_entry, &offset, &arg, &arg_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ols", &id, U_CLASS_ENTRY(dom_characterdata_class_entry), &offset, &arg, &arg_len) == FAILURE) {
return;
}
@@ -277,7 +277,7 @@
int length;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll", &id, dom_characterdata_class_entry, &offset, &count) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll", &id, U_CLASS_ENTRY(dom_characterdata_class_entry), &offset, &count) == FAILURE) {
return;
}
@@ -334,7 +334,7 @@
int length, arg_len;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Olls", &id, dom_characterdata_class_entry, &offset, &count, &arg, &arg_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Olls", &id, U_CLASS_ENTRY(dom_characterdata_class_entry), &offset, &count, &arg, &arg_len) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/comment.c?r1=1.11&r2=1.12&ty=u
Index: php-src/ext/dom/comment.c
diff -u php-src/ext/dom/comment.c:1.11 php-src/ext/dom/comment.c:1.12
--- php-src/ext/dom/comment.c:1.11 Wed Aug 3 10:06:59 2005
+++ php-src/ext/dom/comment.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: comment.c,v 1.11 2005/08/03 14:06:59 sniper Exp $ */
+/* $Id: comment.c,v 1.12 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -50,8 +50,8 @@
char *value = NULL;
int value_len;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|s", &id, dom_comment_class_entry, &value, &value_len) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|s", &id, U_CLASS_ENTRY(dom_comment_class_entry), &value, &value_len) == FAILURE) {
php_std_error_handling();
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/document.c?r1=1.68&r2=1.69&ty=u
Index: php-src/ext/dom/document.c
diff -u php-src/ext/dom/document.c:1.68 php-src/ext/dom/document.c:1.69
--- php-src/ext/dom/document.c:1.68 Wed Aug 3 10:06:59 2005
+++ php-src/ext/dom/document.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: document.c,v 1.68 2005/08/03 14:06:59 sniper Exp $ */
+/* $Id: document.c,v 1.69 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -773,7 +773,7 @@
int ret, name_len, value_len;
char *name, *value = NULL;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s", &id, dom_document_class_entry, &name, &name_len, &value, &value_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s", &id, U_CLASS_ENTRY(dom_document_class_entry), &name, &name_len, &value, &value_len) == FAILURE) {
return;
}
@@ -806,7 +806,7 @@
dom_object *intern;
int ret;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_document_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_document_class_entry)) == FAILURE) {
return;
}
@@ -835,7 +835,7 @@
dom_object *intern;
char *value;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &value, &value_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &value, &value_len) == FAILURE) {
return;
}
@@ -864,7 +864,7 @@
dom_object *intern;
char *value;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &value, &value_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &value, &value_len) == FAILURE) {
return;
}
@@ -893,7 +893,7 @@
dom_object *intern;
char *value;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &value, &value_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &value, &value_len) == FAILURE) {
return;
}
@@ -922,7 +922,7 @@
dom_object *intern;
char *name, *value = NULL;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s", &id, dom_document_class_entry, &name, &name_len, &value, &value_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s", &id, U_CLASS_ENTRY(dom_document_class_entry), &name, &name_len, &value, &value_len) == FAILURE) {
return;
}
@@ -958,7 +958,7 @@
dom_object *intern;
char *name;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &name, &name_len) == FAILURE) {
return;
}
@@ -993,7 +993,7 @@
int ret, name_len;
char *name;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &name, &name_len) == FAILURE) {
return;
}
@@ -1027,7 +1027,7 @@
char *name;
xmlChar *local;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &name, &name_len) == FAILURE) {
return;
}
@@ -1055,7 +1055,7 @@
int ret;
long recursive = 0;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO|l", &id, dom_document_class_entry, &node, dom_node_class_entry, &recursive) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO|l", &id, U_CLASS_ENTRY(dom_document_class_entry), &node, U_CLASS_ENTRY(dom_node_class_entry), &recursive) == FAILURE) {
return;
}
@@ -1100,7 +1100,7 @@
int errorcode;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s|s", &id, dom_document_class_entry, &uri, &uri_len, &name, &name_len, &value, &value_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s|s", &id, U_CLASS_ENTRY(dom_document_class_entry), &uri, &uri_len, &name, &name_len, &value, &value_len) == FAILURE) {
return;
}
@@ -1164,7 +1164,7 @@
dom_object *intern;
int errorcode;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, dom_document_class_entry, &uri, &uri_len, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, U_CLASS_ENTRY(dom_document_class_entry), &uri, &uri_len, &name, &name_len) == FAILURE) {
return;
}
@@ -1227,7 +1227,7 @@
char *uri, *name;
xmlChar *local, *nsuri;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, dom_document_class_entry, &uri, &uri_len, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, U_CLASS_ENTRY(dom_document_class_entry), &uri, &uri_len, &name, &name_len) == FAILURE) {
return;
}
@@ -1255,7 +1255,7 @@
dom_object *intern;
char *idname;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &idname, &idname_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &idname, &idname_len) == FAILURE) {
return;
}
@@ -1294,7 +1294,7 @@
xmlDocPtr docp;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_document_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_document_class_entry)) == FAILURE) {
return;
}
@@ -1325,8 +1325,8 @@
char *encoding, *version = NULL;
int encoding_len = 0, version_len = 0, refcount;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|ss", &id, dom_document_class_entry, &version, &version_len, &encoding, &encoding_len) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|ss", &id, U_CLASS_ENTRY(dom_document_class_entry), &version, &version_len, &encoding, &encoding_len) == FAILURE) {
php_std_error_handling();
return;
}
@@ -1552,7 +1552,7 @@
long options = 0;
id = getThis();
- if (id != NULL && ! instanceof_function(Z_OBJCE_P(id), dom_document_class_entry TSRMLS_CC)) {
+ if (id != NULL && ! instanceof_function(Z_OBJCE_P(id), U_CLASS_ENTRY(dom_document_class_entry) TSRMLS_CC)) {
id = NULL;
}
@@ -1630,7 +1630,7 @@
dom_doc_props *doc_props;
char *file;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &file, &file_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &file, &file_len) == FAILURE) {
return;
}
@@ -1669,7 +1669,7 @@
dom_doc_props *doc_props;
int size, format;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|O", &id, dom_document_class_entry, &nodep, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|O", &id, U_CLASS_ENTRY(dom_document_class_entry), &nodep, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1755,7 +1755,7 @@
int err;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|l", &id, dom_document_class_entry, &flags) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|l", &id, U_CLASS_ENTRY(dom_document_class_entry), &flags) == FAILURE) {
return;
}
@@ -1798,7 +1798,7 @@
dom_object *intern;
xmlValidCtxt *cvp;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_document_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_document_class_entry)) == FAILURE) {
return;
}
@@ -1840,7 +1840,7 @@
int is_valid;
char resolved_path[MAXPATHLEN + 1];
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &source, &source_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &source, &source_len) == FAILURE) {
return;
}
@@ -1930,7 +1930,7 @@
int is_valid;
char resolved_path[MAXPATHLEN + 1];
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &source, &source_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &source, &source_len) == FAILURE) {
return;
}
@@ -2054,7 +2054,7 @@
if (!newdoc)
RETURN_FALSE;
- if (id != NULL && instanceof_function(Z_OBJCE_P(id), dom_document_class_entry TSRMLS_CC)) {
+ if (id != NULL && instanceof_function(Z_OBJCE_P(id), U_CLASS_ENTRY(dom_document_class_entry) TSRMLS_CC)) {
intern = (dom_object *)zend_object_store_get_object(id TSRMLS_CC);
if (intern != NULL) {
docp = (xmlDocPtr) dom_object_get_node(intern);
@@ -2111,7 +2111,7 @@
dom_doc_props *doc_props;
char *file;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &file, &file_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_document_class_entry), &file, &file_len) == FAILURE) {
return;
}
@@ -2146,7 +2146,7 @@
xmlChar *mem;
int size;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_document_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_document_class_entry)) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/documentfragment.c?r1=1.15&r2=1.16&ty=u
Index: php-src/ext/dom/documentfragment.c
diff -u php-src/ext/dom/documentfragment.c:1.15 php-src/ext/dom/documentfragment.c:1.16
--- php-src/ext/dom/documentfragment.c:1.15 Wed Aug 3 10:07:00 2005
+++ php-src/ext/dom/documentfragment.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: documentfragment.c,v 1.15 2005/08/03 14:07:00 sniper Exp $ */
+/* $Id: documentfragment.c,v 1.16 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -49,7 +49,7 @@
xmlNodePtr nodep = NULL, oldnode = NULL;
dom_object *intern;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_documentfragment_class_entry) == FAILURE) {
php_std_error_handling();
return;
http://cvs.php.net/diff.php/php-src/ext/dom/dom_iterators.c?r1=1.9&r2=1.10&ty=u
Index: php-src/ext/dom/dom_iterators.c
diff -u php-src/ext/dom/dom_iterators.c:1.9 php-src/ext/dom/dom_iterators.c:1.10
--- php-src/ext/dom/dom_iterators.c:1.9 Wed Aug 3 10:07:01 2005
+++ php-src/ext/dom/dom_iterators.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dom_iterators.c,v 1.9 2005/08/03 14:07:01 sniper Exp $ */
+/* $Id: dom_iterators.c,v 1.10 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -161,7 +161,7 @@
object = (zval *)iterator->intern.data;
- if (instanceof_function(Z_OBJCE_P(object), dom_nodelist_class_entry TSRMLS_CC)) {
+ if (instanceof_function(Z_OBJCE_P(object), U_CLASS_ENTRY(dom_nodelist_class_entry) TSRMLS_CC)) {
*int_key = iter->index - 1;
return HASH_KEY_IS_LONG;
} else {
http://cvs.php.net/diff.php/php-src/ext/dom/domexception.c?r1=1.11&r2=1.12&ty=u
Index: php-src/ext/dom/domexception.c
diff -u php-src/ext/dom/domexception.c:1.11 php-src/ext/dom/domexception.c:1.12
--- php-src/ext/dom/domexception.c:1.11 Wed Aug 3 10:07:02 2005
+++ php-src/ext/dom/domexception.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: domexception.c,v 1.11 2005/08/03 14:07:02 sniper Exp $ */
+/* $Id: domexception.c,v 1.12 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -45,7 +45,7 @@
void php_dom_throw_error_with_message(int error_code, char *error_message, int strict_error TSRMLS_DC)
{
if (strict_error == 1) {
- zend_throw_exception(dom_domexception_class_entry, error_message, error_code TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(dom_domexception_class_entry), error_message, error_code TSRMLS_CC);
} else {
php_libxml_issue_error(E_WARNING, error_message TSRMLS_CC);
}
http://cvs.php.net/diff.php/php-src/ext/dom/domimplementation.c?r1=1.15&r2=1.16&ty=u
Index: php-src/ext/dom/domimplementation.c
diff -u php-src/ext/dom/domimplementation.c:1.15 php-src/ext/dom/domimplementation.c:1.16
--- php-src/ext/dom/domimplementation.c:1.15 Wed Aug 3 10:07:02 2005
+++ php-src/ext/dom/domimplementation.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: domimplementation.c,v 1.15 2005/08/03 14:07:02 sniper Exp $ */
+/* $Id: domimplementation.c,v 1.16 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -134,7 +134,7 @@
char *prefix = NULL, *localname = NULL;
dom_object *doctobj;
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|ssO", &uri, &uri_len, &name, &name_len, &node, dom_documenttype_class_entry) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|ssO", &uri, &uri_len, &name, &name_len, &node, U_CLASS_ENTRY(dom_documenttype_class_entry)) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/element.c?r1=1.36&r2=1.37&ty=u
Index: php-src/ext/dom/element.c
diff -u php-src/ext/dom/element.c:1.36 php-src/ext/dom/element.c:1.37
--- php-src/ext/dom/element.c:1.36 Wed Aug 3 10:07:03 2005
+++ php-src/ext/dom/element.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: element.c,v 1.36 2005/08/03 14:07:03 sniper Exp $ */
+/* $Id: element.c,v 1.37 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -71,8 +71,8 @@
int name_len, value_len = 0, name_valid;
xmlNsPtr nsptr = NULL;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s!s", &id, dom_element_class_entry, &name, &name_len, &value, &value_len, &uri, &uri_len) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s!s", &id, U_CLASS_ENTRY(dom_element_class_entry), &name, &name_len, &value, &value_len, &uri, &uri_len) == FAILURE) {
php_std_error_handling();
return;
}
@@ -202,7 +202,7 @@
dom_object *intern;
int name_len;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_element_class_entry, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_element_class_entry), &name, &name_len) == FAILURE) {
return;
}
@@ -233,7 +233,7 @@
char *name, *value;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, dom_element_class_entry, &name, &name_len, &value, &value_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, U_CLASS_ENTRY(dom_element_class_entry), &name, &name_len, &value, &value_len) == FAILURE) {
return;
}
@@ -278,7 +278,7 @@
int name_len;
char *name;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_element_class_entry, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_element_class_entry), &name, &name_len) == FAILURE) {
return;
}
@@ -322,7 +322,7 @@
dom_object *intern;
char *name;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_element_class_entry, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_element_class_entry), &name, &name_len) == FAILURE) {
return;
}
@@ -350,7 +350,7 @@
dom_object *intern, *attrobj, *oldobj;
int ret;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, dom_element_class_entry, &node, dom_attr_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, U_CLASS_ENTRY(dom_element_class_entry), &node, U_CLASS_ENTRY(dom_attr_class_entry)) == FAILURE) {
return;
}
@@ -408,7 +408,7 @@
dom_object *intern, *attrobj;
int ret;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, dom_element_class_entry, &node, dom_attr_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, U_CLASS_ENTRY(dom_element_class_entry), &node, U_CLASS_ENTRY(dom_attr_class_entry)) == FAILURE) {
return;
}
@@ -447,7 +447,7 @@
char *name;
xmlChar *local;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_element_class_entry, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_element_class_entry), &name, &name_len) == FAILURE) {
return;
}
@@ -474,7 +474,7 @@
int uri_len = 0, name_len = 0;
char *uri, *name, *strattr;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, dom_element_class_entry, &uri, &uri_len, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, U_CLASS_ENTRY(dom_element_class_entry), &uri, &uri_len, &name, &name_len) == FAILURE) {
return;
}
@@ -518,7 +518,7 @@
dom_object *intern;
int errorcode = 0, stricterror, is_xmlns = 0;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!ss", &id, dom_element_class_entry, &uri, &uri_len, &name, &name_len, &value, &value_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!ss", &id, U_CLASS_ENTRY(dom_element_class_entry), &uri, &uri_len, &name, &name_len, &value, &value_len) == FAILURE) {
return;
}
@@ -614,7 +614,7 @@
int name_len, uri_len;
char *name, *uri;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, dom_element_class_entry, &uri, &uri_len, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, U_CLASS_ENTRY(dom_element_class_entry), &uri, &uri_len, &name, &name_len) == FAILURE) {
return;
}
@@ -671,7 +671,7 @@
int uri_len, name_len, ret;
char *uri, *name;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, dom_element_class_entry, &uri, &uri_len, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, U_CLASS_ENTRY(dom_element_class_entry), &uri, &uri_len, &name, &name_len) == FAILURE) {
return;
}
@@ -702,7 +702,7 @@
dom_object *intern, *attrobj, *oldobj;
int ret;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, dom_element_class_entry, &node, dom_attr_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, U_CLASS_ENTRY(dom_element_class_entry), &node, U_CLASS_ENTRY(dom_attr_class_entry)) == FAILURE) {
return;
}
@@ -768,7 +768,7 @@
char *uri, *name;
xmlChar *local, *nsuri;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, dom_element_class_entry, &uri, &uri_len, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, U_CLASS_ENTRY(dom_element_class_entry), &uri, &uri_len, &name, &name_len) == FAILURE) {
return;
}
@@ -796,7 +796,7 @@
char *name, *value;
int name_len;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_element_class_entry, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_element_class_entry), &name, &name_len) == FAILURE) {
return;
}
@@ -826,7 +826,7 @@
int uri_len, name_len;
char *uri, *name, *value;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, dom_element_class_entry, &uri, &uri_len, &name, &name_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, U_CLASS_ENTRY(dom_element_class_entry), &uri, &uri_len, &name, &name_len) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/entityreference.c?r1=1.12&r2=1.13&ty=u
Index: php-src/ext/dom/entityreference.c
diff -u php-src/ext/dom/entityreference.c:1.12 php-src/ext/dom/entityreference.c:1.13
--- php-src/ext/dom/entityreference.c:1.12 Wed Aug 3 10:07:04 2005
+++ php-src/ext/dom/entityreference.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: entityreference.c,v 1.12 2005/08/03 14:07:04 sniper Exp $ */
+/* $Id: entityreference.c,v 1.13 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -50,8 +50,8 @@
char *name;
int name_len, name_valid;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_entityreference_class_entry, &name, &name_len) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_entityreference_class_entry), &name, &name_len) == FAILURE) {
php_std_error_handling();
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/namednodemap.c?r1=1.15&r2=1.16&ty=u
Index: php-src/ext/dom/namednodemap.c
diff -u php-src/ext/dom/namednodemap.c:1.15 php-src/ext/dom/namednodemap.c:1.16
--- php-src/ext/dom/namednodemap.c:1.15 Wed Aug 3 10:07:04 2005
+++ php-src/ext/dom/namednodemap.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: namednodemap.c,v 1.15 2005/08/03 14:07:04 sniper Exp $ */
+/* $Id: namednodemap.c,v 1.16 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -104,7 +104,7 @@
xmlNodePtr nodep;
xmlNotation *notep = NULL;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_namednodemap_class_entry, &named, &namedlen) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_namednodemap_class_entry), &named, &namedlen) == FAILURE) {
return;
}
@@ -176,7 +176,7 @@
xmlNodePtr nodep, curnode;
int count;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &id, dom_namednodemap_class_entry, &index) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &id, U_CLASS_ENTRY(dom_namednodemap_class_entry), &index) == FAILURE) {
return;
}
if (index >= 0) {
@@ -232,7 +232,7 @@
xmlNodePtr nodep;
xmlNotation *notep = NULL;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, dom_namednodemap_class_entry, &uri, &urilen, &named, &namedlen) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os!s", &id, U_CLASS_ENTRY(dom_namednodemap_class_entry), &uri, &urilen, &named, &namedlen) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/node.c?r1=1.37&r2=1.38&ty=u
Index: php-src/ext/dom/node.c
diff -u php-src/ext/dom/node.c:1.37 php-src/ext/dom/node.c:1.38
--- php-src/ext/dom/node.c:1.37 Wed Aug 3 10:07:04 2005
+++ php-src/ext/dom/node.c Fri Aug 12 07:29:29 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: node.c,v 1.37 2005/08/03 14:07:04 sniper Exp $ */
+/* $Id: node.c,v 1.38 2005/08/12 11:29:29 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -913,7 +913,7 @@
dom_object *intern, *childobj, *refpobj;
int ret, stricterror;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO|O!", &id, dom_node_class_entry, &node, dom_node_class_entry, &ref, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO|O!", &id, U_CLASS_ENTRY(dom_node_class_entry), &node, U_CLASS_ENTRY(dom_node_class_entry), &ref, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1077,7 +1077,7 @@
int ret;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OOO", &id, dom_node_class_entry, &newnode, dom_node_class_entry, &oldnode, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OOO", &id, U_CLASS_ENTRY(dom_node_class_entry), &newnode, U_CLASS_ENTRY(dom_node_class_entry), &oldnode, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1167,7 +1167,7 @@
dom_object *intern, *childobj;
int ret, stricterror;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, dom_node_class_entry, &node, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, U_CLASS_ENTRY(dom_node_class_entry), &node, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1220,7 +1220,7 @@
dom_object *intern, *childobj;
int ret, stricterror;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, dom_node_class_entry, &node, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, U_CLASS_ENTRY(dom_node_class_entry), &node, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1321,7 +1321,7 @@
xmlNode *nodep;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1353,7 +1353,7 @@
dom_object *intern;
long recursive = 0;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|l", &id, dom_node_class_entry, &recursive) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|l", &id, U_CLASS_ENTRY(dom_node_class_entry), &recursive) == FAILURE) {
return;
}
@@ -1414,7 +1414,7 @@
xmlNode *nodep;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1436,7 +1436,7 @@
int feature_len, version_len;
char *feature, *version;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, dom_node_class_entry, &feature, &feature_len, &version, &version_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, U_CLASS_ENTRY(dom_node_class_entry), &feature, &feature_len, &version, &version_len) == FAILURE) {
return;
}
@@ -1459,7 +1459,7 @@
xmlNode *nodep;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1497,7 +1497,7 @@
xmlNodePtr nodeotherp, nodep;
dom_object *intern, *nodeotherobj;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, dom_node_class_entry, &node, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, U_CLASS_ENTRY(dom_node_class_entry), &node, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
@@ -1527,7 +1527,7 @@
int uri_len = 0;
char *uri;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_node_class_entry, &uri, &uri_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_node_class_entry), &uri, &uri_len) == FAILURE) {
return;
}
@@ -1578,7 +1578,7 @@
int uri_len = 0;
char *uri;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_node_class_entry, &uri, &uri_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_node_class_entry), &uri, &uri_len) == FAILURE) {
return;
}
@@ -1609,7 +1609,7 @@
int prefix_len = 0;
char *prefix;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_node_class_entry, &prefix, &prefix_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, U_CLASS_ENTRY(dom_node_class_entry), &prefix, &prefix_len) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/nodelist.c?r1=1.17&r2=1.18&ty=u
Index: php-src/ext/dom/nodelist.c
diff -u php-src/ext/dom/nodelist.c:1.17 php-src/ext/dom/nodelist.c:1.18
--- php-src/ext/dom/nodelist.c:1.17 Wed Aug 3 10:07:04 2005
+++ php-src/ext/dom/nodelist.c Fri Aug 12 07:29:30 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: nodelist.c,v 1.17 2005/08/03 14:07:04 sniper Exp $ */
+/* $Id: nodelist.c,v 1.18 2005/08/12 11:29:30 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -111,7 +111,7 @@
HashTable *nodeht;
pval **entry;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &id, dom_nodelist_class_entry, &index) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &id, U_CLASS_ENTRY(dom_nodelist_class_entry), &index) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/php_dom.c?r1=1.74&r2=1.75&ty=u
Index: php-src/ext/dom/php_dom.c
diff -u php-src/ext/dom/php_dom.c:1.74 php-src/ext/dom/php_dom.c:1.75
--- php-src/ext/dom/php_dom.c:1.74 Thu Aug 11 19:35:53 2005
+++ php-src/ext/dom/php_dom.c Fri Aug 12 07:29:30 2005
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: php_dom.c,v 1.74 2005/08/11 23:35:53 andrei Exp $ */
+/* $Id: php_dom.c,v 1.75 2005/08/12 11:29:30 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -973,7 +973,7 @@
clone = dom_objects_set_class(intern->std.ce, 0 TSRMLS_CC);
- if (instanceof_function(intern->std.ce, dom_node_class_entry TSRMLS_CC)) {
+ if (instanceof_function(intern->std.ce, U_CLASS_ENTRY(dom_node_class_entry) TSRMLS_CC)) {
node = (xmlNodePtr)dom_object_get_node((dom_object *) object);
if (node != NULL) {
cloned_node = xmlDocCopyNode(node, node->doc, 1);
@@ -1094,9 +1094,9 @@
zend_class_entry *ce;
if (ce_type == DOM_NAMEDNODEMAP) {
- ce = dom_namednodemap_class_entry;
+ ce = U_CLASS_ENTRY(dom_namednodemap_class_entry);
} else {
- ce = dom_nodelist_class_entry;
+ ce = U_CLASS_ENTRY(dom_nodelist_class_entry);
}
object_init_ex(return_value, ce);
@@ -1133,69 +1133,69 @@
case XML_DOCUMENT_NODE:
case XML_HTML_DOCUMENT_NODE:
{
- ce = dom_document_class_entry;
+ ce = U_CLASS_ENTRY(dom_document_class_entry);
break;
}
case XML_DTD_NODE:
case XML_DOCUMENT_TYPE_NODE:
{
- ce = dom_documenttype_class_entry;
+ ce = U_CLASS_ENTRY(dom_documenttype_class_entry);
break;
}
case XML_ELEMENT_NODE:
{
- ce = dom_element_class_entry;
+ ce = U_CLASS_ENTRY(dom_element_class_entry);
break;
}
case XML_ATTRIBUTE_NODE:
{
- ce = dom_attr_class_entry;
+ ce = U_CLASS_ENTRY(dom_attr_class_entry);
break;
}
case XML_TEXT_NODE:
{
- ce = dom_text_class_entry;
+ ce = U_CLASS_ENTRY(dom_text_class_entry);
break;
}
case XML_COMMENT_NODE:
{
- ce = dom_comment_class_entry;
+ ce = U_CLASS_ENTRY(dom_comment_class_entry);
break;
}
case XML_PI_NODE:
{
- ce = dom_processinginstruction_class_entry;
+ ce = U_CLASS_ENTRY(dom_processinginstruction_class_entry);
break;
}
case XML_ENTITY_REF_NODE:
{
- ce = dom_entityreference_class_entry;
+ ce = U_CLASS_ENTRY(dom_entityreference_class_entry);
break;
}
case XML_ENTITY_DECL:
case XML_ELEMENT_DECL:
{
- ce = dom_entity_class_entry;
+ ce = U_CLASS_ENTRY(dom_entity_class_entry);
break;
}
case XML_CDATA_SECTION_NODE:
{
- ce = dom_cdatasection_class_entry;
+ ce = U_CLASS_ENTRY(dom_cdatasection_class_entry);
break;
}
case XML_DOCUMENT_FRAG_NODE:
{
- ce = dom_documentfragment_class_entry;
+ ce = U_CLASS_ENTRY(dom_documentfragment_class_entry);
break;
}
case XML_NOTATION_NODE:
{
- ce = dom_notation_class_entry;
+ ce = U_CLASS_ENTRY(dom_notation_class_entry);
break;
}
case XML_NAMESPACE_DECL:
{
- ce = dom_namespace_node_class_entry;
+ ce = U_CLASS_ENTRY(dom_namespace_node_class_entry);
break;
}
default:
@@ -1221,7 +1221,7 @@
void php_dom_create_implementation(zval **retval TSRMLS_DC) {
- object_init_ex(*retval, dom_domimplementation_class_entry);
+ object_init_ex(*retval, U_CLASS_ENTRY(dom_domimplementation_class_entry));
}
/* {{{ int dom_hierarchy(xmlNodePtr parent, xmlNodePtr child) */
http://cvs.php.net/diff.php/php-src/ext/dom/processinginstruction.c?r1=1.17&r2=1.18&ty=u
Index: php-src/ext/dom/processinginstruction.c
diff -u php-src/ext/dom/processinginstruction.c:1.17 php-src/ext/dom/processinginstruction.c:1.18
--- php-src/ext/dom/processinginstruction.c:1.17 Wed Aug 3 10:07:05 2005
+++ php-src/ext/dom/processinginstruction.c Fri Aug 12 07:29:30 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: processinginstruction.c,v 1.17 2005/08/03 14:07:05 sniper Exp $ */
+/* $Id: processinginstruction.c,v 1.18 2005/08/12 11:29:30 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -50,8 +50,8 @@
char *name, *value = NULL;
int name_len, value_len, name_valid;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s", &id, dom_processinginstruction_class_entry, &name, &name_len, &value, &value_len) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|s", &id, U_CLASS_ENTRY(dom_processinginstruction_class_entry), &name, &name_len, &value, &value_len) == FAILURE) {
php_std_error_handling();
return;
}
http://cvs.php.net/diff.php/php-src/ext/dom/text.c?r1=1.23&r2=1.24&ty=u
Index: php-src/ext/dom/text.c
diff -u php-src/ext/dom/text.c:1.23 php-src/ext/dom/text.c:1.24
--- php-src/ext/dom/text.c:1.23 Wed Aug 3 10:07:06 2005
+++ php-src/ext/dom/text.c Fri Aug 12 07:29:30 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: text.c,v 1.23 2005/08/03 14:07:06 sniper Exp $ */
+/* $Id: text.c,v 1.24 2005/08/12 11:29:30 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -54,8 +54,8 @@
char *value = NULL;
int value_len;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|s", &id, dom_text_class_entry, &value, &value_len) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O|s", &id, U_CLASS_ENTRY(dom_text_class_entry), &value, &value_len) == FAILURE) {
php_std_error_handling();
return;
}
@@ -125,7 +125,7 @@
int length;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &id, dom_text_class_entry, &offset) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Ol", &id, U_CLASS_ENTRY(dom_text_class_entry), &offset) == FAILURE) {
return;
}
DOM_GET_OBJ(node, id, xmlNodePtr, intern);
@@ -177,7 +177,7 @@
xmlNodePtr node;
dom_object *intern;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, dom_text_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O", &id, U_CLASS_ENTRY(dom_text_class_entry)) == FAILURE) {
return;
}
DOM_GET_OBJ(node, id, xmlNodePtr, intern);
http://cvs.php.net/diff.php/php-src/ext/dom/xpath.c?r1=1.26&r2=1.27&ty=u
Index: php-src/ext/dom/xpath.c
diff -u php-src/ext/dom/xpath.c:1.26 php-src/ext/dom/xpath.c:1.27
--- php-src/ext/dom/xpath.c:1.26 Wed Aug 3 10:07:06 2005
+++ php-src/ext/dom/xpath.c Fri Aug 12 07:29:30 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: xpath.c,v 1.26 2005/08/03 14:07:06 sniper Exp $ */
+/* $Id: xpath.c,v 1.27 2005/08/12 11:29:30 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -52,8 +52,8 @@
dom_object *docobj, *intern;
xmlXPathContextPtr ctx, oldctx;
- php_set_error_handling(EH_THROW, dom_domexception_class_entry TSRMLS_CC);
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, dom_xpath_class_entry, &doc, dom_document_class_entry) == FAILURE) {
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(dom_domexception_class_entry) TSRMLS_CC);
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "OO", &id, U_CLASS_ENTRY(dom_xpath_class_entry), &doc, U_CLASS_ENTRY(dom_document_class_entry)) == FAILURE) {
php_std_error_handling();
return;
}
@@ -111,7 +111,7 @@
dom_object *intern;
unsigned char *prefix, *ns_uri;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, dom_xpath_class_entry, &prefix, &prefix_len, &ns_uri, &ns_uri_len) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oss", &id, U_CLASS_ENTRY(dom_xpath_class_entry), &prefix, &prefix_len, &ns_uri, &ns_uri_len) == FAILURE) {
return;
}
@@ -151,7 +151,7 @@
xmlNsPtr *ns;
- if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|O", &id, dom_xpath_class_entry, &expr, &expr_len, &context, dom_node_class_entry) == FAILURE) {
+ if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os|O", &id, U_CLASS_ENTRY(dom_xpath_class_entry), &expr, &expr_len, &context, U_CLASS_ENTRY(dom_node_class_entry)) == FAILURE) {
return;
}
http://cvs.php.net/diff.php/php-src/ext/pdo/pdo.c?r1=1.57&r2=1.58&ty=u
Index: php-src/ext/pdo/pdo.c
diff -u php-src/ext/pdo/pdo.c:1.57 php-src/ext/pdo/pdo.c:1.58
--- php-src/ext/pdo/pdo.c:1.57 Tue Jul 26 22:39:11 2005
+++ php-src/ext/pdo/pdo.c Fri Aug 12 07:29:30 2005
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: pdo.c,v 1.57 2005/07/27 02:39:11 wez Exp $ */
+/* $Id: pdo.c,v 1.58 2005/08/12 11:29:30 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -57,7 +57,7 @@
PDO_API zend_class_entry *php_pdo_get_exception(void)
{
- return pdo_exception_ce;
+ return U_CLASS_ENTRY(pdo_exception_ce);
}
zend_class_entry *pdo_dbh_ce, *pdo_dbstmt_ce, *pdo_row_ce;
http://cvs.php.net/diff.php/php-src/ext/pdo/pdo_dbh.c?r1=1.82&r2=1.83&ty=u
Index: php-src/ext/pdo/pdo_dbh.c
diff -u php-src/ext/pdo/pdo_dbh.c:1.82 php-src/ext/pdo/pdo_dbh.c:1.83
--- php-src/ext/pdo/pdo_dbh.c:1.82 Mon Jul 11 22:40:59 2005
+++ php-src/ext/pdo/pdo_dbh.c Fri Aug 12 07:29:30 2005
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: pdo_dbh.c,v 1.82 2005/07/12 02:40:59 wez Exp $ */
+/* $Id: pdo_dbh.c,v 1.83 2005/08/12 11:29:30 dmitry Exp $ */
/* The PDO Database Handle Class */
@@ -512,7 +512,7 @@
RETURN_FALSE;
}
dbstmt_ce = *pce;
- if (!instanceof_function(dbstmt_ce, pdo_dbstmt_ce TSRMLS_CC)) {
+ if (!instanceof_function(dbstmt_ce, U_CLASS_ENTRY(pdo_dbstmt_ce) TSRMLS_CC)) {
pdo_raise_impl_error(dbh, NULL, "HY000",
"user-supplied statement class must be derived from PDOStatement" TSRMLS_CC);
PDO_HANDLE_DBH_ERR();
@@ -538,7 +538,7 @@
ctor_args = NULL;
}
} else {
- dbstmt_ce = pdo_dbstmt_ce;
+ dbstmt_ce = U_CLASS_ENTRY(pdo_dbstmt_ce);
ctor_args = NULL;
}
@@ -880,7 +880,7 @@
PDO_DBH_CLEAR_ERR();
- if (!pdo_stmt_instantiate(dbh, return_value, pdo_dbstmt_ce, NULL TSRMLS_CC)) {
+ if (!pdo_stmt_instantiate(dbh, return_value, U_CLASS_ENTRY(pdo_dbstmt_ce), NULL TSRMLS_CC)) {
pdo_raise_impl_error(dbh, NULL, "HY000", "failed to instantiate user supplied statement class" TSRMLS_CC);
return;
}
@@ -914,7 +914,7 @@
stmt->executed = 1;
}
if (ret) {
- pdo_stmt_construct(stmt, return_value, pdo_dbstmt_ce, NULL TSRMLS_CC);
+ pdo_stmt_construct(stmt, return_value, U_CLASS_ENTRY(pdo_dbstmt_ce), NULL TSRMLS_CC);
return;
}
}
http://cvs.php.net/diff.php/php-src/ext/pdo/pdo_stmt.c?r1=1.118&r2=1.119&ty=u
Index: php-src/ext/pdo/pdo_stmt.c
diff -u php-src/ext/pdo/pdo_stmt.c:1.118 php-src/ext/pdo/pdo_stmt.c:1.119
--- php-src/ext/pdo/pdo_stmt.c:1.118 Wed Aug 3 14:26:16 2005
+++ php-src/ext/pdo/pdo_stmt.c Fri Aug 12 07:29:30 2005
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: pdo_stmt.c,v 1.118 2005/08/03 18:26:16 iliaa Exp $ */
+/* $Id: pdo_stmt.c,v 1.119 2005/08/12 11:29:30 dmitry Exp $ */
/* The PDO Statement Handle Class */
@@ -2285,7 +2285,7 @@
static zend_class_entry *row_get_ce(zval *object TSRMLS_DC)
{
- return pdo_dbstmt_ce;
+ return U_CLASS_ENTRY(pdo_dbstmt_ce);
}
static int row_get_classname(zval *object, char **class_name, zend_uint *class_name_len, int parent TSRMLS_DC)
http://cvs.php.net/diff.php/php-src/ext/simplexml/simplexml.c?r1=1.152&r2=1.153&ty=u
Index: php-src/ext/simplexml/simplexml.c
diff -u php-src/ext/simplexml/simplexml.c:1.152 php-src/ext/simplexml/simplexml.c:1.153
--- php-src/ext/simplexml/simplexml.c:1.152 Thu Aug 11 19:35:55 2005
+++ php-src/ext/simplexml/simplexml.c Fri Aug 12 07:29:31 2005
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: simplexml.c,v 1.152 2005/08/11 23:35:55 andrei Exp $ */
+/* $Id: simplexml.c,v 1.153 2005/08/12 11:29:31 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -42,7 +42,7 @@
ZEND_API zend_class_entry *sxe_get_element_class_entry()
{
- return sxe_class_entry;
+ return U_CLASS_ENTRY(sxe_class_entry);
}
#define SXE_ME(func, arg_info, flags) PHP_ME(simplexml_element, func, arg_info, flags)
@@ -1271,7 +1271,7 @@
xmlDocPtr docp;
char *classname = "";
int classname_len = 0, options=0;
- zend_class_entry *ce= sxe_class_entry;
+ zend_class_entry *ce= U_CLASS_ENTRY(sxe_class_entry);
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|sl", &filename, &filename_len, &classname, &classname_len, &options) == FAILURE) {
return;
@@ -1314,7 +1314,7 @@
xmlDocPtr docp;
char *classname = "";
int classname_len = 0, options=0;
- zend_class_entry *ce= sxe_class_entry;
+ zend_class_entry *ce= U_CLASS_ENTRY(sxe_class_entry);
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|sl", &data, &data_len, &classname, &classname_len, &options) == FAILURE) {
return;
@@ -1600,7 +1600,7 @@
xmlNodePtr nodep = NULL;
char *classname = "";
int classname_len = 0;
- zend_class_entry *ce= sxe_class_entry;
+ zend_class_entry *ce= U_CLASS_ENTRY(sxe_class_entry);
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "o|s", &node, &classname, &classname_len) == FAILURE) {
return;
@@ -1736,7 +1736,7 @@
{
php_info_print_table_start();
php_info_print_table_header(2, "Simplexml support", "enabled");
- php_info_print_table_row(2, "Revision", "$Revision: 1.152 $");
+ php_info_print_table_row(2, "Revision", "$Revision: 1.153 $");
php_info_print_table_row(2, "Schema support",
#ifdef LIBXML_SCHEMAS_ENABLED
"enabled");
http://cvs.php.net/diff.php/php-src/ext/spl/php_spl.c?r1=1.56&r2=1.57&ty=u
Index: php-src/ext/spl/php_spl.c
diff -u php-src/ext/spl/php_spl.c:1.56 php-src/ext/spl/php_spl.c:1.57
--- php-src/ext/spl/php_spl.c:1.56 Wed Aug 10 21:19:10 2005
+++ php-src/ext/spl/php_spl.c Fri Aug 12 07:29:32 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: php_spl.c,v 1.56 2005/08/11 01:19:10 helly Exp $ */
+/* $Id: php_spl.c,v 1.57 2005/08/12 11:29:32 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -293,7 +293,7 @@
EG(function_state_ptr) = original_function_state_ptr;
if (!found) {
- zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Class %s could not be loaded", class_name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_LogicException), 0 TSRMLS_CC, "Class %s could not be loaded", class_name);
}
} /* }}} */
@@ -386,7 +386,7 @@
}
if (!zend_is_callable_ex(zcallable, 0, &func_name, &func_name_len, &alfi.func_ptr, &obj_ptr TSRMLS_CC)) {
if (do_throw) {
- zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Passed array does not specify a callable static method");
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_LogicException), 0 TSRMLS_CC, "Passed array does not specify a callable static method");
}
if (func_name) {
efree(func_name);
@@ -394,7 +394,7 @@
return;
} else if (!obj_ptr && !(alfi.func_ptr->common.fn_flags & ZEND_ACC_STATIC)) {
if (do_throw) {
- zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Passed array specifies a non static method but no object");
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_LogicException), 0 TSRMLS_CC, "Passed array specifies a non static method but no object");
}
if (func_name) {
efree(func_name);
@@ -420,7 +420,7 @@
if (!strcmp(lc_name, "spl_autoload_call")) {
if (do_throw) {
- zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Function spl_autoload_call() cannot be registered", func_name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_LogicException), 0 TSRMLS_CC, "Function spl_autoload_call() cannot be registered", func_name);
}
free_alloca(lc_name);
return;
@@ -428,7 +428,7 @@
if (zend_hash_find(EG(function_table), lc_name, func_name_len+1, (void **) &alfi.func_ptr) == FAILURE) {
if (do_throw) {
- zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Function '%s' not found", func_name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_LogicException), 0 TSRMLS_CC, "Function '%s' not found", func_name);
}
free_alloca(lc_name);
return;
http://cvs.php.net/diff.php/php-src/ext/spl/spl_array.c?r1=1.73&r2=1.74&ty=u
Index: php-src/ext/spl/spl_array.c
diff -u php-src/ext/spl/spl_array.c:1.73 php-src/ext/spl/spl_array.c:1.74
--- php-src/ext/spl/spl_array.c:1.73 Thu Aug 11 19:35:55 2005
+++ php-src/ext/spl/spl_array.c Fri Aug 12 07:29:32 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: spl_array.c,v 1.73 2005/08/11 23:35:55 andrei Exp $ */
+/* $Id: spl_array.c,v 1.74 2005/08/12 11:29:32 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
# include "config.h"
@@ -244,10 +244,10 @@
retval.handle = zend_objects_store_put(intern, NULL, (zend_objects_free_object_storage_t) spl_array_object_free_storage, NULL TSRMLS_CC);
while (parent) {
- if (parent == spl_ce_ArrayIterator) {
+ if (parent == U_CLASS_ENTRY(spl_ce_ArrayIterator)) {
retval.handlers = &spl_handler_ArrayIterator;
break;
- } else if (parent == spl_ce_ArrayObject) {
+ } else if (parent == U_CLASS_ENTRY(spl_ce_ArrayObject)) {
retval.handlers = &spl_handler_ArrayObject;
break;
}
@@ -876,7 +876,7 @@
if (ZEND_NUM_ARGS() == 0) {
return; /* nothing to do */
}
- php_set_error_handling(EH_THROW, spl_ce_InvalidArgumentException TSRMLS_CC);
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(spl_ce_InvalidArgumentException) TSRMLS_CC);
intern = (spl_array_object*)zend_object_store_get_object(object TSRMLS_CC);
@@ -899,7 +899,7 @@
} else {
if (Z_TYPE_P(array) != IS_OBJECT && Z_TYPE_P(array) != IS_ARRAY) {
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
- zend_throw_exception(spl_ce_InvalidArgumentException, "Passed variable is not an array or object, using empty array instead", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_InvalidArgumentException), "Passed variable is not an array or object, using empty array instead", 0 TSRMLS_CC);
return;
}
zval_ptr_dtor(&intern->array);
@@ -970,7 +970,7 @@
intern->array = other->array;
} else {
if (Z_TYPE_PP(array) != IS_OBJECT && !HASH_OF(*array)) {
- zend_throw_exception(spl_ce_InvalidArgumentException, "Passed variable is not an array or object, using empty array instead", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_InvalidArgumentException), "Passed variable is not an array or object, using empty array instead", 0 TSRMLS_CC);
return;
}
zval_ptr_dtor(&intern->array);
@@ -1002,7 +1002,7 @@
}
return_value->type = IS_OBJECT;
- return_value->value.obj = spl_array_object_new_ex(spl_ce_ArrayIterator, &iterator, object TSRMLS_CC);
+ return_value->value.obj = spl_array_object_new_ex(U_CLASS_ENTRY(spl_ce_ArrayIterator), &iterator, object TSRMLS_CC);
return_value->refcount = 1;
return_value->is_ref = 1;
}
@@ -1053,7 +1053,7 @@
}
}
}
- zend_throw_exception_ex(spl_ce_OutOfBoundsException, 0 TSRMLS_CC, "Seek position %ld is out of range", opos);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_OutOfBoundsException), 0 TSRMLS_CC, "Seek position %ld is out of range", opos);
} /* }}} */
int spl_array_object_count_elements(zval *object, long *count TSRMLS_DC) /* {{{ */
http://cvs.php.net/diff.php/php-src/ext/spl/spl_directory.c?r1=1.45&r2=1.46&ty=u
Index: php-src/ext/spl/spl_directory.c
diff -u php-src/ext/spl/spl_directory.c:1.45 php-src/ext/spl/spl_directory.c:1.46
--- php-src/ext/spl/spl_directory.c:1.45 Wed Aug 3 10:07:53 2005
+++ php-src/ext/spl/spl_directory.c Fri Aug 12 07:29:32 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: spl_directory.c,v 1.45 2005/08/03 14:07:53 sniper Exp $ */
+/* $Id: spl_directory.c,v 1.46 2005/08/12 11:29:32 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
# include "config.h"
@@ -191,7 +191,7 @@
char *path;
int len;
- php_set_error_handling(EH_THROW, spl_ce_RuntimeException TSRMLS_CC);
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(spl_ce_RuntimeException) TSRMLS_CC);
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &path, &len) == FAILURE) {
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
@@ -437,10 +437,10 @@
spl_file_object *intern;
zend_bool use_include_path = 0;
- php_set_error_handling(EH_THROW, spl_ce_RuntimeException TSRMLS_CC);
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(spl_ce_RuntimeException) TSRMLS_CC);
if (!dir_obj->entry.d_name[0]) {
- zend_throw_exception_ex(spl_ce_RuntimeException, 0 TSRMLS_CC, "Could not open file");
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_RuntimeException), 0 TSRMLS_CC, "Could not open file");
zval_dtor(return_value);
return;
}
@@ -945,7 +945,7 @@
if (php_stream_eof(intern->stream)) {
if (!silent) {
- zend_throw_exception_ex(spl_ce_RuntimeException, 0 TSRMLS_CC, "Cannot read from file %s", intern->file_name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_RuntimeException), 0 TSRMLS_CC, "Cannot read from file %s", intern->file_name);
}
return FAILURE;
}
@@ -982,7 +982,7 @@
if (intern->func_getCurr->common.scope != spl_ce_FileObject) {
if (php_stream_eof(intern->stream)) {
if (!silent) {
- zend_throw_exception_ex(spl_ce_RuntimeException, 0 TSRMLS_CC, "Cannot read from file %s", intern->file_name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_RuntimeException), 0 TSRMLS_CC, "Cannot read from file %s", intern->file_name);
}
return FAILURE;
}
@@ -1012,7 +1012,7 @@
static void spl_file_object_rewind(spl_file_object *intern TSRMLS_DC) /* {{{ */
{
if (-1 == php_stream_rewind(intern->stream)) {
- zend_throw_exception_ex(spl_ce_RuntimeException, 0 TSRMLS_CC, "Cannot rewind file %s", intern->file_name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_RuntimeException), 0 TSRMLS_CC, "Cannot rewind file %s", intern->file_name);
} else {
spl_file_object_free_line(intern TSRMLS_CC);
intern->current_line_num = 0;
@@ -1026,7 +1026,7 @@
if (intern->stream == NULL) {
if (!EG(exception)) {
- zend_throw_exception_ex(spl_ce_RuntimeException, 0 TSRMLS_CC, "Cannot open file %s", intern->file_name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_RuntimeException), 0 TSRMLS_CC, "Cannot open file %s", intern->file_name);
}
return FAILURE;
}
@@ -1054,7 +1054,7 @@
spl_file_object *intern = (spl_file_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
zend_bool use_include_path = 0;
- php_set_error_handling(EH_THROW, spl_ce_RuntimeException TSRMLS_CC);
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(spl_ce_RuntimeException) TSRMLS_CC);
intern->open_mode = "r";
intern->open_mode_len = 1;
@@ -1191,7 +1191,7 @@
}
if (max_len < 0) {
- zend_throw_exception_ex(spl_ce_DomainException, 0 TSRMLS_CC, "Maximum line length must be greater than or equal zero");
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_DomainException), 0 TSRMLS_CC, "Maximum line length must be greater than or equal zero");
return;
}
@@ -1455,7 +1455,7 @@
}
if (!php_stream_truncate_supported(intern->stream)) {
- zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Can't truncate file %s", intern->file_name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_LogicException), 0 TSRMLS_CC, "Can't truncate file %s", intern->file_name);
RETURN_FALSE;
}
@@ -1473,7 +1473,7 @@
return;
}
if (line_pos < 0) {
- zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "Can't seek file %s to negative line %ld", intern->file_name, line_pos);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_LogicException), 0 TSRMLS_CC, "Can't seek file %s to negative line %ld", intern->file_name, line_pos);
RETURN_FALSE;
}
http://cvs.php.net/diff.php/php-src/ext/spl/spl_iterators.c?r1=1.75&r2=1.76&ty=u
Index: php-src/ext/spl/spl_iterators.c
diff -u php-src/ext/spl/spl_iterators.c:1.75 php-src/ext/spl/spl_iterators.c:1.76
--- php-src/ext/spl/spl_iterators.c:1.75 Thu Aug 11 19:35:55 2005
+++ php-src/ext/spl/spl_iterators.c Fri Aug 12 07:29:33 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: spl_iterators.c,v 1.75 2005/08/11 23:35:55 andrei Exp $ */
+/* $Id: spl_iterators.c,v 1.76 2005/08/12 11:29:33 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
# include "config.h"
@@ -241,11 +241,11 @@
}
ce = child && Z_TYPE_P(child) == IS_OBJECT ? Z_OBJCE_P(child) : NULL;
- if (!ce || !instanceof_function(ce, spl_ce_RecursiveIterator TSRMLS_CC)) {
+ if (!ce || !instanceof_function(ce, U_CLASS_ENTRY(spl_ce_RecursiveIterator) TSRMLS_CC)) {
if (child) {
zval_ptr_dtor(&child);
}
- zend_throw_exception(spl_ce_UnexpectedValueException, "Objects returned by RecursiveIterator::getChildren() must implement RecursiveIterator", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_UnexpectedValueException), "Objects returned by RecursiveIterator::getChildren() must implement RecursiveIterator", 0 TSRMLS_CC);
return;
}
if (object->mode == RIT_CHILD_FIRST) {
@@ -289,7 +289,7 @@
sub_iter = object->iterators[object->level].iterator;
sub_iter->funcs->dtor(sub_iter TSRMLS_CC);
zval_ptr_dtor(&object->iterators[object->level--].zobject);
- if (!object->endChildren || object->endChildren->common.scope != spl_ce_RecursiveIteratorIterator) {
+ if (!object->endChildren || object->endChildren->common.scope != U_CLASS_ENTRY(spl_ce_RecursiveIteratorIterator)) {
zend_call_method_with_0_params(&zthis, object->ce, &object->endChildren, "endchildren", NULL);
}
}
@@ -343,19 +343,19 @@
zend_class_entry *ce_iterator;
long mode = RIT_LEAVES_ONLY, flags = 0;
- php_set_error_handling(EH_THROW, spl_ce_InvalidArgumentException TSRMLS_CC);
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(spl_ce_InvalidArgumentException) TSRMLS_CC);
if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, "o|ll", &iterator, &mode, &flags) == SUCCESS) {
- if (instanceof_function(Z_OBJCE_P(iterator), zend_ce_aggregate TSRMLS_CC)) {
+ if (instanceof_function(Z_OBJCE_P(iterator), U_CLASS_ENTRY(zend_ce_aggregate) TSRMLS_CC)) {
zval *aggregate = iterator;
zend_call_method_with_0_params(&aggregate, Z_OBJCE_P(aggregate), &Z_OBJCE_P(aggregate)->iterator_funcs.zf_new_iterator, "getiterator", &iterator);
}
} else {
iterator = NULL;
}
- if (!iterator || !instanceof_function(Z_OBJCE_P(iterator), spl_ce_RecursiveIterator TSRMLS_CC)) {
+ if (!iterator || !instanceof_function(Z_OBJCE_P(iterator), U_CLASS_ENTRY(spl_ce_RecursiveIterator) TSRMLS_CC)) {
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
- zend_throw_exception(spl_ce_InvalidArgumentException, "An instance of RecursiveIterator or IteratorAggregate creating it is required", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_InvalidArgumentException), "An instance of RecursiveIterator or IteratorAggregate creating it is required", 0 TSRMLS_CC);
return;
}
@@ -366,19 +366,19 @@
intern->flags = flags;
intern->ce = Z_OBJCE_P(object);
zend_hash_find(&intern->ce->function_table, "callhaschildren", sizeof("callHasChildren"), (void **) &intern->callHasChildren);
- if (intern->callHasChildren->common.scope == spl_ce_RecursiveIteratorIterator) {
+ if (intern->callHasChildren->common.scope == U_CLASS_ENTRY(spl_ce_RecursiveIteratorIterator)) {
intern->callHasChildren = NULL;
}
zend_hash_find(&intern->ce->function_table, "callgetchildren", sizeof("callGetChildren"), (void **) &intern->callGetChildren);
- if (intern->callGetChildren->common.scope == spl_ce_RecursiveIteratorIterator) {
+ if (intern->callGetChildren->common.scope == U_CLASS_ENTRY(spl_ce_RecursiveIteratorIterator)) {
intern->callGetChildren = NULL;
}
zend_hash_find(&intern->ce->function_table, "beginchildren", sizeof("beginchildren"), (void **) &intern->beginChildren);
- if (intern->beginChildren->common.scope == spl_ce_RecursiveIteratorIterator) {
+ if (intern->beginChildren->common.scope == U_CLASS_ENTRY(spl_ce_RecursiveIteratorIterator)) {
intern->beginChildren = NULL;
}
zend_hash_find(&intern->ce->function_table, "endchildren", sizeof("endchildren"), (void **) &intern->endChildren);
- if (intern->endChildren->common.scope == spl_ce_RecursiveIteratorIterator) {
+ if (intern->endChildren->common.scope == U_CLASS_ENTRY(spl_ce_RecursiveIteratorIterator)) {
intern->endChildren = NULL;
}
ce_iterator = Z_OBJCE_P(iterator); /* respect inheritance, don't use spl_ce_RecursiveIterator */
@@ -711,7 +711,7 @@
spl_dual_it_object *intern;
zend_class_entry *ce;
- php_set_error_handling(EH_THROW, spl_ce_InvalidArgumentException TSRMLS_CC);
+ php_set_error_handling(EH_THROW, U_CLASS_ENTRY(spl_ce_InvalidArgumentException) TSRMLS_CC);
intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
@@ -726,12 +726,12 @@
}
if (intern->u.limit.offset < 0) {
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
- zend_throw_exception(spl_ce_OutOfRangeException, "Parameter offset must be > 0", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_OutOfRangeException), "Parameter offset must be > 0", 0 TSRMLS_CC);
return NULL;
}
if (intern->u.limit.count < 0 && intern->u.limit.count != -1) {
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
- zend_throw_exception(spl_ce_OutOfRangeException, "Parameter count must either be -1 or a value greater than or equal 0", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_OutOfRangeException), "Parameter count must either be -1 or a value greater than or equal 0", 0 TSRMLS_CC);
return NULL;
}
break;
@@ -756,19 +756,19 @@
return NULL;
}
ce = Z_OBJCE_P(zobject);
- if (!instanceof_function(ce, zend_ce_iterator TSRMLS_CC)) {
+ if (!instanceof_function(ce, U_CLASS_ENTRY(zend_ce_iterator) TSRMLS_CC)) {
if (ZEND_NUM_ARGS() > 1) {
if (zend_lookup_class(class_name, class_name_len, &pce_cast TSRMLS_CC) == FAILURE
|| !instanceof_function(ce, *pce_cast TSRMLS_CC)
|| !(*pce_cast)->get_iterator
) {
- zend_throw_exception(spl_ce_LogicException, "Class to downcast to not found or not base class or does not implement Traversable", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_LogicException), "Class to downcast to not found or not base class or does not implement Traversable", 0 TSRMLS_CC);
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
return NULL;
}
ce = *pce_cast;
}
- if (instanceof_function(ce, zend_ce_aggregate TSRMLS_CC)) {
+ if (instanceof_function(ce, U_CLASS_ENTRY(zend_ce_aggregate) TSRMLS_CC)) {
zval *retval;
zobject = zend_call_method_with_0_params(&zobject, ce, &ce->iterator_funcs.zf_new_iterator, "getiterator", &retval);
ce = Z_OBJCE_P(zobject);
@@ -777,9 +777,9 @@
break;
}
case DIT_AppendIterator:
- spl_instantiate(spl_ce_ArrayIterator, &intern->u.append.zarrayit, 1 TSRMLS_CC);
- zend_call_method_with_0_params(&intern->u.append.zarrayit, spl_ce_ArrayIterator, &spl_ce_ArrayIterator->constructor, "__construct", NULL);
- intern->u.append.iterator = spl_ce_ArrayIterator->get_iterator(spl_ce_ArrayIterator, intern->u.append.zarrayit TSRMLS_CC);
+ spl_instantiate(U_CLASS_ENTRY(spl_ce_ArrayIterator), &intern->u.append.zarrayit, 1 TSRMLS_CC);
+ zend_call_method_with_0_params(&intern->u.append.zarrayit, U_CLASS_ENTRY(spl_ce_ArrayIterator), &U_CLASS_ENTRY(spl_ce_ArrayIterator)->constructor, "__construct", NULL);
+ intern->u.append.iterator = U_CLASS_ENTRY(spl_ce_ArrayIterator)->get_iterator(U_CLASS_ENTRY(spl_ce_ArrayIterator), intern->u.append.zarrayit TSRMLS_CC);
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
return intern;
default:
@@ -806,7 +806,7 @@
Create an Iterator from another iterator */
SPL_METHOD(dual_it, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, zend_ce_iterator, DIT_Default);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(zend_ce_iterator), DIT_Default);
} /* }}} */
/* {{{ proto Iterator FilterIterator::getInnerIterator()
@@ -1046,7 +1046,7 @@
Create a RecursiveFilterIterator from a RecursiveIterator */
SPL_METHOD(RecursiveFilterIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, spl_ce_RecursiveIterator, DIT_Default);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(spl_ce_RecursiveIterator), DIT_Default);
} /* }}} */
/* {{{ proto boolean RecursiveFilterIterator::hasChildren()
@@ -1072,7 +1072,7 @@
intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
zend_call_method_with_0_params(&intern->inner.zobject, intern->inner.ce, NULL, "getchildren", &retval);
- spl_instantiate_arg_ex1(spl_ce_RecursiveFilterIterator, &return_value, 0, retval TSRMLS_CC);
+ spl_instantiate_arg_ex1(U_CLASS_ENTRY(spl_ce_RecursiveFilterIterator), &return_value, 0, retval TSRMLS_CC);
zval_ptr_dtor(&retval);
} /* }}} */
@@ -1080,7 +1080,7 @@
Create a ParentIterator from a RecursiveIterator */
SPL_METHOD(ParentIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, spl_ce_RecursiveIterator, DIT_Default);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(spl_ce_RecursiveIterator), DIT_Default);
} /* }}} */
/* {{{ proto boolean ParentIterator::hasChildren()
@@ -1106,7 +1106,7 @@
intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
zend_call_method_with_0_params(&intern->inner.zobject, intern->inner.ce, NULL, "getchildren", &retval);
- spl_instantiate_arg_ex1(spl_ce_ParentIterator, &return_value, 0, retval TSRMLS_CC);
+ spl_instantiate_arg_ex1(U_CLASS_ENTRY(spl_ce_ParentIterator), &return_value, 0, retval TSRMLS_CC);
zval_ptr_dtor(&retval);
} /* }}} */
@@ -1212,14 +1212,14 @@
spl_dual_it_free(intern TSRMLS_CC);
if (pos < intern->u.limit.offset) {
- zend_throw_exception_ex(spl_ce_OutOfBoundsException, 0 TSRMLS_CC, "Cannot seek to %ld which is below the offset %ld", pos, intern->u.limit.offset);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_OutOfBoundsException), 0 TSRMLS_CC, "Cannot seek to %ld which is below the offset %ld", pos, intern->u.limit.offset);
return;
}
if (pos > intern->u.limit.offset + intern->u.limit.count && intern->u.limit.count != -1) {
- zend_throw_exception_ex(spl_ce_OutOfBoundsException, 0 TSRMLS_CC, "Cannot seek to %ld which is behind offest %ld plus count %ld", pos, intern->u.limit.offset, intern->u.limit.count);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_OutOfBoundsException), 0 TSRMLS_CC, "Cannot seek to %ld which is behind offest %ld plus count %ld", pos, intern->u.limit.offset, intern->u.limit.count);
return;
}
- if (instanceof_function(intern->inner.ce, spl_ce_SeekableIterator TSRMLS_CC)) {
+ if (instanceof_function(intern->inner.ce, U_CLASS_ENTRY(spl_ce_SeekableIterator) TSRMLS_CC)) {
MAKE_STD_ZVAL(zpos);
ZVAL_LONG(zpos, pos);
spl_dual_it_free(intern TSRMLS_CC);
@@ -1248,7 +1248,7 @@
Construct a LimitIterator from an Iterator with a given starting offset and optionally a maximum count */
SPL_METHOD(LimitIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, zend_ce_iterator, DIT_LimitIterator);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(zend_ce_iterator), DIT_LimitIterator);
} /* }}} */
/* {{{ proto void LimitIterator::rewind()
@@ -1375,7 +1375,7 @@
} else {
INIT_PZVAL(&zflags);
ZVAL_LONG(&zflags, intern->u.caching.flags & CIT_PUBLIC);
- spl_instantiate_arg_ex2(spl_ce_CachingRecursiveIterator, &intern->u.caching.zchildren, 1, zchildren, &zflags TSRMLS_CC);
+ spl_instantiate_arg_ex2(U_CLASS_ENTRY(spl_ce_CachingRecursiveIterator), &intern->u.caching.zchildren, 1, zchildren, &zflags TSRMLS_CC);
zval_ptr_dtor(&zchildren);
}
}
@@ -1440,7 +1440,7 @@
Construct a CachingIterator from an Iterator */
SPL_METHOD(CachingIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, zend_ce_iterator, DIT_CachingIterator);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(zend_ce_iterator), DIT_CachingIterator);
} /* }}} */
/* {{{ proto void CachingIterator::rewind()
@@ -1496,7 +1496,7 @@
intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
if (!(intern->u.caching.flags & CIT_CALL_TOSTRING)) {
- zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "%v does not fetch string value (see CachingIterator::__construct)", Z_OBJCE_P(getThis())->name);
+ zend_throw_exception_ex(U_CLASS_ENTRY(spl_ce_BadMethodCallException), 0 TSRMLS_CC, "%v does not fetch string value (see CachingIterator::__construct)", Z_OBJCE_P(getThis())->name);
}
if (intern->u.caching.zstr) {
RETURN_STRINGL(Z_STRVAL_P(intern->u.caching.zstr), Z_STRLEN_P(intern->u.caching.zstr), 1);
@@ -1528,7 +1528,7 @@
Create an iterator from a RecursiveIterator */
SPL_METHOD(CachingRecursiveIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, spl_ce_RecursiveIterator, DIT_CachingRecursiveIterator);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(spl_ce_RecursiveIterator), DIT_CachingRecursiveIterator);
} /* }}} */
/* {{{ proto bolean CachingRecursiveIterator::hasChildren()
@@ -1574,7 +1574,7 @@
Create an iterator from anything that is traversable */
SPL_METHOD(IteratorIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, zend_ce_traversable, DIT_IteratorIterator);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(zend_ce_traversable), DIT_IteratorIterator);
} /* }}} */
static
@@ -1597,7 +1597,7 @@
Create an iterator from another iterator */
SPL_METHOD(NoRewindIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, zend_ce_iterator, DIT_NoRewindIterator);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(zend_ce_iterator), DIT_NoRewindIterator);
} /* }}} */
/* {{{ proto void NoRewindIterator::rewind()
@@ -1681,7 +1681,7 @@
Create an iterator from another iterator */
SPL_METHOD(InfiniteIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, zend_ce_iterator, DIT_InfiniteIterator);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(zend_ce_iterator), DIT_InfiniteIterator);
} /* }}} */
/* {{{ proto InfiniteIterator::next()
@@ -1726,14 +1726,14 @@
Throws exception */
SPL_METHOD(EmptyIterator, key)
{
- zend_throw_exception(spl_ce_BadMethodCallException, "Accessing the key of an EmptyIterator", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_BadMethodCallException), "Accessing the key of an EmptyIterator", 0 TSRMLS_CC);
} /* }}} */
/* {{{ proto EmptyIterator::current()
Throws exception */
SPL_METHOD(EmptyIterator, current)
{
- zend_throw_exception(spl_ce_BadMethodCallException, "Accessing the value of an EmptyIterator", 0 TSRMLS_CC);
+ zend_throw_exception(U_CLASS_ENTRY(spl_ce_BadMethodCallException), "Accessing the value of an EmptyIterator", 0 TSRMLS_CC);
} /* }}} */
/* {{{ proto EmptyIterator::next()
@@ -1801,7 +1801,7 @@
Create an AppendIterator */
SPL_METHOD(AppendIterator, __construct)
{
- spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, zend_ce_iterator, DIT_AppendIterator);
+ spl_dual_it_construct(INTERNAL_FUNCTION_PARAM_PASSTHRU, U_CLASS_ENTRY(zend_ce_iterator), DIT_AppendIterator);
} /* }}} */
/* {{{ proto void AppendIterator::append(Iterator it)
@@ -1813,7 +1813,7 @@
intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() TSRMLS_CC);
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "o", &it, zend_ce_iterator) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "o", &it, U_CLASS_ENTRY(zend_ce_iterator)) == FAILURE) {
return;
}
spl_array_iterator_append(intern->u.append.zarrayit, it TSRMLS_CC);
@@ -1893,7 +1893,7 @@
ulong int_key;
int key_type;
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O", &obj, zend_ce_traversable) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O", &obj, U_CLASS_ENTRY(zend_ce_traversable)) == FAILURE) {
RETURN_FALSE;
}
@@ -1929,7 +1929,7 @@
zend_object_iterator *iter;
long count = 0;
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O", &obj, zend_ce_aggregate) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O", &obj, U_CLASS_ENTRY(zend_ce_aggregate)) == FAILURE) {
RETURN_FALSE;
}