On 19/05/08 23:01, Bram Moolenaar wrote:
[...]
> I'm not sure if Vim should detect (and remove) a BOM halfway a file.
> You can get it with some filter commands and concatenating files.
> Perhaps we need a command ":delboms"?  And ":delbombs" for people who
> can't remember the command name :-).
>

A BOM halfway a file, if it is for the same encoding and endianness as 
the file, is a valid (though deprecated) Unicode codepoint, U+FEFF 
ZERO-WIDTH NO-BREAK SPACE. Removing it could conceivably "join" the 
adjoining words, which would have a bearing for character shape in some 
scripts like Arabic or, IIUC, Devanagari. It should therefore not be 
lightheartedly or thoughtlessly removed.

A BOM halfway a file, for the same encoding but the opposite endianness 
as what comes before, has been suggested as an "endianness change" 
marker, but IIUC this use never did it into the Unicode standard. Yet it 
could happen if files of opposite endianness are concatenated by mistake.


Best regards,
Tony.
-- 
(letter from Mark to Mike, about the film's probale certificate)
       I would like to get back to the Censor and agree to lose the 
shits, take
       the odd Jesus Christ out and lose Oh fuck off, but to retain 'fart in
       your general direction', 'castanets of your testicles' and 'oral sex'
       and ask him for an 'A' rating on that basis.
                  "Monty Python and the Holy Grail" PYTHON (MONTY) 
PICTURES LTD

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Raspunde prin e-mail lui