At 07:29 PM 4/7/2003 +0200, Marcus Börger wrote:
AG> I don't like these OO tricks. It makes sense in my opinion not to have
AG> access modifiers for destructors. The destructor should be called on object
AG> destruction no matter what.


Hm, i think full language support for factories and related patterns are oo
tricks that we should provide. At least i *very* much hope we do.

I don't see any correlation between factories and design patterns and allowing destructors to have access modifiers. Java doesn't even have destructors :)
Anyway, as I mentioned before, destructors shouldn't have access modifiers (like methods in interfaces). So what you are saying is that today we can make destructors private/protected? If so we need to fix it.


Andi


Sometimes it is necessary to explicitly destruct an object and bla bla....
Btw. have a look at tests/classes/destructor_and_globals.phpt and make the
destuctor protected or private with and without my patch. Beides that the
situation is somekind of a more 'funny' problem we should fix it sometime.


-- Best regards, Marcus mailto:[EMAIL PROTECTED]


--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to