emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Unicode-2] `read' always returns multibyte symbol


From: Katsumi Yamaoka
Subject: Re: [Unicode-2] `read' always returns multibyte symbol
Date: Thu, 15 Nov 2007 20:41:33 +0900
User-agent: Gnus/5.110007 (No Gnus v0.7) Emacs/23.0.60 (gnu/linux)

>>>>> Kenichi Handa wrote:
> In article <address@hidden>,
>       Katsumi Yamaoka <address@hidden> writes:

>> I realized a network process that is created by
>> `open-network-stream' in Emacs 21 breaks encoded non-ASCII group
>> names if the process buffer is in the multibyte mode even if the
>> process coding system is binary.  It behaves as if
>> `toggle-enable-multibyte-characters' modifies binary data when
>> turning on the multibyteness of a buffer.

(The changes that I made in nntp.el has been archived in
 <URL:http://article.gmane.org/gmane.emacs.gnus.commits/5519>.)

> If "modifies" means that 8-bit bytes are converted to
> multibyte characters as what string-as-multibyte does, it's
> an expected behaviour.

What I observed was different.  The group name "ใƒ†ใ‚นใƒˆ" is
encoded by utf-8 by the nntp server into:

"\343\203\206\343\202\271\343\203\210"

After it is transferred to Gnus, in the nntp process bufer it is
modified into:

"\343\203XY\343\203\210"

Where X is (make-char 'greek-iso8859-7 99)
  and Y is (make-char 'latin-iso8859-2 57).

Since Gnus treats a group name as a unibyte string, finally it
is made into:

"\343\203\343\271\343\203\210"

> I long ago proposed a facility that turns on the
> multibyteness of a buffer while converting 8-bit bytes to
> multibyte characters as what string-to-multibyte does, but
> not accepted.

But the modern Emacsen does do so, doesn't it?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]