From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.bugs Subject: bug#23595: 25.1.50; file with chinese/japanse chars, vc-diff fails (HG, Git, RCS) Date: Tue, 24 May 2016 23:19:01 -0700 Organization: UCLA Computer Science Department Message-ID: <574543D5.1030201@cs.ucla.edu> References: <87bn3z4l9i.fsf@mat.ucm.es> <1444321464004323@web25h.yandex.ru> <83h9do67pp.fsf@gnu.org> <21f6198c-a2fc-365f-caf7-79fad5027f1c@yandex.ru> <83twho41xd.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: quoted-printable X-Trace: ger.gmane.org 1464157225 16676 80.91.229.3 (25 May 2016 06:20:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 25 May 2016 06:20:25 +0000 (UTC) Cc: oub@mat.ucm.es, 23595@debbugs.gnu.org To: Eli Zaretskii , Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed May 25 08:20:14 2016 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 1b5SAv-0006cJ-6k for geb-bug-gnu-emacs@m.gmane.org; Wed, 25 May 2016 08:20:13 +0200 Original-Received: from localhost ([::1]:57568 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5SAu-00006A-CE for geb-bug-gnu-emacs@m.gmane.org; Wed, 25 May 2016 02:20:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43437) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5SAo-0008Vf-VC for bug-gnu-emacs@gnu.org; Wed, 25 May 2016 02:20:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b5SAk-0004Fc-MP for bug-gnu-emacs@gnu.org; Wed, 25 May 2016 02:20:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:52832) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b5SAk-0004FX-Iu for bug-gnu-emacs@gnu.org; Wed, 25 May 2016 02:20:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1b5SAk-0001LW-BO for bug-gnu-emacs@gnu.org; Wed, 25 May 2016 02:20:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 25 May 2016 06:20:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 23595 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 23595-submit@debbugs.gnu.org id=B23595.14641571535105 (code B ref 23595); Wed, 25 May 2016 06:20:02 +0000 Original-Received: (at 23595) by debbugs.gnu.org; 25 May 2016 06:19:13 +0000 Original-Received: from localhost ([127.0.0.1]:36934 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1b5S9w-0001KB-Lw for submit@debbugs.gnu.org; Wed, 25 May 2016 02:19:12 -0400 Original-Received: from zimbra.cs.ucla.edu ([131.179.128.68]:57282) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1b5S9u-0001Jw-87 for 23595@debbugs.gnu.org; Wed, 25 May 2016 02:19:10 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 7A1CB161376; Tue, 24 May 2016 23:19:02 -0700 (PDT) Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id 6itODWecZ5XO; Tue, 24 May 2016 23:19:01 -0700 (PDT) Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id C255716137E; Tue, 24 May 2016 23:19:01 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id E1dKJmdWig8e; Tue, 24 May 2016 23:19:01 -0700 (PDT) Original-Received: from [192.168.1.9] (unknown [100.32.155.148]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 9F756161376; Tue, 24 May 2016 23:19:01 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.8.0 In-Reply-To: <83twho41xd.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:118648 Archived-At: Eli Zaretskii wrote: > What Emacs should do is > bind coding-system-for-read to utf-8 in this case (not leave it > unbound as in your patch), under the assumption that the user used the > procedure outlined by Paul. I don't see how this would work for files like etc/HELLO, which use iso-2= 022-jp.=20 But perhaps the above comment is obsolete now. > ascii-compatible-p is not the right test, > the right one is mime-text-unsuitable-p; and the test should be > reversed, i.e. this: > > (coding-system-get CODING-SYSTEM :mime-text-unsuitable-p) > > should return nil for CODING-SYSTEM to be usable. Better, but this wouldn't work for coding systems like ebcdic-us, which a= re so=20 incompatible with ASCII that messages like "Binary files differ" would tu= rn into=20 gibberish. > testing this at run time sounds like waste of cycles. Not so many cycles that anyone will really care, I expect. We could establish a new coding system property for "close enough to ASCI= I that=20 most people won't mind". That would be a more-intrusive change, though. F= or=20 emacs-25 I thought it'd be better to have something that is more self-con= tained.