I recently rediscovered this strange behaviour in Python’s Unicode handling.—Evan

Ok, as signature the BOM does make some sense - whether to strip signatures from a document is a good idea or not is a different matter, though.

Here’s the Unicode Cons. FAQ on the subject:

<unicode.org>

They also explicitly warn about adding BOMs to UTF-8 data since it can break applications and protocols that do not expect such a signature.—M.-A.