def _remove_at_charset(tokens):
    tokens = iter(tokens)
    header = list(islice(tokens, 4))
    if [t.type for t in header] == ['ATKEYWORD', 'S', 'STRING', ';']:
        atkw, space, string, semicolon = header
        if ((atkw.value, space.value) == ('@charset', ' ')
                and string.as_css()[0] == '"'):
            # Found a valid @charset rule, only keep what’s after it.
            return tokens
    return chain(header, tokens)
Remove any valid @charset at the beggining of a token stream.
dataset/ETHPy150Open FichteFoll/CSScheme/tinycsscheme/tinycss/css21.py/_remove_at_charset