emacs-devel
[Top][All Lists]
Advanced

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

Re: Need some help with Rmail/mbox


From: Stefan Monnier
Subject: Re: Need some help with Rmail/mbox
Date: Sun, 21 Sep 2008 09:34:38 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

> We were discussing Rmail/mbox.  In that context, whenever you need to
> decode a message body, the buffer needs to be in unibyte mode.  That's
> it.  I think this is simple enough for anyone who writes related code.

The only reliable way to do decoding in buffers is by using
the `destination' argument to decode-coding-region so that you can
decode from a unibyte buffer into a multibyte buffer.

Dealing with "bytes in a multibyte buffer" or with "non-ascii chars in
a unibyte buffer" (as is necessarily the case either as source or as
destination if you do the decoding in-place) is just too delicate in my
experience (and of course, it's also somewhat inefficient).


        Stefan




reply via email to

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