Re: svn: /php/php-src/ branches/PHP_5_4/Zend/zend_compile.c trunk/Zend/zend_compile.c

From: Date: Tue, 16 Aug 2011 14:14:13 +0000
Subject: Re: svn: /php/php-src/ branches/PHP_5_4/Zend/zend_compile.c trunk/Zend/zend_compile.c
References: 1 2 3 4 5 6  Groups: php.cvs 
Request: Send a blank email to php-cvs+get-65875@lists.php.net to get a copy of this message
2011/8/16 Johannes Schlüter <johannes@schlueters.de>: > On Tue, 2011-08-16 at 13:44 +0200, Hannes Magnusson wrote: >> "use foobar;" has no effect, at all, and you will get an warning >> message telling you that. > > It has an effect. In > > namespace strict { class C {} } > namespace foo { use strict; new strict\C; } > > It saves one character of typing. Without the use strict I'd have to > write \strict\C. If this is useful might be questioned but it is valid. And this code snippet will continue to work just fine, as it didn't trigger a warning before. When the use statement has no effect you get a warning "The use statement with non-compound name '%s' has no effect", except now - we check if you have perl syndrome and let you know, forcefully. -Hannes

« previous php.cvs (#65875) next »