def do_get_latest_comments(parser, token):
    error_message = "%r tag must be of format {%% %r NUM_TO_GET as CONTEXT_VARIABLE %%}" % (token.contents.split()[0], token.contents.split()[0])
    try:
        split = token.split_contents()
    except ValueError:
        raise template.TemplateSyntaxError, error_message
    if len(split) != 4:
        raise template.TemplateSyntaxError, error_message
    if split[2] != 'as':
        raise template.TemplateSyntaxError, error_message
    if "free" in split[0]:
        is_free = True
    else:
        is_free = False
    return LatestCommentsNode(split[1], split[3], free=is_free)
Helper for lookup_symbol that only looks up global variables.
dataset/ETHPy150Open caseywstark/colab/colab/apps/threadedcomments/templatetags/threadedcommentstags.py/do_get_latest_comments--crossover with--dataset/ETHPy150Open myint/cppclean/cpp/symbols.py/SymbolTable._lookup_global