Hello Stephane, Monday, February 16, 2004, 5:13:46 PM, you wrote:
> == Quote from Andi Gutmans ([EMAIL PROTECTED])'s article >> Marcus didn't mean it adds complexity to the code but to PHP. It's >> obviously quite easy to implement this interface; implementation was never >> a problem. >> I don't really care too much if we have such an interface or not, although >> I do think that it just makes things complex and I doubt almost anyone will >> have a need for it. >> I think the arguments given on this list for why we need this interface >> were mainly academic and an attempt of people familiar with Java to copy >> the hierarchy. The actual times you will need such an interface is quite >> rare and I don't think it's worth the complexity for the one in a million >> purist guy (i.e. people who want all their classes to inherit from a >> CObject including exceptions). > Implementing an interface would also help in getting round the very > restrictive Exception implementation: > * all methods are final, including getMessage() !!!, > * its trace member is private. as i said before there is a reason for that: I played a long time with exceptions until they became what they are right now. And and attempt to increase the visibility of one of its members can be used to make it SEGV. So i don't want more visibility. Also where is the reason? You can read everything just fine and you can overload you exception to print out better formatted output and whatever. The only place where you need to change such member in derived classes is when you are using exceptions as flow control. And duing so is violating exception rule number two. So don't expect this to be changed. >> P.S. - BTW, why not call it IException (or ExceptionInterface) instead of >> Throwable? I think for people who don't know Java, it makes more sense. > Why not, but in that case, the other PHP interfaces should also follow this naming > convention. > Stephane -- Best regards, Marcus mailto:[EMAIL PROTECTED] -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php