Re: Re: PHP 4.0 Bug #4294 Updated: return in script called from php.ini stops engine (2/2)

From: Date: Sat, 19 Aug 2000 14:59:20 +0000
Subject: Re: Re: PHP 4.0 Bug #4294 Updated: return in script called from php.ini stops engine (2/2)
References: 1 2  Groups: php.dev 
Request: Send a blank email to php-dev+get-29662@lists.php.net to get a copy of this message
At 04:46 PM 8/19/00 +0200, André Langhorst wrote:
Yes but the global scope is now only the real global scope. prepend/append/require/include have their own scope now. It is especially useful as you can return values from require() and include().
sure, but what is the trick behind treating return like exit an the global scope? why should I be able to leave the global scope to who is that variable returned, to god? ;) But in fact it doesn´t matter if return exists or is ignored, it´s just wrong to place it there (but I´d ignore it)
It is returned to the Zend Engine which makes sure that returned value is freed. It has no semantic value to return from the global scope. Andi --- Andi Gutmans <andi@zend.com> http://www.zend.com/

« previous php.dev (#29662) next »