gnu-arch-users
[Top][All Lists]
Advanced

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

Re: [Gnu-arch-users] How does arch/tla handle encodings?


From: Marcus Sundman
Subject: Re: [Gnu-arch-users] How does arch/tla handle encodings?
Date: Fri, 27 Aug 2004 20:13:49 +0300
User-agent: KMail/1.7

On Friday 27 August 2004 19:01, Andrew Suffield wrote:
> On Fri, Aug 27, 2004 at 06:25:10PM +0300, Marcus Sundman wrote:
> > The vast majority of programs assume input text files to be in the
> > local system's default encoding. Therefore the files on disk should
> > preferably use whatever happens to be the local system's default
> > encoding. (In some files the encoding is part of the file's semantics,
> > though, so such files should be left as they are.)
>
> Here's where you invented the problem. My editor picks the right
> encoding for the file, and allows you to specify the encoding within
> the file for the ambiguous cases.

Oh, my. Where do I begin?
An editor cannot possibly know which encoding a file has. It can try to 
guess it by looking inside the file and eliminating encodings that are 
incompatible. However, there are several encodings in which any byte 
sequence is valid, and many, many encodings that have approximately the 
same control characters but differ mostly in the range of normal 
characters.

But sure, you _could_ specify the encoding each time you open a file, but 
this is precisely something that should be automatic.

> Fixing the problem anywhere else is a silly amount of work for no good
> reason.

Yeah, sure. Let's all remove the encoding info from the byte blobs and then 
try to guess what the encoding info was. What a brilliant idea. Or wait, 
I've got a better idea. Let's not throw away the encoding info. That way we 
(nor other people) won't have to guess what it was.


- Marcus Sundman




reply via email to

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