[Top][All Lists]

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

Re: Buffer-local variables affect general-purpose functions

From: Paul Eggert
Subject: Re: Buffer-local variables affect general-purpose functions
Date: Wed, 26 Mar 2014 14:50:52 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0

Eli Zaretskii wrote:
I think the problem is wider.

Yes, it is.

But there should still be a way to compare bytes and strings of bytes
in a unibyte buffer, right?

Byte-strings vs character-strings shouldn't be a problem, as the string itself tells you whether it's multibyte. The problem is bytes vs characters, as both are modeled as small integers.

So perhaps we should have special
functions just for that purpose, and char-equal should signal an error
when presented with unibyte non-ASCII values.

Sorry, I don't follow. How could char-equal know whether 224 is a raw byte or the Latin-1 character 'à'? It'd have to know that, to signal an error in the former case.

reply via email to

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