From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: master b8062be 3/5: Remove some compat code from eudc-bob.el Date: Thu, 13 Aug 2020 19:43:48 +0300 Message-ID: <83364qmr7f.fsf@gnu.org> References: <20200812175454.4839.92908@vcs0.savannah.gnu.org> <20200812175456.C5D122172E@vcs0.savannah.gnu.org> <874kp7lpda.fsf@gnus.org> <87mu2zhssl.fsf@gnus.org> <83imdmn0vr.fsf@gnu.org> <835z9mmy4t.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32991"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Aug 13 18:45:51 2020 Return-path: Envelope-to: ged-emacs-devel@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 1k6GMQ-0008Uf-Lz for ged-emacs-devel@m.gmane-mx.org; Thu, 13 Aug 2020 18:45:50 +0200 Original-Received: from localhost ([::1]:52698 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1k6GMP-0004D8-MA for ged-emacs-devel@m.gmane-mx.org; Thu, 13 Aug 2020 12:45:49 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:59446) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1k6GKa-0002S8-DA for emacs-devel@gnu.org; Thu, 13 Aug 2020 12:43:56 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:57423) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1k6GKZ-00035U-Vn; Thu, 13 Aug 2020 12:43:55 -0400 Original-Received: from [176.228.60.248] (port=2271 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1k6GKY-000127-Td; Thu, 13 Aug 2020 12:43:55 -0400 In-Reply-To: (message from Stefan Monnier on Thu, 13 Aug 2020 10:23:57 -0400) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:253740 Archived-At: > From: Stefan Monnier > Cc: emacs-devel@gnu.org > Date: Thu, 13 Aug 2020 10:23:57 -0400 > > > And why does that matter in the case in point? > > No idea, but before removing that code we would have to find out why it > *doesn't* matter. It's quite clear that the code wants to put on disk the exact binary stream it received. > >> > (And it's wrong to use 'binary' for producing files that will > >> > be processed by programs other than Emacs, because 'binary' spills out > >> > the Emacs internal representation of characters.) > >> It's definitely not wrong for unibyte buffers where there's no "internal > >> representation of characters" that can spill out ;-) > > We cannot know that in general. > > Yes, we do: unibyte buffers have no "internal representation of > characters" that can spill out. In unibyte buffers the coding-system doesn't matter. > To me `binary` is *the* coding-system to use when you have bytes and > want to write them in a file (and same when you want to read the *bytes* > of a file into a buffer). For a unibyte buffer, it doesn't matter. For a multibyte buffer, it's dangerous.