From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: eight-bit char handling in emacs-unicode Date: 23 Nov 2003 18:48:08 -0500 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: References: <200311130153.KAA04615@etlken.m17n.org> <200311130610.PAA04983@etlken.m17n.org> <200311130901.SAA05204@etlken.m17n.org> <200311140047.JAA06414@etlken.m17n.org> <200311180733.QAA13703@etlken.m17n.org> <200311190006.JAA14847@etlken.m17n.org> <200311210041.JAA18324@etlken.m17n.org> <200311210627.PAA18757@etlken.m17n.org> <200311220125.KAA20128@etlken.m17n.org> <200311230730.QAA21903@etlken.m17n.org> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1069631707 12832 80.91.224.253 (23 Nov 2003 23:55:07 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 23 Nov 2003 23:55:07 +0000 (UTC) Cc: jas@extundo.com, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Mon Nov 24 00:55:04 2003 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AO44G-0006m8-00 for ; Mon, 24 Nov 2003 00:55:04 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1AO44F-0002BY-00 for ; Mon, 24 Nov 2003 00:55:04 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AO4wI-0001hB-1Z for emacs-devel@quimby.gnus.org; Sun, 23 Nov 2003 19:50:54 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1AO4vw-0001dr-Mi for emacs-devel@gnu.org; Sun, 23 Nov 2003 19:50:32 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1AO4vQ-0000m6-Op for emacs-devel@gnu.org; Sun, 23 Nov 2003 19:50:31 -0500 Original-Received: from [132.204.24.67] (helo=mercure.iro.umontreal.ca) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AO4vC-0000X3-7s for emacs-devel@gnu.org; Sun, 23 Nov 2003 19:49:46 -0500 Original-Received: from vor.iro.umontreal.ca (vor.iro.umontreal.ca [132.204.24.42]) by mercure.iro.umontreal.ca (8.12.9/8.12.9) with ESMTP id hANNm8bj011383; Sun, 23 Nov 2003 18:48:09 -0500 Original-Received: by vor.iro.umontreal.ca (Postfix, from userid 20848) id 69CE33C63E; Sun, 23 Nov 2003 18:48:08 -0500 (EST) Original-To: Kenichi Handa In-Reply-To: <200311230730.QAA21903@etlken.m17n.org> Original-Lines: 23 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-DIRO-MailScanner: Found to be clean X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:18064 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:18064 > But, the concept of unibyte<->multibyte convesion itself is > not ad-hoc. Don't you think their meaning is very clear > when you grasp them as my way? Do you see any inconsistency > in my explanation about them? No, as a matter of fact I don't see why in a utf-8 environment, it makes any sense to have a function that turns a multibyte string into a unibyte string encoded in latin-1 (without even complaining when it encounters other characters). It'd make sense if the environment said "latin-1 when you can, utf-8 otherwise" or something like that, but then we would use encode-coding-string anyway. Besides, if any non-latin-1 char is encountered by string-make-unibyte, then we end up with a uninyte string that has an unknown meaning because some chars might have been encoded in latin-1, and others in some other encoding. I just don't know of a concrete case where it makes sense to use string-make-unibyte. Stefan