From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.bugs Subject: bug#61730: 30.0.50; Compiler warnings for delq and delete Date: Thu, 23 Feb 2023 22:59:14 -0500 Message-ID: References: <87ilfsisje.fsf@web.de> Reply-To: rms@gnu.org Content-Type: text/plain; charset=Utf-8 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30241"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 61730@debbugs.gnu.org To: Michael Heerdegen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Feb 24 05:00:09 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pVPFh-0007gX-41 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 24 Feb 2023 05:00:09 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pVPFc-0003Dk-Pm; Thu, 23 Feb 2023 23:00:04 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pVPFb-0003DL-7C for bug-gnu-emacs@gnu.org; Thu, 23 Feb 2023 23:00:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pVPFa-0000Jn-UT for bug-gnu-emacs@gnu.org; Thu, 23 Feb 2023 23:00:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pVPFa-0005xk-Ld for bug-gnu-emacs@gnu.org; Thu, 23 Feb 2023 23:00:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Richard Stallman Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 24 Feb 2023 04:00:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61730 X-GNU-PR-Package: emacs Original-Received: via spool by 61730-submit@debbugs.gnu.org id=B61730.167721116422846 (code B ref 61730); Fri, 24 Feb 2023 04:00:02 +0000 Original-Received: (at 61730) by debbugs.gnu.org; 24 Feb 2023 03:59:24 +0000 Original-Received: from localhost ([127.0.0.1]:35756 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pVPEy-0005wP-C7 for submit@debbugs.gnu.org; Thu, 23 Feb 2023 22:59:24 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:46220) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pVPEv-0005w9-Nu for 61730@debbugs.gnu.org; Thu, 23 Feb 2023 22:59:22 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pVPEp-0008Vd-H6; Thu, 23 Feb 2023 22:59:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=Date:References:Subject:In-Reply-To:To:From: mime-version; bh=OfGCQj9amLsJwnzZeNstDCLxZkCnE3CGeH0TnRQxQWc=; b=pFPKBNp77X+L vaDgFsaU0IjX+XJ5W7EKycBW7a0nxspZpPuCaruah15EldbJ603jB+HZjrBWxMSdcgn2NWyE1ieC9 ZLgEIZSii52Y/JILnQC30r94d7b7Kp/qhdf47ZPBX45T5dfTK9qNSBZCbYMsIMNpdeLdOgiYcR1Qt Iq3Fv8VOkHaS77KSGnrjPWnYvmBEi1/r0pyJVGDCUheSIweQAsEk4he5bMn+V7Jjy4fGtPogndA83 Z+bda71/69L2HxUCTbkvDaStm/S8hqKFXYRVSaeKsUNPBUdH/HlF3BrpNYmIYSBmRErkezlnrW7+k z6ygFB2oLZvN5M0k0f54fw==; Original-Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1pVPEo-0000FK-Oa; Thu, 23 Feb 2023 22:59:14 -0500 In-Reply-To: <87ilfsisje.fsf@web.de> (message from Michael Heerdegen on Thu, 23 Feb 2023 11:29:25 +0100) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:256542 Archived-At: > I think we should add compiler warnings for `delete' and `delq' function > calls whose return values are unused. I think that is a good idea. But before we release such a change, we should try compiling a lot of code with it and study the warnings produced. Are nearly all the warnings caused by real bugs? There are some special cases where the unused value is not a bug. For instance, when you know that the elements to be deleted cannot include the first element, it is safe not to store the result back. One can argue that it is cleaner to do so anyway, but that's a matter of neatness, not a bug. -- Dr Richard Stallman (https://stallman.org) Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org)