[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Unibyte characters, strings, and buffers
From: |
David Kastrup |
Subject: |
Re: Unibyte characters, strings, and buffers |
Date: |
Sat, 29 Mar 2014 18:18:54 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) |
Nathan Trapuzzano <address@hidden> writes:
> Nathan Trapuzzano <address@hidden> writes:
>
>> For example, say we decode a stream of raw bytes as utf8, but that the
>> stream contains some non-utf8 sequences.
>
> Of course, most programming languages would simply refuse to decode by,
> e.g., throwing an exception. But that's not really appropriate for an
> editor. On one hand, you need some way to distinguish between
> characters and bytes, even if the distinction's not made by the type
> system; on the other hand, an _editor_ of all things should be able to
> deal with both kinds at the same time without the distinction being
> lost, and Emacs does a tremendous job at this IMO.
_De_coding into a _unibyte_ buffer is a lossy operation by definition
since a unibyte buffer cannot hold the full set of values that
_de_coding delivers.
--
David Kastrup
- Re: Unibyte characters, strings, and buffers, (continued)
- Re: Unibyte characters, strings, and buffers, David Kastrup, 2014/03/30
- Re: Unibyte characters, strings, and buffers, Andreas Schwab, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Richard Stallman, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Stefan Monnier, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Richard Stallman, 2014/03/30
- Re: Unibyte characters, strings, and buffers, Andreas Schwab, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Stephen J. Turnbull, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Andreas Schwab, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Nathan Trapuzzano, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Nathan Trapuzzano, 2014/03/29
- Re: Unibyte characters, strings, and buffers,
David Kastrup <=
- Re: Unibyte characters, strings, and buffers, Nathan Trapuzzano, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Richard Stallman, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Andreas Schwab, 2014/03/30
- Re: Unibyte characters, strings, and buffers, Richard Stallman, 2014/03/30
- Re: Unibyte characters, strings, and buffers, David Kastrup, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Daniel Colascione, 2014/03/28
- Re: Unibyte characters, strings, and buffers, Glenn Morris, 2014/03/28
- Re: Unibyte characters, strings, and buffers, Stephen J. Turnbull, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Eli Zaretskii, 2014/03/29
- Re: Unibyte characters, strings, and buffers, Stephen J. Turnbull, 2014/03/29