This module provides fast, validated encoding and decoding functions
between ByteStrings and Strings. It does not exactly match the
output of the Codec.Binary.UTF8.String output for invalid encodings
as the number of replacement characters is sometimes longer.

Try to extract a character from a byte string.
Returns Nothing if there are no more bytes in the byte string.
Otherwise, it returns a decoded character and the number of
bytes used in its representation.
Errors are replaced by character '\0xFFFD'.

Split a string into two parts: the first is the longest prefix
that contains only characters that satisfy the predicate; the second
part is the rest of the string.
Invalid characters are passed as '\0xFFFD' to the predicate.

Split a string into two parts: the first is the longest prefix
that contains only characters that do not satisfy the predicate; the second
part is the rest of the string.
Invalid characters are passed as '\0xFFFD' to the predicate.

Split a string into a list of lines.
Lines are termianted by '\n' or the end of the string.
Empty line may not be terminated by the end of the string.
This function preserves the terminators.
See also lines.