From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: reverting non-existent file Date: Thu, 14 May 2020 22:02:24 +0300 Message-ID: <83imgy49xb.fsf@gnu.org> References: <87lfluijfh.fsf@yandex.com> <83o8qq4bsm.fsf@gnu.org> <87h7wiic2a.fsf@yandex.com> Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="89506"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Colin Baxter Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu May 14 21:03:22 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 1jZJ8c-000NBN-An for ged-emacs-devel@m.gmane-mx.org; Thu, 14 May 2020 21:03:22 +0200 Original-Received: from localhost ([::1]:45318 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jZJ8b-0002jZ-BJ for ged-emacs-devel@m.gmane-mx.org; Thu, 14 May 2020 15:03:21 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54660) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jZJ7v-00025W-Jr for emacs-devel@gnu.org; Thu, 14 May 2020 15:02:39 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:40670) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jZJ7u-0002Vt-UW; Thu, 14 May 2020 15:02:38 -0400 Original-Received: from [176.228.60.248] (port=1435 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jZJ7t-0006yF-W2; Thu, 14 May 2020 15:02:38 -0400 In-Reply-To: <87h7wiic2a.fsf@yandex.com> (message from Colin Baxter on Thu, 14 May 2020 19:52:29 +0100) 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:250278 Archived-At: > From: Colin Baxter > Cc: emacs-devel@gnu.org > Date: Thu, 14 May 2020 19:52:29 +0100 > > > I get the error message even if I don't do steps 3 to 6. And that > > is expected, as a non-existent file cannot be reverted. So what > > did you find surprising in this behavior? > > > (I'm guessing that your locale uses UTF-8 as its codeset, so the > > new file's buffer has utf-8 encoding from the get-go, and thus > > adding the local variable doesn't change the coding-system, and > > you are not asked to revert the buffer. Which is also expected.) > > > Confused. > > Not now, thanks. I think I was confused by the response "revert-buffer" > when I knew I'd yet to save it. And yes, my locale is utf-8. Hmm... maybe we should not suggest reverting if the file doesn't exist? Would that make this situation less confusing?