From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#15535: Acknowledgement (24.3.50; basic-save-buffer should update buffer-file-coding-system value if the contents were written using different coding system) Date: Sun, 06 Oct 2013 23:58:57 +0300 Message-ID: <5251CF11.8080301@yandex.ru> References: <871u3z49ty.fsf@yandex.ru> <52509C0D.1000600@yandex.ru> <83vc1a5omh.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1381093221 24696 80.91.229.3 (6 Oct 2013 21:00:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 6 Oct 2013 21:00:21 +0000 (UTC) Cc: 15535@debbugs.gnu.org To: Eli Zaretskii , Kenichi Handa Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Oct 06 23:00:23 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VSvR9-0001Co-Cx for geb-bug-gnu-emacs@m.gmane.org; Sun, 06 Oct 2013 23:00:23 +0200 Original-Received: from localhost ([::1]:56431 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VSvR8-00076f-Qg for geb-bug-gnu-emacs@m.gmane.org; Sun, 06 Oct 2013 17:00:22 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46216) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VSvQy-00075e-L6 for bug-gnu-emacs@gnu.org; Sun, 06 Oct 2013 17:00:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VSvQr-000249-BU for bug-gnu-emacs@gnu.org; Sun, 06 Oct 2013 17:00:12 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:49951) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VSvQr-00023c-8g for bug-gnu-emacs@gnu.org; Sun, 06 Oct 2013 17:00:05 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1VSvQq-0007a3-Ad for bug-gnu-emacs@gnu.org; Sun, 06 Oct 2013 17:00:04 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 06 Oct 2013 21:00:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15535 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 15535-submit@debbugs.gnu.org id=B15535.138109315329048 (code B ref 15535); Sun, 06 Oct 2013 21:00:03 +0000 Original-Received: (at 15535) by debbugs.gnu.org; 6 Oct 2013 20:59:13 +0000 Original-Received: from localhost ([127.0.0.1]:58244 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VSvQ0-0007YR-5t for submit@debbugs.gnu.org; Sun, 06 Oct 2013 16:59:12 -0400 Original-Received: from mail-ee0-f45.google.com ([74.125.83.45]:36149) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VSvPt-0007YB-5C for 15535@debbugs.gnu.org; Sun, 06 Oct 2013 16:59:10 -0400 Original-Received: by mail-ee0-f45.google.com with SMTP id c50so2840723eek.18 for <15535@debbugs.gnu.org>; Sun, 06 Oct 2013 13:59:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=HXlZERPXKIhiD0IYbhaoyqVzu5j1RzKn8pwuQkhVEZw=; b=ubNAaqmBHQYAORc4uwjq6M00SzlqmBVzE/1qmVLKhaJRF5Y1ov4aMlS6sIjwc3V002 dxeSzI5rtuNy9f8DXR6AvooRmAIdMmI5WgTtw+tI/hwhyxcyMc8Axnjy+kQW5kxgN9P1 5ruVNm7FJGcZKlPIPS36+o/puVFaI8B+H/AiGtEnaa5Ieo8VqTKPuIzq2UsYgSHh47aE LA2gLrUPUKszaL+EVQFAPdAXWYA7UY9NWDWoLYOptkCXW+n09c/i0zSSdHbojhro04xP OMjSIRw6nA7P8wkA/iDycVWafuOE54AGjPgR7a93ilFkbQOXuVv7JDbQ6g7U8I4QeWVE LDwg== X-Received: by 10.14.122.132 with SMTP id t4mr43565941eeh.20.1381093143604; Sun, 06 Oct 2013 13:59:03 -0700 (PDT) Original-Received: from [192.168.10.2] (93-113-74.netrun.cytanet.com.cy. [93.109.113.74]) by mx.google.com with ESMTPSA id n48sm55106727eeg.17.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 06 Oct 2013 13:59:02 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.0 In-Reply-To: <83vc1a5omh.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 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.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:78961 Archived-At: On 06.10.2013 19:51, Eli Zaretskii wrote: > If the former, we could perhaps add some flag to struct undecided_spec > and set it whenever the encoder used by `undecided' sees a non-ASCII > character, and then use that flag to set last-coding-system-used to > UTF-8. That already happens (last-coding-system-used has the right value right after the file is written), but I don't think I can use it: even if `ruby-mode-set-encoding' is moved to after-save-hook, as long as it's not the first function in this hook (and I can't ensure that it is), the previous functions can also do some I/O and thus change last-coding-system-used's value. And that the reason I reverted 114527 in 114533, which in turn sparked the discussion in emacs-devel.