From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.devel Subject: Re: attribute warn_unused_result Date: Thu, 03 Feb 2011 16:57:14 -0800 Organization: UCLA Computer Science Department Message-ID: <4D4B4EEA.50907@cs.ucla.edu> References: <83r5bobz2k.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1296781067 25949 80.91.229.12 (4 Feb 2011 00:57:47 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 4 Feb 2011 00:57:47 +0000 (UTC) Cc: Stefan Monnier , emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Feb 04 01:57:43 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Pl9zU-0000nL-Jx for ged-emacs-devel@m.gmane.org; Fri, 04 Feb 2011 01:57:38 +0100 Original-Received: from localhost ([127.0.0.1]:55457 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pl9zS-0006mt-K8 for ged-emacs-devel@m.gmane.org; Thu, 03 Feb 2011 19:57:34 -0500 Original-Received: from [140.186.70.92] (port=51324 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pl9zE-0006k3-TO for emacs-devel@gnu.org; Thu, 03 Feb 2011 19:57:23 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pl9zC-0002O0-RP for emacs-devel@gnu.org; Thu, 03 Feb 2011 19:57:19 -0500 Original-Received: from smtp.cs.ucla.edu ([131.179.128.62]:54742) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pl9zA-0002Nb-VT; Thu, 03 Feb 2011 19:57:17 -0500 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp.cs.ucla.edu (Postfix) with ESMTP id 4417A39E80DB; Thu, 3 Feb 2011 16:57:16 -0800 (PST) X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu Original-Received: from smtp.cs.ucla.edu ([127.0.0.1]) by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Gudllqj+mmGT; Thu, 3 Feb 2011 16:57:15 -0800 (PST) Original-Received: from [131.179.64.200] (Penguin.CS.UCLA.EDU [131.179.64.200]) by smtp.cs.ucla.edu (Postfix) with ESMTPSA id 7CA9439E8083; Thu, 3 Feb 2011 16:57:15 -0800 (PST) User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.13) Gecko/20101208 Thunderbird/3.1.7 In-Reply-To: <83r5bobz2k.fsf@gnu.org> X-Enigmail-Version: 1.1.2 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 131.179.128.62 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:135549 Archived-At: On 02/03/11 13:14, Eli Zaretskii wrote: >> From: Stefan Monnier >> 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.