|
From: | Ulf Ochsenfahrt |
Subject: | Re: [Monotone-devel] line endings as project policy |
Date: | Thu, 23 Nov 2006 12:37:46 +0100 |
User-agent: | Icedove 1.5.0.8 (X11/20061116) |
Nuno Lucas wrote:
Line endings don't have a direct relation to character encoding. It's true that in theory you would need to know the character encoding to know what a line ending is (like the mentioned line ending Unicode character), but in practice there are only 3 "standard" line endings (LF, CR-LF and CR) and if some file uses any other you would need to use a special program for it, so it's better to treat the file as binary. An ASCII text can use any of the 3 line-endings. Some with an UTF-8 text, ISO-8859-1, or any other. No way to know the line ending by the character encoding.
Yes, but UTF-8 is a _multi-byte_ encoding.If you see an LF byte, you don't know whether this is a single-byte LF or part of a multi-byte sequence. (I'm not sure if this is a problem with UTF-8 in particular, but it certainly is with 16 or 32-bit encodings, such as UTF-16 and UTF-32.)
-- Ulf
smime.p7s
Description: S/MIME Cryptographic Signature
[Prev in Thread] | Current Thread | [Next in Thread] |