From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Multibyte and unibyte file names Date: Sat, 02 Feb 2013 19:19:29 +0200 Message-ID: <83boc2bplq.fsf@gnu.org> References: <83ehhbn680.fsf@gnu.org> <83wqv2ldk1.fsf@gnu.org> <83obgel94c.fsf@gnu.org> <83k3r1lnlb.fsf@gnu.org> <83vcalj97s.fsf@gnu.org> <83r4l8jjtv.fsf@gnu.org> <83k3r0jd9r.fsf@gnu.org> <834ni3jefn.fsf@gnu.org> <83mwvticzi.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1359825575 28893 80.91.229.3 (2 Feb 2013 17:19:35 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 2 Feb 2013 17:19:35 +0000 (UTC) Cc: kzhr@d1.dion.ne.jp, michael.albinus@gmx.de, emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Feb 02 18:19:55 2013 Return-path: Envelope-to: ged-emacs-devel@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 1U1gkt-0001F5-6B for ged-emacs-devel@m.gmane.org; Sat, 02 Feb 2013 18:19:55 +0100 Original-Received: from localhost ([::1]:35102 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U1gka-0003JN-Qs for ged-emacs-devel@m.gmane.org; Sat, 02 Feb 2013 12:19:36 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:50955) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U1gkX-0003JH-IT for emacs-devel@gnu.org; Sat, 02 Feb 2013 12:19:35 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U1gkT-0006VZ-Ua for emacs-devel@gnu.org; Sat, 02 Feb 2013 12:19:33 -0500 Original-Received: from mtaout20.012.net.il ([80.179.55.166]:38540) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U1gkT-0006VQ-MX for emacs-devel@gnu.org; Sat, 02 Feb 2013 12:19:29 -0500 Original-Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MHL00K00QZOX200@a-mtaout20.012.net.il> for emacs-devel@gnu.org; Sat, 02 Feb 2013 19:19:27 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MHL00LOPS4E1H30@a-mtaout20.012.net.il>; Sat, 02 Feb 2013 19:19:27 +0200 (IST) In-reply-to: X-012-Sender: halo1@inter.net.il X-detected-operating-system: by eggs.gnu.org: Solaris 10 X-Received-From: 80.179.55.166 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:156800 Archived-At: > From: Stefan Monnier > Cc: kzhr@d1.dion.ne.jp, michael.albinus@gmx.de, emacs-devel@gnu.org > Date: Mon, 28 Jan 2013 10:21:52 -0500 > > >> At least I disagree with your Ffile_name_directory suggestion: if the > >> file-name is already encoded and it results in bugs, the fix should be > >> in the caller. > > So you are saying these primitives should assume decoded file names, > > and if called with encoded ones, exhibit undefined behavior, for which > > the fix is in the caller, is that right? > > Pretty much, yes. OK, I just committed to trunk a changeset (revision 111663) to do this. dostounix_filename now accepts an argument telling it whether the file name is multibyte (i.e. decoded), and fileio.c primitives use that. Downcasing of file names under w32-downcase-file-names is now done by calling Fdowncase on Lisp strings. Let's see how much will this break.