Re: Wierd ass code...
| From: | Robert Cummings | Date: | Sat, 13 May 2006 23:55:38 +0000 |
| Subject: | Re: Wierd ass code... | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-236129@lists.php.net to get a copy of this message | ||
On Sat, 2006-05-13 at 19:37, Rory Browne wrote:
>
> I would submit that the error suppression operator isn't BAD BAD BAD
> per se - it's just like goto, in that 99% of its use is bad. In the
> absence of a comment justifying it, the error-suppressed expression is
> BAD.
>
> There are some cases where the Error Suppression operator may be
> useful in good code. I wouldn't use it to suppress anything more
> serious than E_NOTICE. I don't think I ever used this operator, but if
> I did, i'd explain why there is no possible case where the code could
> emit an E_WARNING or higher.
Yep I agree with that... the particular usage in the example though was
just laziness :)
Cheers,
Rob.
--
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com
|
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting |
| a powerful, scalable system for accessing system services |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for |
| creating re-usable components quickly and easily. |
`------------------------------------------------------------'