[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: attribute warn_unused_result

From: Paul Eggert
Subject: Re: attribute warn_unused_result
Date: Thu, 03 Feb 2011 16:57:14 -0800
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20101208 Thunderbird/3.1.7

On 02/03/11 13:14, Eli Zaretskii wrote:
>> From: Stefan Monnier <address@hidden>

>> I think the right thing to do is to adjust the code so as to make it
>> clear to the compiler that we thought about the issue and decided that
>> we really do want to ignore the return value.
> You can't do that, not with this warning.

Actually, you can do it.  In the current trunk, the warning is
ignored for one particular case, documented by wrapping the
call in question by ignore_value (CALL).  This is in
src/sysdep.c, line 583.

We can wrap the other calls as needed.  I did just one call
for now, to illustrate the technique.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]