Re: [PEPr] Comment on PHP::Assert
| From: | Philippe Jausions | Date: | Thu, 11 Aug 2005 23:43:16 +0000 |
| Subject: | Re: [PEPr] Comment on PHP::Assert | ||
| References: | 1 2 3 4 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-39333@lists.php.net to get a copy of this message | ||
Carsten Lucke wrote:
Hi together, I think that exception-throwing and catching should not have to do anything with assertions. As mentioned before assertions should be used where normally nothing fails - but when, then there is no way of recovery ... Somehow Travis got the point when he wrote that there is the assert() function which also does a satisfactory job. But on the other hand I think it would not harm anyone if there was a PHP_Assertion wrapper around assert() in PEAR. I think people could decide on their own whether to use this or not.There is harm. assert() can be completly and simply disabled, barely adding any overhead, while a PEAR package could have a comparatively tremendous impact (loading + parsing + calling + executing and then the assert()) -Philippe