utf8.byte-order-mark

constant

Library: UTF-8 (OMUTF8)
Import : omutf8.xmd

Returns: UTF-8 byte-order mark


Declaration
constant string byte-order-mark
    


Purpose

Some UTF-8 data streams contain a leading byte-order mark (also referred to as a signature). Since this byte-order mark can interfere with later processing, it is sometimes better to remove it from the input. For example, since a UTF-8 byte-order mark can interfere with XML processing, it can be dropped from the input before the latter is passed to the XML parser:


  process
     do xml-parse scan file "input.xml" drop utf8.byte-order-mark?
        suppress
     done