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: Typing raw bytes Date: Mon, 21 Jan 2013 19:38:00 +0200 Message-ID: <83y5fmo2rr.fsf@gnu.org> References: <83hambpqds.fsf@gnu.org> <83622rp517.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1358789898 26517 80.91.229.3 (21 Jan 2013 17:38:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 21 Jan 2013 17:38:18 +0000 (UTC) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jan 21 18:38:36 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 1TxLKO-00019f-IK for ged-emacs-devel@m.gmane.org; Mon, 21 Jan 2013 18:38:36 +0100 Original-Received: from localhost ([::1]:38805 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TxLK7-00015h-AQ for ged-emacs-devel@m.gmane.org; Mon, 21 Jan 2013 12:38:19 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:43021) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TxLK4-00015M-FW for emacs-devel@gnu.org; Mon, 21 Jan 2013 12:38:17 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TxLK3-0007sW-2A for emacs-devel@gnu.org; Mon, 21 Jan 2013 12:38:16 -0500 Original-Received: from mtaout21.012.net.il ([80.179.55.169]:50914) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TxLK2-0007sK-QN for emacs-devel@gnu.org; Mon, 21 Jan 2013 12:38:14 -0500 Original-Received: from conversion-daemon.a-mtaout21.012.net.il by a-mtaout21.012.net.il (HyperSendmail v2007.08) id <0MGZ00I00KPNVQ00@a-mtaout21.012.net.il> for emacs-devel@gnu.org; Mon, 21 Jan 2013 19:37:44 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout21.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MGZ00I53KYWR660@a-mtaout21.012.net.il>; Mon, 21 Jan 2013 19:37:44 +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.169 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:156551 Archived-At: > From: Stefan Monnier > Cc: emacs-devel@gnu.org > Date: Mon, 21 Jan 2013 10:38:20 -0500 > > >> Subsequent messages explain it seems to be due to the C-q NNN char being > >> passed through keyboard-coding-system: that seems to be a bug. > > How is that a bug? > > AFAIK C-q NNN should insert the char whose internal character code is > NNN (in Emacs's own encoding, not in the keyboard's), so the > keyboard-coding-system should not have any influence. It doesn't, indeed. I was wrong. The problem was the insertion of 8-bit codes into a multibyte buffer, which silently converts them to multibyte characters as appropriate to the current locale. > > Keyboard input decoding is not the issue here; how > > the result is inserted into a buffer is, IMO. > > In a unibyte buffer, a character code NNN (where NNN is less than 256) > should be inserted as that byte without any loss. I was wrong about the buffer being unibyte: raw-text doesn't do that. (I think it used to do so in some old version of Emacs, and the memory sticked.)