cvs: ZendEngine2 / zend_builtin_functions.c zend_object_handlers.c
| From: | Dmitry Stogov | Date: | Wed, 17 Aug 2005 17:07:52 +0000 |
| Subject: | cvs: ZendEngine2 / zend_builtin_functions.c zend_object_handlers.c | ||
| Groups: | php.zend-engine.cvs | ||
| Request: | Send a blank email to php-zend-engine-cvs+get-4028@lists.php.net to get a copy of this message | ||
dmitry Wed Aug 17 13:07:52 2005 EDT
Modified files:
/ZendEngine2 zend_builtin_functions.c zend_object_handlers.c
Log:
Unicode mode doesn't allow non-unicode properties
http://cvs.php.net/diff.php/ZendEngine2/zend_builtin_functions.c?r1=1.280&r2=1.281&ty=u
Index: ZendEngine2/zend_builtin_functions.c
diff -u ZendEngine2/zend_builtin_functions.c:1.280 ZendEngine2/zend_builtin_functions.c:1.281
--- ZendEngine2/zend_builtin_functions.c:1.280 Tue Aug 16 14:10:40 2005
+++ ZendEngine2/zend_builtin_functions.c Wed Aug 17 13:07:52 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_builtin_functions.c,v 1.280 2005/08/16 18:10:40 andrei Exp $ */
+/* $Id: zend_builtin_functions.c,v 1.281 2005/08/17 17:07:52 dmitry Exp $ */
#include "zend.h"
#include "zend_API.h"
@@ -929,7 +929,7 @@
RETURN_FALSE;
}
- if (Z_TYPE_PP(method_name) != IS_STRING || Z_TYPE_PP(method_name) == IS_UNICODE) {
+ if (Z_TYPE_PP(method_name) != (UG(unicode)?IS_UNICODE:IS_STRING)) {
convert_to_text_ex(method_name);
}
lcname = zend_u_str_case_fold(Z_TYPE_PP(method_name), Z_UNIVAL_PP(method_name),
Z_UNILEN_PP(method_name), 1, &lcname_len);
@@ -971,7 +971,7 @@
ZEND_WRONG_PARAM_COUNT();
}
- if (Z_TYPE_PP(property) != IS_STRING && Z_TYPE_PP(property) != IS_UNICODE) {
+ if (Z_TYPE_PP(property) != IS_UNICODE && (UG(unicode) || (Z_TYPE_PP(property) !=
IS_STRING))) {
convert_to_text_ex(property);
}
http://cvs.php.net/diff.php/ZendEngine2/zend_object_handlers.c?r1=1.140&r2=1.141&ty=u
Index: ZendEngine2/zend_object_handlers.c
diff -u ZendEngine2/zend_object_handlers.c:1.140 ZendEngine2/zend_object_handlers.c:1.141
--- ZendEngine2/zend_object_handlers.c:1.140 Wed Aug 17 09:10:02 2005
+++ ZendEngine2/zend_object_handlers.c Wed Aug 17 13:07:52 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_object_handlers.c,v 1.140 2005/08/17 13:10:02 dmitry Exp $ */
+/* $Id: zend_object_handlers.c,v 1.141 2005/08/17 17:07:52 dmitry Exp $ */
#include "zend.h"
#include "zend_globals.h"
@@ -291,7 +291,7 @@
zobj = Z_OBJ_P(object);
use_get = (zobj->ce->__get && !zobj->in_get);
- if (member->type != IS_STRING && member->type != IS_UNICODE) {
+ if (member->type != IS_UNICODE && (UG(unicode) || member->type != IS_STRING)) {
ALLOC_ZVAL(tmp_member);
*tmp_member = *member;
INIT_PZVAL(tmp_member);
@@ -347,7 +347,7 @@
zobj = Z_OBJ_P(object);
use_set = (zobj->ce->__set && !zobj->in_set);
- if (member->type != IS_STRING && member->type != IS_UNICODE) {
+ if (member->type != IS_UNICODE && (UG(unicode) || member->type != IS_STRING)) {
ALLOC_ZVAL(tmp_member);
*tmp_member = *member;
INIT_PZVAL(tmp_member);
@@ -494,7 +494,7 @@
zobj = Z_OBJ_P(object);
- if (member->type != IS_STRING && member->type != IS_UNICODE) {
+ if (member->type != IS_UNICODE && (UG(unicode) || member->type != IS_STRING)) {
tmp_member = *member;
zval_copy_ctor(&tmp_member);
convert_to_text(&tmp_member);
@@ -539,7 +539,7 @@
zobj = Z_OBJ_P(object);
use_unset = (zobj->ce->__unset && !zobj->in_unset);
- if (member->type != IS_STRING && member->type != IS_UNICODE) {
+ if (member->type != IS_UNICODE && (UG(unicode) || member->type != IS_STRING)) {
ALLOC_ZVAL(tmp_member);
*tmp_member = *member;
INIT_PZVAL(tmp_member);
@@ -919,7 +919,7 @@
zobj = Z_OBJ_P(object);
use_isset = (zobj->ce->__isset && !zobj->in_isset);
- if (member->type != IS_STRING && member->type != IS_UNICODE) {
+ if (member->type != IS_UNICODE && (UG(unicode) || member->type != IS_STRING)) {
ALLOC_ZVAL(tmp_member);
*tmp_member = *member;
INIT_PZVAL(tmp_member);