This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] debug/tst-longjmp_chk2: Make signal handler more conservative [BZ #20248]


On Wed, 15 Jun 2016, Paul Eggert wrote:

> I never understood why GCC generated warnings for expressions cast to void, as
> that was the longstanding idiom for "I know this returns a value, and I don't
> want it."

The point is that longstanding idiom implies people seeing a warning and 
blindly applying it, without thinking about whether there is a real bug 
present or whether it's really an exceptional case where ignoring the 
warning is OK.  Unfortunately it's difficult to take technical measures 
against stupidity, or to enforce a particular project's coding standards 
for exceptions (like glibc's DIAG_*_NEEDS_COMMENT macros needing a comment 
to explain why they are being used).

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]