From: Dmitry Stogov Date: Wed, 14 Jan 2009 13:57:59 +0000 (+0000) Subject: Fixed bug #46755 (warning: use statement with non-compound name) X-Git-Tag: php-5.4.0alpha1~191^2~4521 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=84f46ee4373fd946cb88cae39b554379b88fad10;p=php Fixed bug #46755 (warning: use statement with non-compound name) Fixed bug #46979 (use with non-compound name *has* effect) --- diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c index f12b6ec523..2e002a012a 100644 --- a/Zend/zend_compile.c +++ b/Zend/zend_compile.c @@ -5548,7 +5548,7 @@ void zend_do_use(znode *ns_name, znode *new_name, int is_global TSRMLS_DC) /* {{ } else { *name = *ns; zval_copy_ctor(name); - warn = !is_global; + warn = !is_global && !CG(current_namespace); } } else { char *p = zend_memrchr(Z_STRVAL_P(ns), '\\', Z_STRLEN_P(ns)); @@ -5557,7 +5557,7 @@ void zend_do_use(znode *ns_name, znode *new_name, int is_global TSRMLS_DC) /* {{ } else { *name = *ns; zval_copy_ctor(name); - warn = !is_global; + warn = !is_global && !CG(current_namespace); } } }