utf8BomLength

fnsize_t utf8BomLength(const(ubyte)[] bytes) @safe pure nothrow

Returns the length of a UTF-8 BOM prefix in bytes.

Parameters

bytesInput byte sequence.

Returns

3 if bytes begins with the UTF-8 BOM (EF BB BF), otherwise 0.