def _check_for_encoding(b):
    """You can use a different encoding from UTF-8 by putting a specially-formatted
    comment as the first or second line of the source code."""
    eol = b.find(b'\n')
    if eol < 0:
        return _check_line_for_encoding(b)[0]
    enc, again = _check_line_for_encoding(b[:eol])
    if enc or not again:
        return enc
    eol2 = b.find(b'\n', eol + 1)
    if eol2 < 0:
        return _check_line_for_encoding(b[eol + 1:])[0]
    return _check_line_for_encoding(b[eol + 1:eol2])[0]
You can use a different encoding from UTF-8 by putting a specially-formatted
    comment as the first or second line of the source code.