public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c/25509] can't disable __attribute__((warn_unused_result))
Date: Mon, 30 Aug 2010 15:01:00 -0000	[thread overview]
Message-ID: <20100830150050.18755.qmail@sourceware.org> (raw)
In-Reply-To: <bug-25509-3563@http.gcc.gnu.org/bugzilla/>



------- Comment #26 from rguenth at gcc dot gnu dot org  2010-08-30 15:00 -------
(In reply to comment #25)
> > > gcc currently has no middle option.
> > 
> > Also this attribute is not on by default in glibc so you are asking to  
> > turn on the style based warnings.
> 
> (In reply to comment #24)
> > FIXED in GCC 4.5
> 
> After having waded through this long series of comments, I am left
> wondering just how this got addressed.  Does  --no-warn-unused-result
> mean that fwrite() usage may be cast to void, or that it may be
> treated as if it were a void procedure?  I think it is very reasonable
> to warn if a returned result is not handled.  Casting to void is
> a valid way to handle the result.  I would like warnings when returned
> results are not handled.  What does the fix do?

It simply adds -W[no-]unused-result and completely enables/disables all
unused result warnings.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25509


  parent reply	other threads:[~2010-08-30 15:01 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-20 23:09 [Bug c/25509] New: can't voidify __attribute__((warn_unused_result)) mueller at kde dot org
2005-12-20 23:53 ` [Bug c/25509] " joseph at codesourcery dot com
2005-12-21  0:07 ` mueller at kde dot org
2005-12-21  3:20 ` pinskia at gcc dot gnu dot org
2005-12-21  3:35 ` mueller at kde dot org
2005-12-21  3:47 ` pinskia at gcc dot gnu dot org
2005-12-21  3:55 ` joseph at codesourcery dot com
2005-12-21  4:02 ` mueller at kde dot org
2005-12-21  4:17 ` mueller at kde dot org
2005-12-21  9:59 ` rguenth at gcc dot gnu dot org
2005-12-21 10:16 ` rguenth at gcc dot gnu dot org
2005-12-21 10:59 ` rguenth at gcc dot gnu dot org
2005-12-21 13:04 ` joseph at codesourcery dot com
2005-12-21 14:07 ` mueller at kde dot org
2005-12-21 17:05 ` gdr at integrable-solutions dot net
2007-03-15 21:41 ` fche at redhat dot com
2008-10-17 11:41 ` [Bug c/25509] can't disable __attribute__((warn_unused_result)) bonzini at gnu dot org
2008-10-17 15:32 ` joseph at codesourcery dot com
2008-10-17 15:49 ` bonzini at gnu dot org
2008-10-17 16:56 ` joseph at codesourcery dot com
2008-11-22 15:44 ` thomas at mich dot com
2008-11-22 17:17   ` Andrew Thomas Pinski
2008-11-22 17:18 ` pinskia at gmail dot com
2008-11-22 18:36 ` fche at redhat dot com
2009-07-10  7:28 ` manu at gcc dot gnu dot org
2009-07-10  7:29 ` manu at gcc dot gnu dot org
2010-08-30 14:43 ` bkorb at gnu dot org
2010-08-30 15:01 ` rguenth at gcc dot gnu dot org [this message]
2010-08-30 21:09 ` ericb at gcc dot gnu dot org
     [not found] <bug-25509-4@http.gcc.gnu.org/bugzilla/>
2014-08-13 22:13 ` ppluzhnikov at google dot com
2014-08-13 23:47 ` manu at gcc dot gnu.org
2015-06-11  8:08 ` manu at gcc dot gnu.org
2015-06-11  8:54 ` manu at gcc dot gnu.org
2015-06-11 13:37 ` filbranden at google dot com

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100830150050.18755.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).