From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: emacs-26 c87d04e: Avoid aborts in 'md5' Date: Thu, 01 Mar 2018 05:39:00 +0200 Message-ID: <83sh9kxy5n.fsf@gnu.org> References: <20180227164448.16622.42058@vcs0.savannah.gnu.org> <20180227164448.E4B45207B1@vcs0.savannah.gnu.org> <87h8q15xdo.fsf@gmx.de> <87606h5vlm.fsf@gmx.de> <83inahyuq9.fsf@gnu.org> <83606hyqlw.fsf@gnu.org> <2ec62b62-7d0e-c0a5-6139-739f9b5a4206@cs.ucla.edu> <83woywyhri.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1519875422 28805 195.159.176.226 (1 Mar 2018 03:37:02 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 1 Mar 2018 03:37:02 +0000 (UTC) Cc: schwab@suse.de, michael.albinus@gmx.de, emacs-devel@gnu.org To: Paul Eggert Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Mar 01 04:36:57 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1erF1d-0006q9-07 for ged-emacs-devel@m.gmane.org; Thu, 01 Mar 2018 04:36:57 +0100 Original-Received: from localhost ([::1]:48132 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1erF3d-0005hF-Ku for ged-emacs-devel@m.gmane.org; Wed, 28 Feb 2018 22:39:01 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:41049) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1erF3X-0005gu-Hs for emacs-devel@gnu.org; Wed, 28 Feb 2018 22:38:56 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1erF3T-0008Ng-LE for emacs-devel@gnu.org; Wed, 28 Feb 2018 22:38:55 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:44874) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1erF3T-0008NS-H9; Wed, 28 Feb 2018 22:38:51 -0500 Original-Received: from [176.228.60.248] (port=4165 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1erF3T-0001wx-0O; Wed, 28 Feb 2018 22:38:51 -0500 In-reply-to: (message from Paul Eggert on Wed, 28 Feb 2018 14:14:46 -0800) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:223187 Archived-At: > Cc: schwab@suse.de, michael.albinus@gmx.de, emacs-devel@gnu.org > From: Paul Eggert > Date: Wed, 28 Feb 2018 14:14:46 -0800 > > On 02/28/2018 12:35 PM, Eli Zaretskii wrote: > > That's not what I meant. I meant that as long as the code is frozen > > in its current form, nothing is gained by omitting 'else'. > > I'm puzzled, since my patch inserts 'else', and yet you appear to be > objecting to it on the grounds that nothing is gained by omitting > 'else'. I must be misunderstanding. "Nothing is gained" was Andreas's argument, not mine. > For the case we're talking about, it's not possible for the object to be > a string, so although it might be appropriate to have an eassert > (STRINGP (...)) to verify that the impossible does not happen (to help > future-proof the code, say), we shouldn't need a runtime check in > production code. I don't want a function called from half a dozen places, which generates a string from at least 3 different object types, to become a cause for an assertion violation or worse. It is a large and not-so-simple function, where drawing such conclusions could yield mistakes. So let's please stop this particular bike-shedding and leave the code alone. There's nothing wrong with it.