Re: caller function?
| From: | Zeev Suraski | Date: | Thu, 14 Dec 2000 14:18:51 +0000 |
| Subject: | Re: caller function? | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-41369@lists.php.net to get a copy of this message | ||
At 16:12 14/12/2000, Tom Fishwick wrote:
As I said, this is a very far-reaching change, and will have to be a part of a thorough discussion and review (probably for Zend Engine 1.1). It's not going to be something that will happen in a miniversion, or in the immediate future. About the caller info thing - we don't want to slow down the engine for debugging purposes. The right way to do it is using a zend extension module, and using the engine's extended information capability - that way it can be done without slowing you down unless you're actually debugging. I don't have time to implement this functionality right now, but I'll try to do it for 4.0.5. Zeev -- Zeev Suraski <zeev@zend.com> CTO, Zend Technologies Ltd. http://www.zend.com/Also, any thoughts on some type checking syntax? ie.We're not getting into this now. It's a major concept change and should be discussed (I'm generally against it, definitely when talking about primitive types - perhaps with the future OO support). I agree with the primitive types, I was thinking more about the objects though. I think the type casting syntax works well for this. The past week I've been debugging a system written in php and _many_ of the bugs have been becaause the wrong object type has been been passed to a method. I either need to add code to check the object type for each method or have some other kind of type checking, I think that this:function blah((Person)$person) { }looks much better than:function blah($person) { if(get_class($person) != 'Person') trigger_error(E_USER_ERROR, '$person must be a Person object'); }the more I can separate logic code and the error checking code the better, which is my main reason for wanting a caller() and type checking operator.