Re: __attribute__((warn_unused_result)) for NetBSD?
Thor Lancelot Simon <[email protected]>
| Newsgroups | gmane.os.netbsd.devel.general |
|---|---|
| Message-ID | <[email protected]> |
On Tue, Sep 16, 2008 at 10:10:50PM +0300, Aleksey Cheusov wrote: > > is SUFFICIENT. But if CHECKS FOR FAILURE IS NECESSARY, > warn-unused-result does its job, it implements minimal checks and > produces appropriate warnings/errors. Of course, warn-unused-result > cannot replace human :-) Please, STOP SHOUTING. We do have lower-case characters on our keyboards these days, though I understand that at one time that was not the case. I do not agree (and I think many others similarly do not agree) that ubiquitous warnings that cause many small (and large) programs to explode in length and decline dramatically in readability are "appropriate". There are other desiderata than checking every single possible error that might occur, no matter how improbable. Sometimes it is, in fact, desirable to produce brief, readable code that does not handle errors which one knows a priori are extremely unlikely to occur, or are not actually possible to handle in a beneficial way. Others may not strike the balance at the exact same point you do. That does not (despite what you seem to believe) mean they're wrong; what it does mean is that you and they have a difference of opinion. -- Thor Lancelot Simon [email protected] "Even experienced UNIX users occasionally enter rm *.* at the UNIX prompt only to realize too late that they have removed the wrong segment of the directory structure." - Microsoft WSS whitepaper