

@register.tag
def querystring(parser, token):
    '\n    Creates a URL (containing only the querystring [including "?"]) derived\n    from the current URL\'s querystring, by updating it with the provided\n    keyword arguments.\n\n    Example (imagine URL is ``/abc/?gender=male&name=Brad``)::\n\n        {% querystring "name"="Ayers" "age"=20 %}\n        ?name=Ayers&gender=male&age=20\n        {% querystring "name"="Ayers" without "gender" %}\n        ?name=Ayers\n\n    '
    bits = token.split_contents()
    tag = bits.pop(0)
    updates = token_kwargs(bits, parser)
    if (bits and (bits.pop(0) != 'without')):
        raise TemplateSyntaxError(("Malformed arguments to '%s'" % tag))
    removals = [parser.compile_filter(bit) for bit in bits]
    return QuerystringNode(updates, removals)

dataset/ETHPy150Open bradleyayers/django-tables2/django_tables2/templatetags/django_tables2.py querystring/original