Richard Henderson - Re: [RFC] PR/24900: computed but not used cast values (original) (raw)
This is the mail archive of the gcc@gcc.gnu.orgmailing list for the GCC 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] |
- From: Richard Henderson
- To: Ian Lance Taylor
- Cc: Aldy Hernandez , gcc at gcc dot gnu dot org, joseph at codesourcery dot com
- Date: Thu, 17 Nov 2005 15:24:34 -0800
- Subject: Re: [RFC] PR/24900: computed but not used cast values
- References: <20051117213300.GA15008@redhat.com> <m3br0j0w8b.fsf@gossamer.airs.com> <20051117225448.GA21279@redhat.com> <m33blu279z.fsf@gossamer.airs.com>
On Thu, Nov 17, 2005 at 03🔞00PM -0800, Ian Lance Taylor wrote:
I don't think you should get a warning for not using the return value of a function, at least not under -Wunused.
For this, I agree. Except that we're not talking about the return value of the function directly, we're talking about the return value of a cast.
Given that one can always cast any value to void to suppress this warning, I'm unconcerned about getting every single edge case "correct". Especially for edge cases for which one can reasonably disagree as to what is correct.
A stronger case for changing this would be that gcc version n-1 didn't warn. As discussed elsewhere, some modicum of stability in warnings is desirable from the user's perspective. I don't know whether or not this applies in this case.
r~
- Follow-Ups:
- Re: [RFC] PR/24900: computed but not used cast values
* From: Aldy Hernandez - Re: [RFC] PR/24900: computed but not used cast values
* From: Neil Booth
- Re: [RFC] PR/24900: computed but not used cast values
- References:
- [RFC] PR/24900: computed but not used cast values
* From: Aldy Hernandez - Re: [RFC] PR/24900: computed but not used cast values
* From: Ian Lance Taylor - Re: [RFC] PR/24900: computed but not used cast values
* From: Richard Henderson - Re: [RFC] PR/24900: computed but not used cast values
* From: Ian Lance Taylor
- [RFC] PR/24900: computed but not used cast values
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |